Lov & record group problem

Hi
I have to achieve this task.
I have "company_list" record group and "company_list" lov
I am form layout style. I am in Enter-query. Then give some value to any field. Then Click execute-query. Its retreiving some records.
Now if I click the LOV can I show only those records currently I have retreived.
I have following trigger on button pressed.
It is giving 1)error Populating group.2)cannot create group company_list 3) error_populating group.
Anybody pl help me.
Christy.
DECLARE
cur_blk VARCHAR2(40) := :System.Cursor_Block;
last_qry varchar2(2000);
bk_id Block;
rg_name VARCHAR2(40) := 'COMPANY_LIST';
rg_id RecordGroup;
errcode number;
BEGIN
bk_id := Find_Block(cur_blk);
last_qry := Get_Block_Property( bk_id, LAST_QUERY);
rg_id := Find_Group('COMPANY_LIST');
IF NOT Id_Null(rg_id) THEN
DELETE_GROUP(rg_id);
END IF;
rg_id := Create_Group(rg_name);
errcode:=Populate_Group_With_Query(rg_id,last_qry);
end;

I think that you have to use Create_Group_From_Query() instead of Create_Group():
rg_id := Create_Group_From_Query(rg_name);
Helena
null

Similar Messages

  • URGENT : Record Group Problem

    hello all
    i have a problem regarding record group.
    i want to populate my record group with a dynamic clause which is
    "and main_code not in ('02725','02868')"
    and my record group query is
    "select mt.main_number from main_table mt,main_parent mp
    where mt.main_code = mp.main_code
    and mt.main_code not in (:parameter.param_main_code)"
    now i am adopting the following method for populating the
    LOV(list of values) which is attached to a text item:
    assigning values i.e. '02725','02868' to my parameter object i.e. :parameter.param_main_code but the record group is not giving changd results according to my criteria i.e.'02725','02868'...
    does any body knows the solution for this problem..kindly help him with it..logically the record group query should work and return a changed results for the LOV..
    please help me with this.....
    thank you.

    I thing you can't able to do what you are trying to do, but you can achive this by using dynamic record group.
    Create the dynamic record as same struncture of design time then populate it by the coding.
    Sample Code is
    declare
         l_rec_name RecordGroup;
         l_rec_col GroupColumn;
         l_rec_col1 GroupColumn;     
         cursor l_ename is select ename from emp;
         l_row number(12):= 1;
    begin
         l_rec_name := create_group('rg_dynamic',Form_scope, 100);
         l_rec_col := add_group_column(l_rec_name,'ENAME',char_column,30);
         l_rec_col1 := add_group_column(l_rec_name,'EMPNO',number_column,6);     
         for i in l_ename
         loop
              add_group_row(l_rec_name, end_of_group);
    set_group_char_cell(l_rec_col,l_row, i.ename);
    set_group_number_cell(l_rec_col1,l_row, l_row);
    l_row := l_row+1;
         end loop;
         :parameter.num_rows := l_row -1;
         set_lov_property('LOV5',group_name,'RG_DYNAMIC');
    end;
    I hope this will help you to solve this problem.
    [email protected]

  • Change lov record group dynamilcally

    Please provide me solution :-
    declare
         l_id lov;
         rg_id recordgroup;
         n boolean;
    begin
         l_id := find_lov('LOV14');
         rg_id := find_group('LOV14');
         if get_lov_property('LOV14',group_name) = 'LOV14' then
              message('found');
              message('found');
         --     end if;
    --     if not id_null(rg_id) then
         --     delete_group(rg_id);
              set_lov_property(l_id ,group_name, 'NEW_RG');
         --     message('group has been changed');
         --     message('group has been changed');
              n:= show_lov('LOV14');
         end if;
         end;
    i tried this code . but neither its giving error nor doing work. please help me

    thanks for reply sir, bt problem is :---
    my lov name is 'LOV14' and same name as record group 'LOV14' , now i hav to button on my form ;
    i want to show lov at button first . as well as i want change record group dynamicly at button second.
    first record group name is "LOV14' and another is "NEW_RG'. and run time i want to change NEW_RG record group at the place of LOV14.
    declare
         l_id lov;
         rg_id recordgroup;
         n boolean;
         x number;
    begin
         l_id := find_lov('LOV14');
         rg_id := find_group('LOV14');
         if get_lov_property('LOV14',group_name) = 'LOV14' then
              message('found');
              message('found');
         --     end if;
    --x :=     POPULATE_GROUP('NEW_RG');
    --     if not id_null(rg_id) then
         --     delete_group(rg_id);
         if not id_null (rg_id) then
              delete_group(rg_id);
              end if;
              set_lov_property(l_id ,group_name, 'NEW_RG');
         --     message('group has been changed');
         --     message('group has been changed');
         --     n:= show_lov('LOV14');
         end if;
         end;

  • Record group problem

    hi all
    i make a record group in my form (developer 6i).
    in runtime i want to find a special record in this record group.
    what is the best way?
    thanks in advance.
    shoja

    You can loop through the members of the record group using GET_GROUP_ROW_COUNT to get the number of members and then the various get_group_..._cell built-ins to get the value of a column for each row

  • Dynamic Record Group problem

    I am trying to assign LOV to a field on 6i form programatically. Here is the procedure I created.
    PROCEDURE XXSAG_RECGROUP IS
    XXSAG_ACCOUNT_RG               RECORDGROUP;
    val                                   number;
    val_chosen               boolean;
    raise_error               exception;
    BEGIN
    if (id_null(XXSAG_ACCOUNT_RG)) then
    XXSAG_ACCOUNT_RG := Create_Group_From_Query('ACCOUNT_NUMBER','select account_number'||' from xxsag_prod_producer_info'
                   ||' where production_id = :xxsag_prod_main.production_id'
                   ||' and account_type = :xxsag_prod_producer_info.account_type ');
                   val := Populate_Group(XXSAG_ACCOUNT_RG);
                   If val != 0 then
                        delete_group(XXSAG_ACCOUNT_RG);
                        raise raise_error;
                   End If;     
                   set_lov_property('ACCOUNT_NUMBER_LIKE',GROUP_NAME,'XXSAG_ACCOUNT_RG');
                   set_item_property('XXSAG_PROD_PRODUCER_INFO.ACCOUNT_NUMBER',LOV_NAME,'ACCOUNT_NUMBER_LIKE');
                   delete_group(XXSAG_ACCOUNT_RG);
              end if;     
    END;     
    However, when the cursor goes to the field, I see the LOV toolbar but no records show up. Please help.
    Thanks.

    Please explain why you need to create the group during run-time. I don't see anything in your code that might require this.
    Are you just trying to change the contents of the LOV based on the values in production_id and account_type? I think setting Automatic Refresh to YES might do it.

  • Dynamic record group

    Please explain me step by step to create dynamic record group and populate it into my combo box.
    thanks
    rupal
    Edited by: rupearlkaushal on Jun 13, 2012 9:39 PM

    hi
    plz check out the following threads.
    Dynamic creation of record group
    and
    Dynamic Record Group
    LOV (List of Values)
    LOV is nothing but a form item which is used to provide list of values to a text field.
    Each LOV contains a Record Group which provides the data to the LOV
    Record Group
    A record groups contains the query which is used to populate the values to the LOV.
    To alter a list of values(LOV) of a text field, we should change the query of the
    record group which is attached to the corresponding LOV or we should create a
    new record group and attach it to the existing LOV.
    Note : We cant create a new LOV. But we can attach a exsiting LOV to a form field.Method 1: Changing the query of the existing Record group
    declare
    rg_id RECORDGROUP ;
    err number;
    lv_id lov;
    begin
    rg_id:=find_group('LOV4'); -- LOV4 is the name of the existing LOV
    if not id_null(rg_id) then
    err:=populate_group_with_query(rg_id,
             'select deptno from dept where dname=''SALES''');
    end if;
    lv_id:=find_lov('LOV4');
    set_lov_property(lv_id,group_name,rg_id);Method 2: Creating a new Record Group if doesn't exists
    declare
    rg_id recordgroup;
    pg_num number;
    lv_id lov;
    begin
    rg_id:=find_group('MYGROUP');  -- MYGROUP is the Group Name
    if id_null(rg_id) then
    rg_id:=create_group_from_query('MYGROUP','SELECT 100 deptno FROM dual');
    end if;
    pg_num:=populate_group(rg_id);
    lv_id:=find_lov('LOV4');sarah
    Edited by: Sarah on Jun 13, 2012 9:56 PM

  • Static record group and lov problem

    hi all,
    1)I created a form module
    2)created a basic datablock based on empno and ename from emp table.
    3) created a static record group ,where i specified the column name as col1,provided the values as 1 ,2,3,4,5 etc
    4) created an LOV and assigned the above record group to the LOV
    5) then assigned the lov to the emp.empno item in the datablock emp....
    when i run the form .....i get the list of values message on the console (bottom end of the window) ....
    but I am not able to see the LOV when i press the cntrl L or see it from the edit menu command ?
    what must be the problem ?
    ta
    s

    Dear,
    May be you don't set LOV's "Column Mapping Properties". After setting the properties correctly you will be able to display LOV.
    Thanks.

  • Dynamically  populate  a  record  group  on  the  fly uisng LOV

    Hi,
    I want to create dynamically populate a record group on the fly uisng LOV.
    1. This is how the RG_BANKNAME Record Group object look like
    Object : Record Group
    Name : RG_BANKNAME
    Record Group Query : SELECT NAME, SHORT_NAME FROM C_BANKS
    2. I create the Push Button and when user click it will popup the LOV.
    DECLARE
         rg_id RecordGroup;
         errcode NUMBER;
         status BOOLEAN;
    BEGIN
         rg_id := Find_Group('RG_BANKNAME');
         IF Id_Null(rg_id) THEN
              Message('No such group: ',ACKNOWLEDGE);
              RAISE Form_Trigger_Failure;
         ELSE
              errcode :=POPULATE_GROUP(rg_id);     
              SET_LOV_PROPERTY('LV_NAME', TITLE, 'My Own LOV');
              SET_LOV_PROPERTY('LV_NAME', GROUP_NAME, rg_id);
              SET_LOV_COLUMN_PROPERTY('LV_NAME', 1 ,Title, 'NAME');
              SET_LOV_COLUMN_PROPERTY('LV_NAME', 1 ,Width, 150);     
              SET_LOV_COLUMN_PROPERTY('LV_NAME', 2 ,Title, 'SHORT NAME');
              SET_LOV_COLUMN_PROPERTY('LV_NAME', 2 ,Width, 100);     
              status := Show_LOV('LV_NAME',10,20);
              IF NOT status THEN
                   Message('You have not selected a value.');
                   Bell;
              END IF;
         END IF;
    END;
    My question is do I need to create the LOV Object name call 'LV_NAME'? since I don't have this
    create on my design times, because I thought it can be done dynamically on the fly.
    The problem is compliant that the Lov Id is not valid.
    Thanks
    David
    Edited by: user445990 on May 24, 2011 9:19 PM

    Hello,
    You request is not clear. Do you need to display the LOV or not ? In other words, what is the goal of your record group ?
    Francois

  • Strange Problem in dynamically list population with record group

    Hello Room,
    I am dynamically populating a single list with 2 record groups. I am having a strange problem. All the code are written in 2 seperate buttons. The code of every button is given below.
    Button 1 code:-
    DECLARE
    rg_reports RECORDGROUP;
    rg_name VARCHAR2(40) := 'REPORTS';
    vTemp NUMBER;
    BEGIN
    -- Pls make sure Group doesn't already exist
    rg_reports := FIND_GROUP(rg_name);
    -- If it doesn't exist then create it and add ur query to it
    IF Id_Null (rg_reports) THEN
    rg_reports:=CREATE_GROUP_FROM_QUERY(rg_name , 'SELECT companyname,to_char(co) from companymaster order by companyname');
    end if;
    --Populate the Record Group
    vTemp:=POPULATE_GROUP(rg_reports);
    POPULATE_LIST('REPORTS.EXAMPLELIST', rg_name);
    Delete_Group( rg_reports );
    END;
    Button 2 Code:-
    DECLARE
    rg_reports RECORDGROUP;
    rg_name VARCHAR2(40) := 'REPORTS';
    vTemp NUMBER;
    BEGIN
    -- Pls make sure Group doesn't already exist
    rg_reports := FIND_GROUP(rg_name);
    -- If it doesn't exist then create it and add ur query to it
    IF Id_Null (rg_reports) THEN
    rg_reports:=CREATE_GROUP_FROM_QUERY(rg_name , 'SELECT accountname,to_char(co) from accountmaster order by accountname');
    end if;
    --Populate the Record Group
    vTemp:=POPULATE_GROUP(rg_reports);
    POPULATE_LIST('REPORTS.EXAMPLELIST', rg_name);
    Delete_Group( rg_reports );
    END;
    The code is same here only the sql is different in these 2 buttons. Now the problem point.
    when i press button 1, I get the list populated ok. when i try to click on the list item and keep the button pressed the list gets scrolled properly.
    when i press button 2 after that i get account names well populated in the same list item as well, but this time, when i keep the button pressed the list does not scroll below as in button 1. It does not even allow to select different item from the list of button 2 code.
    I tried to clear cache, cookies, exit browser everything and try to run the button 2 first, but still the problem in button 2 code.
    Following are my system details.
    windows 7 professional edition.
    Oracle database 11g on windows 7
    Oracle forms 10g patchset 10.1.2.0.2 on windows 7
    Browser Netscape Navigator with oracle jinitiator 1.3.1.22
    But this form is run by a client side html file where oracle forms 10g is not installed on windows xp. html file is just referring server url to run the module. The file is run on Netscape navigator browser with oracle jinitiator 1.3.1.22
    My question is that is this a bug ? if button 1 gets the list item scrolled, why is the problem with button 2 even though i press it first. Here I am deleting the record group also. after the code is over. Initially I thought this may be the character length problem so I took the maximum character length for that list item as given by the 2 columns in database.
    Why is the list scrolling not happening in button 2 but in button 1 with same codes on both ?
    Anybody please help me.

    The problem is the second query. I would guess that the TO_CHAR(co) is not unique for each account, but is the same for the accounts. And as the second item in the select-list is the listitems values, all your listitem-entries have the same value. therefore, of you select any entry, the list will always go the the first entry again.
    Adjust your query.

  • Creation of Record Group and LOV at run time

    Hello All,
    I have been stuck by this...I have two text items on which LOVs have been placed.Selection of one depends on selection of other.I can dynamically create a record group but how to create a LOV dynamically to populate it with the dynamic record group been created.
    For more visualization consider that filtering of data takes place in one lOV based on the other LOV been provided.
    Revert ASAP...
    Thanks and Regards,
    Kapil Uppal

    I don't think you can create a LOV dynamically, but you can repopulate a pre-existing one, which should allow you to achieve the same goal.

  • (urgent) Dynamic record groups and LOV

    I have to create a record group and then add 2 rows to it manually.Following is the code.There are no values displayed in the lov.Please help.
    PROCEDURE create_record_group IS
    BEGIN
    DECLARE
    rg varchar2(40) := 'test_fips';
    rg_id RECORDGROUP;
    lov_id Lov;
    err NUMBER;
    gc_id1 GROUPCOLUMN;
    gc_id2 GROUPCOLUMN;
    counter number;
    BEGIN
    rg_id := FIND_GROUP(rg);
    lov_id := FIND_LOV('LOV_FIPS');
    IF NOT ID_NULL(rg_id) THEN
    DELETE_GROUP(rg_id);
    END IF;
    IF ID_NULL(rg_id) THEN
    rg_id := CREATE_GROUP(rg);
    gc_id1 := add_group_column (rg_id,'col1',number_column);
    gc_id2 := add_group_column(rg_id,'col2',char_column,40);
    END IF;
    /* adding static content to LOV */
    ADD_GROUP_ROW( rg_id,1);
    SET_GROUP_NUMBER_CELL(gc_id1,1,997);
    SET_GROUP_CHAR_CELL(gc_id2,1,'MLAB');
    counter := get_group_row_count(rg_id);
    /* adding dynamic content */
    FOR rec in (SELECT FIPS_CD COL1, LOCNAME COL2 FROM FIPS) LOOP
    counter := counter +1 ;
    ADD_GROUP_ROW( rg_id, counter);
    SET_GROUP_NUMBER_CELL(gc_id1,counter,rec.col1);
    SET_GROUP_CHAR_CELL(gc_id2,counter,rec.col2);
    END LOOP;
    SET_LOV_PROPERTY('LOV_FIPS',GROUP_NAME, rg);
    END;
    END;

    I tried creating the group the way you suggested but it does not seem to work because of 'UNION' in the query.It says unable to create rcord group.Did you anytime use the 'UNION' option while creating record group.
    While creating record group at design time also you cannot use UNION with dual.
    This how I modified :
    PROCEDURE create_record_group IS
    BEGIN
    DECLARE
    V_RG_ID RECORDGROUP;
    RG_NAME VARCHAR2(20) := 'TEST_FIPS';
    V_ERRCODE NUMBER;
    BEGIN
    V_RG_ID := FIND_GROUP('TEST_FIPS');
    IF ID_NULL(V_RG_ID) THEN
    V_RG_ID := CREATE_GROUP_FROM_QUERY('TEST_FIPS', 'SELECT FIPS_CD, LOCNAME FROM FIPS
    UNION SELECT 997,'MLAB' FROM DUAL');
    END IF;
    V_ERRCODE := POPULATE_GROUP(V_RG_ID);
    MESSAGE('CREATED '|| V_ERRCODE);
    SET_LOV_PROPERTY('LOV_FIPS',GROUP_NAME, RG_NAME);
    END;
    END;
    Notice here 'MLAB' is char and I get compilation error if I use these quotes with MLAB.But is I remove the quotes the it compiles.
    Thanks

  • LOV with 3 record groups

    I have two LOV s one in the mainform and one in the subform. If I select one category from the list in the mainform LOV. In the subform LOV has to change it's record group (3 record groups) depending on the category selected in the mainform LOV. Please help. I am pasting the code I wrote. I tried it in the NEW ITEM INSTANCE TRIGGER, NEW BLOCK INSTANCE TRIGGER (datablock for the 2nd LOV with 3 record groups) and in the NEW FORM INSTANCE TRIGGER. Please help. Thank you.
    DECLARE
    lov_id1 LOV;
         --val          boolean;
              rg_id1 RECORDGROUP;
         rg_id2 RECORDGROUP;
              rg_id3 RECORDGROUP;
    BEGIN
    lov_id1 := FIND_LOV ('ACTIVITYTYPE_LOV');
         rg_id1 := FIND_GROUP('ACTIVITYTYPE_RG1');
         rg_id2 := FIND_GROUP('ACTIVITYTYPE_RG2');
         rg_id3 := FIND_GROUP('ACTIVITYTYPE_RG3');
    --     val := SHOW_LOV(lov_id1, 32, 48);
    IF
         GET_LOV_PROPERTY(lov_id1,GROUP_NAME ) = 'rg_id1' AND :YOUTH_GOALS.GOAL_TYPE = 'EXIT COUNSELING'
         THEN SET_LOV_PROPERTY(lov_id1,GROUP_NAME,'rg_id1');
         ELSIF
         GET_LOV_PROPERTY(lov_id1,GROUP_NAME ) = 'rg_id1' AND :YOUTH_GOALS.GOAL_TYPE = 'COMPLETE TRAINING'
         THEN SET_LOV_PROPERTY(lov_id1,GROUP_NAME,'rg_id1');
              ELSIF
         GET_LOV_PROPERTY(lov_id1,GROUP_NAME ) = 'rg_id1' AND :YOUTH_GOALS.GOAL_TYPE = 'VOCATIONAL TRAINING'
         THEN SET_LOV_PROPERTY(lov_id1,GROUP_NAME,'rg_id2');
              ELSIF
         :YOUTH_GOALS.GOAL_TYPE = 'GRADUATE FROM HIGH SCHOOL'AND GET_LOV_PROPERTY(lov_id1,GROUP_NAME ) = 'rg_id1'
         THEN SET_LOV_PROPERTY(lov_id1,GROUP_NAME,'rg_id2');
              ELSIF
         :YOUTH_GOALS.GOAL_TYPE = 'IMPROVE ACADEMIC PERFORMANCE'AND GET_LOV_PROPERTY(lov_id1,GROUP_NAME ) = 'rg_id1'
         THEN SET_LOV_PROPERTY(lov_id1,GROUP_NAME,'rg_id2');
              ELSIF
         :YOUTH_GOALS.GOAL_TYPE = 'OBTAIN GED'AND GET_LOV_PROPERTY(lov_id1,GROUP_NAME ) = 'rg_id1'
         THEN SET_LOV_PROPERTY(lov_id1,GROUP_NAME,'rg_id2');
              ELSIF
         :YOUTH_GOALS.GOAL_TYPE = 'NON-ACADEMIC'AND GET_LOV_PROPERTY(lov_id1,GROUP_NAME ) = 'rg_id1'
         THEN SET_LOV_PROPERTY(lov_id1,GROUP_NAME,'rg_id3');
         END IF;
    end;

    try on when-validate-item or on POST-CHANGE
    Regards,
    Danish Hayder

  • One LOV multiple Record Groups

    Hi all
    I have 2 text items text A and Text B
    on text A i have a list with two items Say 'cricket' and 'football'
    I have two record groups 'Cricket' and 'football'
    If i select 'cricket' from text A then the LOV for text B should have the 'Cricket' record group attached
    and if i select 'football' from text A then the LOV for text B should have the football record Group attached
    Please tell me how to do it
    Thanks in advance

    Hi,
    why don't you just create two LOV's and exchange them on the fly?
    WHEN-VALIDATE-ITEM Trigger on "A" :
    IF( :A = 'cricket' )
    THEN
    set_item_property( 'B', LOV_NAME, 'Cricket' );
    ELSIF( :A = 'football' )
    THEN
    set_item_property( 'B', LOV_NAME, 'Football' );
    ELSE
    set_item_property( 'B', LOV_NAME, NULL );
    END IF;
    Another possibility would be to create a KEY-LISTVAL Trigger on "B" use "show_lov" to switch between both LOV's.
    Regards
    Markus

  • Record groups and LOV

    HI
    I have a question regarding LOV's.
    I have 2 fields dept_code which is a checkbox and field2 which is an LOV displaying the employee names based on the dept_code selected.
    My record group has a query like this -
    SELECT empname FROM emp WHERE dept_code IN(:parameter.P_dept_code). p_dept_code is char.
    If the user enters multiple department codes then my p_dept_code should contain commas and single quotes for each department like this ('m10','m20')
    In which trigger do I do this coding and how do I do it?
    Thanks.

    Hi
    Thanks for your response.
    The key-listval does'nt seem to firing.
    When I run the form the lov comes up but displays the value 2 which is from the default record group(select 1 "dno", 2 "ename" from dual).
    This is the code in my key-listval -
    DECLARE
    rg_name VARCHAR2(40) := 'name_rg';
    rg_id RecordGroup;
    gc_id GroupColumn;
    errcode NUMBER;
    BEGIN
    rg_id := Find_Group(rg_name);
    IF Id_Null(rg_id) THEN
    rg_id := Create_Group(rg_name);
    gc_id := Add_Group_Column(rg_id, 'dno',
    CHAR_COLUMN,10);
    gc_id := Add_Group_Column(rg_id, 'empno',
    CHAR_COLUMN,100);
    END IF;
         :parameter.p_dno := ''''||replace(:parameter.p_dno,',',''',''')||'''';
    errcode := Populate_Group_With_Query( rg_id,
    'select dno dno, ename ename from emp1 where dno in ('|| :parameter.p_dno|| ')' );
    set_lov_property('name_lov', GROUP_NAME, rg_name);
    list_values;
    message(errcode);
    END;
    Please let me know what I'm doing wrong
    TIA

  • Assigning different record groups to a single LOV

    I have an LOV named as ship_refrence and this is how i display
    DECLARE
         a_value_chosen BOOLEAN;
    BEGIN
         a_value_chosen := Show_Lov('ship_refrence');           
    END; and the corresponding query for
    the RG1 is
    SELECT ALL TBLOBLIGATION.MATID, TBLOBLIGATION.MATCODE, TBLOBLIGATION.DESCRIPTION,
    TBLOBLIGATION.PARTNO, TBLOBLIGATION.DESCRIPTION1, TBLOBLIGATION.PARTNO1, TBLOBLIGATION.MANUFACTURER,
    TBLOBLIGATION.NETYPE, TBLOBLIGATION.CAT2, TBLOBLIGATION.CAT3,
    TBLOBLIGATION.CAT5, TBLOBLIGATION.CAT6, TBLOBLIGATION.CAT7, TBLOBLIGATION.COMMCODE,
    TBLOBLIGATION.NSMCODE, TBLOBLIGATION.UNIT_TYPE_ID
    FROM TBLOBLIGATION Now i have created
    RG2
    select matcode,description,partno1,description1,partno1 from tblobligation where cat2!='C'
    RG3
    select matcode,description,partno1,description1,partno1 from tblobligation where cat2='C'now the thing is I want my default LOV which has been using rg1 to use RG2 if the billtype is 'Send it to site' or else use RG3 if it is 'Send it to Consumed'
    Edited by: Suhail Faraaz on Jan 29, 2011 12:35 AM

    i have solved it.. by creating 3 different LOV for the record group and under when button pressed i have written this
    Declare
         a_value_chosen BOOLEAN;
    BEGIN
         if
              :shipbill.billtype
              in ('Send it to staff','Send it to store','send it to repair','Received from staff','Received from site','Received from store','Received from STC')
              then
         a_value_chosen := Show_Lov('ship_refrence');
         else     
         if :shipbill.billtype='Send it to site'
              then
              a_value_chosen :=Show_Lov('RG_SITE');
         else
              if
                   :shipbill.billtype ='Send it to consumed'
                   then
                        a_value_chosen :=Show_Lov('RG_CONSUMED');
         end if;
         end if;
         end if;     
    END;
    END;

Maybe you are looking for

  • Paths in templates

    hi, read some threads about it, but still cannot find out. it's a simple piece of code where is a path to a specific folder which DW doesn't treat as a link/path and that's why pages on different level than a tempalate doesn't works. here is the line

  • Firefox does not start. error message comes up saying firefox open.

    Fire fox cannot be started as error message comes up saying Fire Fox is open and should be closed. I have shut down and restart computer several time and it still shows Firefox is open and running.I even uninstalled Firefox and re installed it still

  • Adobe Captivate 6.0 Help

    We have been using Adobe Captivate 6 and here the problem is we are not able to open Adobe Help even after installing the updated patch and even after launching the Adobe Captivate with Administrator privileges. Can anyone help us with this?

  • Where does the Ipod Maps App get its location from?

      Mine thinks it is in Queensland but it is in Victoria

  • LabVIEW coding using wnaspi32.dll

    Hi to all, here I need you guys help in LV coding with wnaspi32.dll for I have no experience in doing that at all! I will appreciate if any of you can tell me what the equivalent in lv code for 1) typedef struct BYTE SRB_Cmd; // ASPI command code = S