How to populate rows from another table in new blank rows of other table

I have to convert an oracle form 6i to Jdeveloper application. In forms 6i we use create a cursor for other table and then populate the current table data block row using create record and assigning its values from cursor and then issuing next record until all cursor records are written in data block. After some manual editing we save the whole form and then all block records are saved as new rows in table.
Now how to create this functionality in jdeveloper application.
Kindly help.

two steps-
1. get row from first VO.iterate them - like below -
DCBindingContainer bindings = (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry();
                                DCIteratorBinding dcIteratorBindings = bindings.findIteratorBinding("ViewObj1Iterator");
                                HSSFRow  excelrow = null;
                                        // Get all the rows of a iterator
                                        oracle.jbo.Row[] rows = dcIteratorBindings.getAllRowsInRange();
                                    int i = 0;
                                            for (oracle.jbo.Row row : rows) {
                                                                                                                row.getAttribute(colName).toString());  // by this you can get row attribute value..
2. inside iteration create row for VO 2 for example-
ViewObject employee= findViewObject("EmployeeVO");
// Create a row and fill in the columns.
Row row = employee.createRow();
row.setAttribute("Name", "Vinay");
row.setAttribute("EmpId", 1);
//Insert row in to the default row set
employee.insertRow(row);
Read more: http://www.techartifact.com/blogs/2012/12/creating-new-row-of-view-object-in-adf-techartifact.html#ixzz2iL978UOD
http://www.techartifact.com/blogs/2012/12/creating-new-row-of-view-object-in-adf-techartifact.html

Similar Messages

  • Insert missing rows from another table

    Hi
    I need to insert rows from another table if there is gaps in my transaction table. For each ärendenr there should be 5 Id status rows (1-5). Except for the fact that the inserted rows never should have higher IdStatus number then the highest value from
    the transaction for each Ärendenr. See my example below that illustrates my transaction table, Stages master and the desired result.
    Is there some t sql code that could handle this problem?
    Best regards
    Arne
    So far i have tried to solve this with the code below but it doesnt work.
    I have copied the transaction file information to the TempLogTransTimes
    and then insert into LogTransTimes
    IF OBJECT_ID('dbo.TempLogTransTimes', 'U') IS NOT NULL --Här raderas den tillfälliga tabellen
    DROP TABLE dbo.TempLogTransTimes;
    SELECT *
    INTO TempLogTransTimes
    FROM LogTransTimes
    DECLARE @TopÄrende INT
    WHILE EXISTS(SELECT * FROM TempLogTransTimes)
    BEGIN
    SET @TopÄrende = (SELECT TOP(1) Ärendenr FROM TempLogTransTimes ORDER BY Ärendenr)
    INSERT INTO LogTransTimes(Ärendenr, IdStatus, StatusNamn, SourceId)
    SELECT @TopÄrende, SM.IdStatus, SM.StatusNamn, 'Beräkning'
    FROM Statusmall SM
    FULL JOIN TempLogTransTimes LT ON SM.IdStatus = LT.IdStatus
    WHERE LT.IdStatus IS NULL
    DELETE TempLogTransTimes WHERE Ärendenr = @TopÄrende
    END
    Arne Olsson

    Hi Arne Olsson, try this..
    DECLARE @Transactions TABLE
    Id1 INT,
    IdStatus INT,
    StatusName VARCHAR(10)
    DECLARE @Stages TABLE
    IdStatus INT,
    StatusName VARCHAR(10)
    INSERT INTO @Transactions VALUES(1,1,'AA'), (1,3,'CC'), (1,5,'EE'), (2,1,'AA'), (2,3,'CC')
    INSERT INTO @Stages VALUES (1,'AA'), (2,'BB'), (3,'CC'), (4,'DD'), (5,'EE')
    ;WITH CTE AS(SELECT DISTINCT Id1 FROM @Transactions)
    SELECT Id1, IdStatus, StatusName FROM CTE, @Stages
    EXCEPT
    SELECT Id1, IdStatus, StatusName FROM @Transactions
    Please mark as answer, if this has helped you solve the issue.
    Good Luck :) .. visit www.sqlsaga.com for more t-sql code snippets and BI related how to articles.

  • How to populate data from table into datagrid in form

    hi there. may i know how to populate data from a table into a datagrid? i have created a datagrid in a form using OLE's microsoft datagrid. i'm having problem to populate data from table into the grid. can i know how to do that? thanks

    Not exactly. I want to enter input from form and the user can have all options to choose i.e. HIGH, MEDIUM or so on.
    Suppose, you have option to select HIGH, MEDIUM or LOW and you can see all these options together. You select LOW and when you save, it is saves in the table as a value. So when you view the table again, it will show LOW as active and HIGH and MEDIUM are null.

  • How to copy images from another MC in reversed order??

    Hi everyone,
    I'm new to AS3 and have been fighting and searching for a solution to this problem for a week now, and I'm VERY close!
    I crated a MC holding of a series of images (about 50) and I jump around in it using plenty AS3 scripts (most of which I don't fully understand yet, but I'm working on that to! )
    I had to find a way to "rewind" (= play backwards) the MC. Since there is a stop(); command in almost every frame, prevFrame does not work and if I put that in a loop, it goes WAY to fast (but worked).. So I could think of only one way...
    Create a new (reverserd) MC with the same image sequence ald reverse it manually and play that one.
    This all works fine (very proud of it ).
    Now my question:
    To get this to work for multiple image sequences, I have to load all images twice (once in MC_1 and again in MC_2 and select them and reverse them).
    Not a big one, unless you want to create MANY of those SWF's...
    Is it possible to load the 50 images of the first MC in reverse into the second MC dynamically? JUST the images, noting else.
    extra info: the MC_2 is already in the lib(empty) and placed on the stage.
    something like:
    var pointer:Number=1;
    for (var:i:Number=50;i>=0;i--) {
    get MC_1.picure(var);
    put it in MC_2.frame(pointer);
    pointer = pointer + 1;
    All help is welcome and please take into account that I have little experience and copy most of my scripting from people like you
    T.I.A.
    Melluw

    I tried your advice (thanks for that)
    The event I already have is the mouse leave
    I //-d out the part I removed (what did work)
    The code I ended up with is:
    function Start() {
    stage.addEventListener(Event.MOUSE_LEAVE, cursorHide);
    function cursorHide(evt:Event):void {
    var currFrame = MC_1.currentFrame;
    if (CCW == true) {  //it is true in this case
      movStart = (50 - currFrame);
    else {
      movStart = currFrame;
    if (movStart>25) {
      MC_1.prevFrame();
    // removed swapChildren(MC_1, MC_2); // This is the part I removed
    // removed MC_2.gotoAndPlay(movStart);
    else {
      MC_1.gotoAndPlay (movStart);
    And if I leave the stage on the part where movStart is indeed >25
    Nothing happens,
    So I guess this is not what you meant
    Subject: Action Script 3 how to copy images from another MC in reversed order??
    I cannot direct you in the loading of the images approach, it will be too complicated, and will probably not work anyways... when you move away from a frame that has dynamic content, you lose the content.  So basically, there is nothing practical in taking that approach.
    I do niot understand what the problem will be with the enterFrame/prevFrame approach. If everything you can do with the mouse is already used (which I doubt) by the first mc, then there is nothing else you can do with this file.  You probably just need to rethink your control scheme.  You should search Google for "AS3 slideshow tutorial", and to lighten up your design, add "XML" in that search.
    >

  • HT204350 Incorrect link to "OS X: How to migrate data from another Mac using Mountain Lion and earlier"

    Incorrect link to "OS X: How to migrate data from another Mac using Mountain Lion and earlier". Should be http://support.apple.com/kb/HT6025

    I think the OP is saying OS X: How to migrate data from another Mac using Mountain Lion and earlier (which should be a link to HT4889) just links back to OS X: How to migrate data from another Mac using Mavericks (HT5872).
    It does indeed do that, & HT4889 seems to be MIA.

  • How to view messages from another iPhone using your apple Id

    How to view messages from another iPhone using your apple Id

    Sign into iMessage using the same ID (in Settings>Messages>Send & Receive).  The other phone should then see your messages too.

  • How I can backup from another Hard disk through my Macbook air?

    How I can backup datas from another external storage disk by using My Macbook Air?

    How I can backup from another hard disk through my Macbook air in Time Capsule?

  • How we can restrict record in CTL file on the basis of other table ?

    Hello all,
    How we can restrict record in CTL file on the basis of other table ?
    Eg.
    I have following control file to load the records in the table through the sql loader.
    LOAD DATA
    INTO TABLE THIST APPEND
    FIELDS TERMINATED BY "|" TRAILING NULLCOLS
    LNUM POSITION(1) Char "substr(:LOAN_NUM, 4, 13)",
    TSRNUM Char "rtrim:TRAN_SR_NUM)" ,
    TPROCDT Char "to_char(to_date rtrim:TRAN_PROC_DT), 'MMDDYYYY'), 'YYYYMMDD')"      
    I have another table c all TFILE in which I have LNUM. I want to import only those records from input text file using the control file and sql loader in which LNUM is exist in the TFILE.
    So how i can restrict it in the Control File.
    Thanks
    Kamlesh Gujarathi
    [email protected]

    Hello Satyaki De.
    Thank you very much for your suggestion but my Private information is totally apart from this question & I already I have changed each and every information from the question.
    Thanks
    Kamlesh Gujarathi
    [email protected]

  • How to prevent apps from syncing in the new version of itunes?

    Hey there.
    I brang my macbook to Applestore cause it had a problem and they downloaded the latest version of itunes. Everything's fine and my music, videos and apps are in the new itunes like before. But now, when I want to sync my iphone, a pop window asks me to give the password of the itunes account I used to download some of my apps or it will delete them and their data. The problem is that one of these accounts is an old friend's one and I actually lost all contact with him. So basically now I can't sync my iphone at all or it will delete all my apps.
    Has anyone any idea how to sort that out? Or at least knows how to prevent apps from syncing in this new version of itunes?
    Thanks for your help

    Onthe top menu
    View > Show Status Bar.
    The grey bar will now appear at the bottom with the info you want

  • I just got tOhe iPhone 4Gs today and had contacts and photos uploaded from another phone synced new phone with iTunes for music and accidentally restored it so all my old iPhone stuff is on the new one is there any way to fix this

    I just got tOhe iPhone 4Gs today and had contacts and photos uploaded from another phone synced new phone with iTunes for music and accidentally restored it so all my old iPhone stuff is on the new one is there any way to fix this ?! Please help !!!!

    Could you be more specific about what exactly do you want to fix now?

  • How to get playlist from old ipod to new itunes

    how to get playlist from old ipod to new itunes

    See Recover your iTunes library from your iPod or iOS device.
    tt2

  • HT4859 How can I restore from iCloud on my new phone if I didn't do it on the intial setup process?

    How can I restore from iCloud on my new phone if I didn't do it on the intial setup process?

    You can't merge the backups, you'll have to delete the backup of your old phone.  If it says it's currently in use when you try, that will normally clear up on its own but may take 3-5 days to do so.  Give it a few days and try deleting the old backup again.
    In the meantime, you can create a manual backup of your new phone on your computer by connecting it to your computer, opening iTunes, clicking on the name of your phone in iTuens, going to the Summary tab of your iTunes sync settings and clicking Back Up Now.  Also go to File>Devices>Transfer Purchases.  Then you'll be safe until you can start backup up to iCloud again.

  • I backed up to the cloud and then Apple gave me a new phone which was IOS6.  How do I restore from Cloud to my new phone which I have just updated to IOS7 please?

    I backed up to the cloud and then Apple gave me a new phone which was IOS6.  How do I restore from Cloud to my new phone which I have just updated to IOS7 please?
    Grateful for any suggestions.

        Hi kattaylor49!
    I hope you are enjoying your new phone! Here are the steps to restore your content:http://bit.ly/1z5kb40.
    Thanks,
    AyaniB_VZW
    Follow us on Twitter @VZWSupport

  • How do I migrate from old Imac to new?

    How do I migrate from old Imac to new?

    Setting-up a new Mac from an old one, its Backups, or a PC 

  • How do you transfer from old ipad to new ipad

    How do you transfer from old ipad to new ipad

    How to Transfer Everything from an Old iPad to New iPad
    http://osxdaily.com/2012/03/16/transfer-old-ipad-to-new-ipad/
     Cheers, Tom

Maybe you are looking for

  • HP photosmart D110 Mac OSX 10.8.5

    I have had to reload my printers into my Macbook pro.  I have loaded the HP photosmart D110 in the print/scan utility and can see the printer.  I also can print a test page.  When I go to print a document, I get the following message "printing-printe

  • PO attachments in ME22N greyed out

    Hi all, i created a new PO, after that, i went to ME22N just to add an PDF file as an attachment. I went to the create Services for Object - Create.... but the option of Create attachment it is greyed out. The PO is open, not MIGO or MIRO transaction

  • Crc issue when extracting VHD trial SAP Gateway

    I've encountered a problem with the Sap netweaver gateway 2.0 - Abap and java trial version on microsoft server. I've managed to download all four rar files (in chrome it didn't work but IE does). However, if i try to extract it with either winrar or

  • Elements 12 & Lightroom 4 issues

    I just purchased Elements 12 and use it with Lightroom 4. I can transfer a file to Elements with ease but when I try to transfer it back by hitting file/save, it opens a dialogue box instead of transfering me back to Lightroom and then I have to impo

  • Finding those missing ...

    Hallo everyone, I have one large table covering two periods and would like to find codes (article numbers) in one period which do not appear in the other. With two separate tables or a smaller volume of data this is quite easy as you can either conne