Populate multi record display item

Hellou gurus!
I have forms 10g and i need to populate display item in enter query mode. My problem is that I have table T1 with some static values. Table T2 is through ID connected (reference) to table T1 1:1 cardinality and T2 table also have reference to T3 table.
I have block B2 based on table T2 and in this block I have multirecord item for inserting and updating new values for T2, but in this block ii also have no DB, multi record display item (because i don't want to allow editting in T1 table records) for diplaying static values for table T1. I want to display all static values from T1 next to the editable values in T2 (T2 multi record field is not insert yet). I tried for loop, select into but it not work. T1 values need to be selected before I started to inserting values into T2 items, but off course they need to be referenced It is hard to explain but i belive you understand.
Can you help me how I can populate multi record item??

You have to write the code again for your second list item....
group_id RecordGroup;
list_id Item  := Find_Item('button.tyear');
list_id1 Item  := Find_Item('button.tperiod');
status NUMBER;
rg_name varchar2(40) := 'recgroup';
BEGIN
----------------------------- LIST
clear_list(list_id);
group_id := Find_Group(rg_name);
IF NOT id_null(group_id) then
    Delete_Group(group_id);
End if;
group_id := Create_Group_From_Query(rg_name,
'select vm_year, vm_year from fwqgl.vouchermaster
group by vm_year');
status := Populate_Group(rg_name);
Populate_List(list_id, group_id);
/* --------------------SECOND LIST ITEM...BUT REC. GRP NAME CAN BE SAME,better to use another name if you need to retrieve list and store qry..other wise the fol. code is enuf-----------------------*/
clear_list(list_id1);
group_id := Find_Group(rg_name);
IF NOT id_null(group_id) then
    Delete_Group(group_id);
End if;
group_id := Create_Group_From_Query(rg_name,
'select vm_period, vm_period from fwqgl.vouchermaster
group by vm_period');
status := Populate_Group(rg_name);
Populate_List(list_id1, group_id);
END;Edited by: Dora on Dec 5, 2009 10:41 AM

Similar Messages

  • Multi-Line Display Item

    I need to populate a multi-line display item in Forms 6i.
    The problem that I am having is the actual assignment to the display item.
    For example:
    :DISPLAY_ITEM := '10';
    :DISPLAY_ITEM := '11';
    This makes the display item show the value '11' only.
    I need '10' on the first line and '11' on the second line, etc.
    Thanks in advance,
    Patrick

    well, you can write:
    go_block('BL_BLK');
    first_record;
    :display_item:=10;
    next_record;
    :display_item:=11;
    but for this- 1. block should have one navigable item. 2. display_item should not be the first item of the block.
    Otherwise you will need to create a non-databse text_item with width 0 on the canvas for that block.
    Hope this helps.
    Regards
    Mona

  • Dynamic update if multi-record list item.

    I have a bunch of multi-record list items whose poplist I need to update with queried data at the WHEN-NEW-ITEM-INSTANCE triggers,
    At NEW-FORM-INSATNCE trigger I queried and filled all the poplists with no problem. The problem occurs at the WHEN-NEW-ITEM-INSTANCE triggers.
    I have a clear_list() before each add_list_element() from a runtime record group. The problem is that the poplists at the cursor record is updated correctly, when I click on the same list item at other records, the list repeats -- meaning (probably) it was not cleared before being populated. Is there a way to either (1) just populate the list item of the current record, or (2) clear all records of a list item before all records are populated.
    I tried copy( NULL, current_ilist ) where current_ilist is the item name before add_list_element(), but I got errors because the list items are required fields. Besides, the item has queried data in it.
    I'm thinking about changing the item property to optional, save the item value, set it to NULL, populate its poplist, restore it's original value and then change the item property back to "required'. I don't know if it would work but is there a more elegant way of doing it?
    Any suggestion will be appreciated.

    Hello All,
    Just in case nobody saw this, thought i might post it again.
    would abybody have any pointers,
    easo

  • Record display item/field

    How can I have a field displayed on a form as a list of records? That is e.g status_type as heading with list of all the data records shown on the form.
    Femi

    I did not make myself clear but what I wanted was to have a display-only field/item on a form with all it's values.
    Set the item type to display item and changed the setting for bevel to lowered.
    Thanks.

  • How to do it in multi-record block

    Hi all,
    i have 1 text items in a multi-record block number of record displayed 10
    and i have values like 100 , 50, 30 in first 3 records and in 5th record i want to put some value like
    20 then i want to calculate all values like 100 + 50 + 30 +20 = 200 and i want to put the total value in a single record block.
    but my problem is i cannot able to calculate all the value because for the totale value i have to
    write a for loop to loop through the record
    but go_block() is not working in post_change .
    if any solution is there plz suggest.......

    Hi zeeshan
    my problem is i cannot able to calculate all the value because for the total value
    put the total value in a single record block.
    First pls the following...
    Guidelines for Working with Calculated Items Calculated items_
    1- They are display-only control items.
    2-Calculated items cannot be database items.
    3.While you can set a calculated item's Enabled, Mouse Navigate, and Keyboard Navigable properties to Yes,
    you cannot set the Insert Allowed or Update Allowed properties to Yes
    Second Keyword: TOTAL is a reserved oracle key word... pls read the Details...
    go_block() is not working in post_change .well u can use timers but no need for it u can reference block item but first u have to accumulate the values per record in WHEN-VALIDATE-ITEM TRIGGER in the last calculated item which is inserted by the user and assign it to the display item in ur current multi-record block :*block_name.total_item*.. as follow...
    :block_name.total_item := :item1 + .... ; Then u create a second display item > no of records property = 1 , named e.g. final_summarized_totals
    In order to summarize this total values accumulated in the multi-record display item named e.g. block_name.total_item
    Finally using PRE-INSERT , PRE-UPDATE,PRE-DELETE Triggers to assign the value calculated into the display item * block_name.total_item* into the db_item into the previously mentioned Trigger Block-Level Off-course.
    :block_name.total_db_tem := :i:block_name.final_summarized_totals ; Hope this helps...
    Regards,
    Amatu Allah

  • Multi-record stacked itemgroups

    Hello,
    I have a problem with Designer6, using Headstart6.
    I want to generate a multi-record stacked item-group with overflow below. This far everything goes all right. Designer generates a content canvas with a tab-canvas on it. On each tab-page, it generates an item-group. But when I want to compute a sum-function over an item in that item-group, designer decreases the number of records displayed from 10 to 1. (CGEN-1381: Warning: component GRM1 required number of rows 10 reduced to 1)
    Can someone help me with this problem?
    Martine Vanderveken,
    Stienstra.

    Hi Gerd,
    UNDER WHEN-NEW-RECORD-INSTANCE
    i used this code
    DECLARE
    blk_id Block;
    BEGIN
         /* Lookup the block's internal ID */
         blk_id := Find_Block('CURRENCY_MASTER');
         /* ** If the block exists (ie the ID is Not NULL) then set
         ** the three properties for this block. Otherwise signal
         ** an error. */
         IF NOT Id_Null(blk_id) THEN
              Set_Block_Property(blk_id,INSERT_ALLOWED,PROPERTY_FALSE);
              Set_Block_Property(blk_id,UPDATE_ALLOWED,PROPERTY_FALSE);
              Set_Block_Property(blk_id,DELETE_ALLOWED,PROPERTY_FALSE);
         ELSE
              Message('Block '||'CURRENCY_MASTER'||' does not exist.');
              RAISE Form_Trigger_Failure;
         END IF;
         END;
    when queried it restrict from insert/update/delete to all rows
    but i want the last record to be enable and can be update/delete
    or can insert another record at last.which is not possible with the above code.
    help me out pls.!

  • Problem in displaying records in multi record block

    Hi all,
    I have a problem in displaying records in a multi record block in a form.
    I have 1 control block and 1 data block(multi-record block).
    Control block has one item CUSTOMER-ID. Data block has many other items related to customer.
    when a value is entered in customer-id text item, all the relavant details should be displayed in the data block.
    but, the records are overlapping in the same line in the data block, actually they have to be displayed one record per one line.
    The code is,
    IF :CUST_BLOCK.CUST_ID IS NOT NULL THEN
    GO_BLOCK('XBSI_CONTRACT_PRICE_FACTORS');
    FOR C1 IN C
    LOOP
    :XBSI_CONTRACT_PRICE_FACTORS.CUST_ID:=c1.site_use_id;
    :XBSI_CONTRACT_PRICE_FACTORS.CAT_ID:=c1.ipc_category_id;
    :XBSI_CONTRACT_PRICE_FACTORS.MFG_ID:=c1.mfg_category_id;
    :XBSI_CONTRACT_PRICE_FACTORS.INVENTORY_ITEM_ID:=c1.inventory_item_id;
    :XBSI_CONTRACT_PRICE_FACTORS.PRICE_BASIS:=c1.price_basis;
    :XBSI_CONTRACT_PRICE_FACTORS.PRICE_FACTOR:=c1.price_factor;
    END LOOP;
    Please help me out..
    Thanks in advance!
    Suman

    Hi Suman
    IF :CUST_BLOCK.CUST_ID IS NOT NULL THEN
    GO_BLOCK('XBSI_CONTRACT_PRICE_FACTORS');
    first_record;
    FOR C1 IN C
    LOOP
    :XBSI_CONTRACT_PRICE_FACTORS.CUST_ID:=c1.site_use_id;
    :XBSI_CONTRACT_PRICE_FACTORS.CAT_ID:=c1.ipc_category_id;
    :XBSI_CONTRACT_PRICE_FACTORS.MFG_ID:=c1.mfg_category_id;
    :XBSI_CONTRACT_PRICE_FACTORS.INVENTORY_ITEM_ID:=c1.inventory_item_id;
    :XBSI_CONTRACT_PRICE_FACTORS.PRICE_BASIS:=c1.price_basis;
    :XBSI_CONTRACT_PRICE_FACTORS.PRICE_FACTOR:=c1.price_factor;
    next_record;
    END LOOP;
    Try this. you are trying to show all the records in same line. so its overlapping.
    Thankyou
    [email protected]

  • Conditionally display an icon for each record in a multi record block

    Hi,
    I am using Forms 6i. Is there any way to conditionally display an icon for each record in a multi record block. The SET_ITEM_INSTANCE_PROPERTY builtin does not have many choices. Thanks for your help.

    Henry,
    I doubt that. You would have to replace the text item with an image item. This however can't be done for individual cells in a table but only for the whole column.
    On the web chances are that these could be handled with a custom PJC, but this solution doesn't work in client/server
    Frank

  • How to set default settings to display record count in multi record block

    Hi All
    Whenever I query my multi record block, I get 1/? as record count at the console in standard Oracle Applications. Is there any setting so that it displays 1/50 (in case total record queried is 50). I don't want to set query all property of block as I don't have any control in standard Apps forms.
    Thanks in advance
    Navdeep

    Check out the next_navigation_item option for the get_item_property procedure. If you use this you can do the process without having to navigate from one item to the next.
    You can do something like this (untested) to move and resize the items (other than the first in the block):
    PROCEDURE move_and_resize(p_item IN ITEM, p_width IN PLS_INTEGER) IS
      prev_item ITEM := Get_Item_Property(p_item, PREVIOUS_NAVIGATION_ITEM);
    BEGIN
      Set_Item_Property(p_item, WIDTH, Get_Item_Property(p_item, WIDTH) + p_width);
      Set_Item_Property(p_item, X_POS, Get_Item_Property(prev_item, WIDTH) +
                                       Get_Item_Property(prev_item, X_POS));
    END move_and_resize;
    move_and_resize(myitem, -30);

  • Updating a value of a text item in a multi record block based on a change

    Hi,
    I need to change the value of a text item in a multi record block based on a change to another item's value in the same block.
    Suppose there's a text item in a multi record block called dt1 which is of type date, which is changed in a particular record. I want to change the values of the another item in the same multi record block, for all other records by running a loop through all the records in multi record block. I dont want to do it on the press of a button, it should do automatically on change. Help me resolve this issue.

    Hi,
    I need to change the value of a text item in a multi record block based on a change to another item's value in the same block.
    Suppose there's a text item in a multi record block called dt1 which is of type date, which is changed in a particular record. I want to change the values of the another item in the same multi record block, for all other records by running a loop through all the records in multi record block. I dont want to do it on the press of a button, it should do automatically on change. Help me resolve this issue.

  • Change number of record displayed for a single item alone

    Hi,
    I have a single data block with few items. Is it possible to make one item in the block as non-database item and make the display of record in the item alone to show multiple lines.
    i.e. All other items in the Data block shows single record, whereas this particular item should shows 10 records.
    Is this achievable?
    Or should i have to put that item in a separate data block and choose the data block property to "Number of records displayed" as 10?
    Thanks,
    Yuvaraaj.

    983448 wrote:
    Hi,
    I have a single data block with few items. Is it possible to make one item in the block as non-database item and make the display of record in the item alone to show multiple lines.
    i.e. All other items in the Data block shows single record, whereas this particular item should shows 10 records.Yes you can. But i will say re-check your design.
    Hamid
    Mark correct/helpful to help others to get right answer(s).*

  • New lines created in excel when displaying multi-line text item value

    Hi all,
    I put the value of a multi-line text-item into a csv file :
    DECLARE
    file_filter VARCHAR2(256) := 'Export Files (*.csv)/*.csv/All Files (*.*)/*.*/';
    fExp VARCHAR2(256);
    in_file Text_IO.File_Type;
    linebuf VARCHAR2(4000);
    BEGIN
    fExp := get_file_name ( directory_name, file_name, file_filter, NULL, SAVE_FILE, TRUE);
    IF fExp IS NOT NULL
    THEN
    set_application_property(cursor_style,'BUSY');
    in_file := Text_IO.Fopen( fExp, 'W');
    linebuf := NVL(:com_bnc_possibles.LIBEL_TRAITE,'') || ';' ||
    NVL(:com_bnc_possibles.NUM_ANFR_ID,'') || ';' ||
                             NVL(:com_bnc_possibles.ver_fiche,'') || ';' ||
                             NVL(:com_bnc_possibles.titre,'') || ';' ||
    NVL(to_char(:com_bnc_possibles.date_creat, 'dd/mm/yyyy'),'') || ';' ||
    NVL(to_char(:com_bnc_possibles.date_valide, 'dd/mm/yyyy'),'') || ';' ||
    NVL(:com_bnc_possibles.LIBEL_STATUT,'') || ';' ||
    NVL(:com_bnc_possibles.label_reg,'') || ';' ||
    NVL(:com_bnc_possibles.nom,'') || ';' ||
    NVL(:com_bnc_possibles.prenom,'') || ';' ||
    NVL(:com_bnc_possibles.nom_societe,'') || ';' ||
    NVL(:com_bnc_possibles.comp_bnc,'') || ';' ||
    NVL(:com_bnc_possibles.motifs,'') || ';' ;
    Text_IO.Put_Line( in_file, linebuf);
    Text_IO.Fclose( in_file);
    set_application_property(cursor_style,'DEFAULT');
    END IF;
    END;
    And when I opened the csv file then the remaining lines , that is from the second line , of the column "motifs" are displayed through the column A of excel. The "motifs" multi-line text-item has 500 as its Maximum Length property value, and has a Char Data Type property value.
    So how to display all the motifs' lines through the same column M without displaying the remaining lines in column A ?
    Or are there tips to remove CHR(13) characters from a multi-line text-item ?
    Thank you very much indeed.
    Message was edited by:
    andrianiaina

    Hi,
    I tried to do it in different way. What i did is I have created a item of type formattted text and set its text like:--
    <html>User authentication failed. <br*> Cause: Invalid password.</html> --remove *
    So I am able to see the prompt like :-
    User authentication failed.
    Cause: Invalid password.
    Hope this helps you...
    Thanks
    --Anil                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • How to change the Height of item....!!!! in multi record block

    Here is the problem I want to change one item height in multiple records block..
    I tried to do the following
    set_item_instance_property(:system.mouse_item,:system.current_record,height,50);
    But this didn't work as the property for height couldn't be used with this built in..
    Can any one tell me any other suggestion to move around
    Thanks and best regares

    If you just have two sizes to display - e.g. normally the item is 1 line high but in the current item you want to show more information and want to make it say 2 lines high, then you can use a Mirror item to do this.
    Create another item in the block - set the Synchronize With Item property to the base item you want to "Resize".
    Set the Records Displayed property to 1 for this extra field.
    Put this field on a stacked canvas that is just big enough to hold it.
    The in your When-New-Record Instance trigger you can pop the stacked canvas up over the normal version of the field.
    That should do the trick.

  • Number of items/records display

    I want to set the number of items/records display base on query. I tried Set_Block_Property and Set_Item_Property, they don't have any option for me to set it dynamically. Any ideas?
    Thanks

    A couple:
    a) Set QUERY ALL RECORDS to YES, and programmaticaly set MAXIMUM RECORDS FETCHED.
    b) in a POST-QUERY block-level trigger, check the :system.trigger_record. When it reaches the number you want, issue an ABORT_QUERY built-in.
    Hope this helps,
    Pedro

  • About populating a non-database item in a multi-records block

    Hi, all
    I have a problem about populating a non-database item in a
    multi-records block. This block is set to database block with a
    controlled item which needs to be populated after query. so I
    create a post-query trigger, but my problem is when the records
    listed in this block are less than 10 ( the record number is set
    to 10), the trigger fires no problem. but when the retrieved
    records are greater than 10, the error message is 'post query
    trigger raised unhandled exception ora 01403'. anyone can help me
    fix this problem?
    Thanks in advance
    Diana

    Diana,
    When you have an unbound item in a block and want to fetch
    some data into it you need to write a post-query trigger.What
    you have done is right.But it seems that u are getting a No data
    found error.I am sure about how u r populating data into that
    field.If u have written a select statement to fetch the data in
    post-query trigger, kindly handle an exception and find out the
    problem.Having a look at ur code(pos-query) would be much more
    helpful for giving a better solution.Try this a let me know.
    Thanks
    Vinod.

Maybe you are looking for

  • SAP Alert Not Triggering

    Hi, I seem to have an issue with two SAP Alerts that I setup. 1) One Alert is set to trigger every day morning at 9 AM. 2) One Alert is to trigger every day night at 11 PM. The first alert set to trigger in the morning is works fine Monday to Friday.

  • IPOD NANO-Windows delayed write failed...

    I just bought an IPOD NANO 4gb yesterday... Downloaded ITunes and have been having problems getting it to SYNC music to my IPOD. It keeps throwing the "windows delayed write failed" error. No other errors present. I havent been able to get any music

  • Ipod: Unable to reset or restore

    My Ipod (click wheel) will not reset or restore. The apple logo appears on the Ipod screen, followed by the file with an exclamation point. I have tried to use Ipod updater without success. The Ipod does not register that it is charging either when p

  • MBeans + OAS-10.1.2

    Hi, I am using OAS-release 2 and interested to use JMX features such as MBeans, MBeanServer etc., Let me know whether these features are supported in release 2. I would like to monitor my application using JMX features Thanks.

  • "Memory nearly full" on E61 when trying to open a ...

    When trying to open a pdf document (email attachment) I got the message "Memory nearly full. The list of documents last opened will be displayed". I tried to free up some memory, but when checking, I learnt that there was space to waste in my phone m