URGENT - Form with LOV - Query Fails

Hi All,
I've a portal form, with about 10 fields and about 06 of them are combo boxes (attached to dynamic LOVs).
I'm trying to perform a query using the ID and leaving all other fields blank, but no result is displayed. I am sure that the record for that ID exist in the database table.
Can someone please suggest what should I do to be able to perform query in form with LOVs.
Thanks in advance.

Hi Jatinder
I'm happy because you are apparently on the right way with 'your duplicate form'!
"adjust the empty values" means to make sure, that the value of the simple empty field (in the duplicate form) is the same as the value of the corresponding LOV based combo box field (in the original form).
Maybe this sounds easy, but in the matter of fact it isn't. Why?
Look carefully at the following sample:
You have a dynamic LOV based on the number column 'category' in your 'table_1'.
So the basic part of the LOVs query looks like this:
select distinct category from table_1;
Now you still have to add the 'empty value' to your LOV to complete your request to find any value of 'category'. But if you add '0' or ' ' (blank) it wouldn't work. So you have to add NULL but this still doesn't work because you have to adjust NULL to the corresponding data type.
Furthermore you have to be sure that the default LOV's value is the 'any value' one.
Your complete LOVs query then looks like this:
select distinct category from table_1
union
select to_number(null) from dual
order by category desc;
/* 'desc' for 'descending' ensures the NULL value to be on the top of the combo box */
Now as you know how it works for number columns simply use the analog logic for character columns with to_char(null) and for date columns with to_date(null).
That's it.
Thanks
Peter

Similar Messages

  • Can you append a link to a form with a query string to popular a form field?

    I'm trying to do this with Form Central but having no luck getting an answer. Is Acrobat Pro the answer?
    Thanks for your help
    Wayne

    Hi Irosenth
    That looks a great solution. However, I'm a newbie here and can't see that Adobe Pro gives an option to save a form as a .fdf or .xfdf.
    BTW the headline should say POPULATE not popular (whatever that is).
    What I would like to do is send an email to every recipient with a link to a form appended with a query string that automatically completes the ID field. At this point I only have Adobe Pro and FormCentral. Should I be looking elsewhere. (I did try to phone Adobe UK yesterday but was on hold for 1hr 4mins before I had to continue with the rest of my life).
    Thanks for your help & time.
    Wayne

  • Apexlib tabular form with lov gining ora-00900

    Hi,
    When I add a tabular form with 3 items and chagne two of them to a LOV display item I get the following error:
    ORA-00900: invalid SQL statement
    Debug:
    1: begin
    2: ---------------------------------------------
    3: -- Get metadata of page
    4: ---------------------------------------------
    5: ApexLib_Page.generateBrowserData;
    6: ---------------------------------------------
    7: -- Get metadata of items and tabular forms.
    8: ---------------------------------------------
    9: ApexLib_Item.generateBrowserData;
    10: ApexLib_TabForm.generateBrowserData;
    11:
    12: ---------------------------------------------
    13: -- Send data for cascading lovs
    14: ---------------------------------------------
    15: ApexLib_Lov.generateBrowserData;
    16:
    17: ---------------------------------------------
    18: -- Send NLS data for date formats and numeric
    19: -- format masks and translated error messages
    20: ---------------------------------------------
    21: ApexLib_Browser.setNlsData;
    22: ApexLib_Browser.setApexLibMessages;
    23:
    24: ---------------------------------------------
    25: -- Active different navigation improvements
    26: ---------------------------------------------
    27: ApexLib_Browser.setLovIconsNonNavigable;
    28: ApexLib_Browser.setLRButtonIconsNonNavigable
    29: ( pLeftClassName => 'L'
    30: , pRightClassName => 'R'
    31: );
    32: ApexLib_Browser.checkForLovKey;
    33: ApexLib_Browser.checkForUpDownKey;
    34:
    35: ---------------------------------------------
    36: -- Active different UI improvements
    37: ---------------------------------------------
    38: /* optional
    39: ApexLib_Browser.setTextareaProperty
    40: ( pProperty => ApexLib_Browser.VERTICAL_RESIZEABLE
    41: );
    42: */
    43: ---------------------------------------------
    44: -- Init browser validation
    45: ---------------------------------------------
    46: ApexLib_Browser.initValidation
    47: ( pShowRequiredWarning => TRUE
    48: );
    49: ---------------------------------------------
    50: -- Has to be the last statement!
    51: ---------------------------------------------
    52: ApexLib_Browser.flushJsBuffer;
    53: end;
    Any idea?
    Erwin

    I solved it.
    I modified a bit my code "On load Page". In case of LOV i have changed this condition
    if (l == undefined) {
              document.wwv_flow.f03.disabled = true;
          }with this
    if (l == 105) {
              document.wwv_flow.f03.disabled = true;
          }I don't know why 105 instead of undefined, but this works. I give 105, with alert on length.

  • LightSwitch Fill Form with a Query

    Hi,
    I added a button in an add and edit screen to edit information related to the paticular id I am editing but need to launch another edit screen so I can edit the information stored in another non relational table with the id in the previous screen. Since
    I do not have an entity information of that table I needed to pass the id and the edit form be fill in with a query so I can edit that table after.
    Anyone has an idea would appreciate it.
    Thanks,

    Yeah, the way I usually go about doing that sort of thing is by overloading the main constructor of the Form which does the editing..
    So for example:
    public Form1(){
    Initialise();
    You'd also make another like this:
    public Form1(int id){
    Initialise();
    LoadRecord(id);
    To open up the form you'd write this in the event handler of the original form:
    Form frm = new Form(123);
    frm.Show();/frm.Visible=true; (whatever it is)
    Hope this helps,
    Antony
    :D

  • How to create Form with LOV in JDeveloer9i?

    Forms Builder 9i use Data Block Wizard and Layout Wizard to define a form and LOV Wizard to define List of Values from master table.
    How can I define LOV for foreign key of a Base Table using JDeveloper9i?

    Check out the JClient demos at:
    http://otn.oracle.com/products/jdev/viewlets/viewlet.html
    There is one for JClient LOVs which may be useful.
    regards
    Grant Ronald
    JDeveloper Product Management

  • Need urgent help with the query - Beginer

    Hello - I need help with a query to populate data in a table.Here is the scenario.
    Source1
    MnthID BranchCod CustID SegCode FXStatus ProfStatus Profit
    200712 B1 C1 20 Y Y 100
    Source2
    MnthID BranchCod CustID ProdCode ProdIndex
    200712 B1 C1 12 1
    200712 B1 C2 12 0
    Destination
    MnthID BranchCod SegCode ProdCode CountSegCust CountProdCust ProfitProdCust
    Condition and Calculations:
    1)Source1 customer are base customers.If Source2 has customers who is not in source1 then that customer's record should not be fetched.
    2)SegCode, FX Status, ProfStatus is one variable in destination table. [ SegCode = SegCode+ FXStatus (if FXStatus = Y)+ ProfStatus (if FXStatus = Y) ]
    3)CountSegCust = CountCustID Groupby MnthID,BranchCod,SegCode Only.
    4)CountProdCust = CountCustID Groupby MnthID,BranchCod,SegCode,ProdCode (when ProdIndex = 1)
    5)ProfitProdCust = Sum of Profit of Customers Groupby MnthID,BranchCod,SegCode,ProdCode (when ProdIndex = 1)
    Apologies for bad formatting.
    Thanks in advance!!

    A total guess indeed.
    It's not clear whether some aggregation can be done (summing counts of grouped data might cause some customers being counted more than once)
    insert into destination
    select mnthid,branchcod,segcode,prodcode,countsegcust,countprodcust,profitprodcust
      from (select s1.mnthid,
                   s1.branchcod,
                   s1.segcode || case s1.fxstatus when 'Y' then s1.fxstatus || s1.profstatus end segcode,
                   s2.prodcode,
                   count(s1.custid) over (partition by s1.mnthid,
                                                       s1.branchcod,
                                                       s1.segcode || case s1.fxstatus when 'Y' then s1.fxstatus || s1.profstatus end
                                              order by null
                                         ) countsegcust,
                   count(case proindex when 1
                                       then custid
                         end
                        ) over (partition by s1.mnthid,
                                             s1.branchcod,
                                             s1.segcode || case s1.fxstatus when 'Y' then s1.fxstatus || s1.profstatus end
                                             s2.prodcode
                                    order by null
                               ) countprodcust,
                   sum(case proindex when 1
                                     then profit
                       end
                      ) over (partition by s1.mnthid,
                                           s1.branchcod,
                                           s1.segcode || case s1.fxstatus when 'Y' then s1.fxstatus || s1.profstatus end
                                           s2.prodcode
                                  order by null
                             ) profitprodcust,
                   row_number() over (partition by s1.mnthid,
                                                   s1.branchcod,
                                                   s1.segcode || case s1.fxstatus when 'Y' then s1.fxstatus || s1.profstatus end
                                                   s2.prodcode
                                          order by null
                                     ) the_row
              from source1 s1,source2 s2
             where s1.mnthid = s2.mnthid
               and s1.branchcod = s2.branchcod
               and s1.custid = s2.custid
    where the_row = 1Regards
    Etbin

  • How to refresh Portal form with LOV POPUP ?

    I have a portal form which has a LOV which is a POPUP.
    When the POPUP is filled, I need that another LOV (a combo box) be refreshing by its dependent bind variable.
    When the Popup is filled, nothing happens.
    I tried with this javascript:
    do_event(this.form, this.name, 1, 'CUSTOM', '');
    But it works only if the first LOV that is the Popup is use as a combo box.
    I still need to use the Popup.
    Thanks.
    Enrique.

    This is a known issue and this is soon going to be fixed .It might be available in the next patch.
    Actually you will see that if you have written code in onChange of POPUP then if you change the value in the text box of the POPUP lov it will work but when you will select it from the POPUP values the event will not be generated.
    rahul

  • Help with LOV query

    Hi,
    I need some help with a lov.
    The lov needs to be populated with distinct values of an item description
    I have 3 records in my table
    "1" "Roof Plate"
    "2" "Threaded Rod"
    "3" "Roof Plate"
    Therefore my lov should only have "Roof Plate" and "Threaded Rod"
    I can't figure out how to do this in the lov bearing in mind i need a display_value and return_value
    Please help..

    Hi,
    >
    I need some help with a lov.
    The lov needs to be populated with distinct values of an item description
    I have 3 records in my table
    "1" "Roof Plate"
    "2" "Threaded Rod"
    "3" "Roof Plate"
    Therefore my lov should only have "Roof Plate" and "Threaded Rod"
    I can't figure out how to do this in the lov bearing in mind i need a display_value and return_value>
    What is the expected return value, 1 or 3?
    Regards,

  • Tabular form with non base table field

    I want to develop a tabular form with
    1. A non-base table edit field to accept a value
    2. Insert/update another table based on the input value
    3. Also, computed field on each row based on other fields on the records (like post-query trigger in oracle forms at block level - for each row)
    Thanks,
    Rachna

    Thanks for your reply.
    Varad, I like the link you sent me. It has a lot of good information.
    I created a process (under page processing) called "Update/Insert Process" that dosn't seem to be working.
    Question, I created a manual tabular form with SQL Query and created a process (under page processing) called "Update/Insert Process", then I check for each record in the tabular form. If the old value <> new value then I update/insert in the new table.
    Any step by step will be highly apprciated - to create process/validation etc.
    Thanks,
    Rachna

  • How to display LOV on web in ENTER-QUERY mode with form or block query only.

    Hello all
    How can I display lov automatic on the web in from enter-query
    mode in form or block query only mode.
    thankx

    If I understand correctly your explanation, your called form
    fails to activate the LOV in enter-query mode when it is deployed
    and test on the browser.
    So lets proceeed like this, to make it work in all environments,
    let us programetically activate the LOV.
    HOW?
    In the called form, write in the WHEN-NEW-ITEM-INSTANCE TRIGGER
    at block level (if have more than one LOV)
    IF :SYSTEM.MODE = 'ENTER-QUERY' THEN
    IF get_item_property(:system.cursor_item,lov_name) IN ('YOUR
    LOV1', 'LOV2' etc) THEN
    IF SHOW_LOV(get_item_property(:system.cursor_item,lov_name))
    THEN
    NULL;
    END IF;
    END IF;
    END IF;
    The above code maybe tweak to suite your need and condition.
    This way, we explicitly make the LOV appear in ENTER-QUERY mode
    whenever the user clicks on an item with an attached LOV.
    Hope this helps.
    Mohammed R.Qurashi

  • The following query failed: GetUserProfileByName - with the wrong username

    I have 2 users (out of 800), who run into this issue on occasion. Their username is 'fccs\user1' in the profile db, and in every UserInfo table in the system. But when they try to go to certain sites or open an infopath form, this error gets thrown:
    The following query failed: GetUserProfileByName (User: FCCS\[email protected], Form Name: Template, IP: , Connection Target: , Request: http://fccsteams/sites/DataManagement/Tasks/Lists/Tasks/Folders1.aspx?RootFolder=/sites/DataManagement/Tasks/Lists/Tasks/2013/11&, Form ID: urn:schemas-microsoft-com:office:infopath:list:-AutoGen-2013-08-05T23:14:53:458Z Type: DataAdapterException, Exception Message: The remote server returned an error: (500) Internal Server Error.  Operation Failure ---> Access Denied: To create a user profile, you must be an administrator, or create your own profile and have personal features rights.  UnauthorizedAccessAccess Denied: To create a user profile, you must be an administrator, or create your own profile and have personal features rights. The remote server returned an error: (500) Internal Server Error.)
    Notice how the username is now the entire email address and not just the username. I have no idea why it thinks that that is their username. Any ideas?

    Hi,
    According to your post, my understanding is that you got query failed error.
    Melick had written a blog said that the form access the user profile web service (Userprofileservice.asmx) using  UDC
    file.
    You can check whether the UDC connection was still pointing to root site.
    You can change this file to match with the sub site collection. Otherwise there may be a cross domain access issue.
    There are similar threads for your reference.
    http://social.msdn.microsoft.com/Forums/sharepoint/en-US/9c2f7f4c-0fa9-43bd-94b1-1d7075e35841/5566-error-with-getuserprofilebyname-and-infopah-browser-forms-using-claims-based-authentication
    http://social.msdn.microsoft.com/Forums/en-US/49753330-40c0-4327-9a9b-2c3304a74e67/sharepoint-infopath-and-populating-forms-with-ad-data?forum=sharepointcustomizationlegacy
    Thanks & Regards,
    Jason 
    Jason Guo
    TechNet Community Support

  • Select item on a Tabular form with a different dynamic LOV on each row

    I would like to use a tabular form where one of the columns is a dynamic LOV based Select, and where that dynamic LOV refers to one of the column values on each row.
    So if the tabular form represented a list of teams and the LOV-based Select column was the current team leader, I would want that select list to be populated only with the members of that team (different for each row). Since the list of team members is in some other table (all_players or something) I would want to populate the LOV with a query with a where clause that selected only those players records with a team-membership equal to the current tabular form's team id. So, on each row that select list's contents would be different.
    -- Justin

    I'm beating a dead horse here but I did get something to work with "less" code. My current needs do not require me to cascade drop downs, I only want 1. You can use the query like the in the first reply (but I don't have a table with joins) I created a simple two column table dept_emp with 4 records 10,null 20,null .... I want to fill the nulls with an employee but ONLY an employee that matches the dept. (Same concept of team leader and members).
    Here's the query:
    select apex_item.display_and_save(1,dept) dept,
    apex_item.select_list_from_query(2, name, 'select ename from emp where deptno='||dept) name
    from dept_emp
    I removed the code that was there already (ApplyMRU) and just put in this code:
    BEGIN
    FOR i IN 1..HTMLDB_APPLICATION.G_F01.COUNT LOOP
    UPDATE dept_emp
    SET
    name=HTMLDB_APPLICATION.G_F02(i)
    WHERE dept=to_number(HTMLDB_APPLICATION.G_F01(i));
    END LOOP;
    END;
    The G_F01 matches the column 1 and so forth. There's more documentation but little explanation at:
    http://download.oracle.com/docs/cd/B25329_01/doc/appdev.102/b25309/api.htm#sthref2171
    The thing I could not get to work was a dynamic message
    #MRU_COUNT# row(s) updated, #MRI_COUNT# row(s) inserted.
    Not sure when the MRU_COUNT gets populated (probably in the routine I removed ;))
    You're probably way past me by now but I like to have as little code as possible when it comes to maintaining an app. That's why I liked oracle forms so much. This kind of stuff was pretty easy to do.
    Thanks again everybody!

  • LOV & Query in Forms 10g not working

    Hi All,
    I have a strange problem with custom forms that i am developing using Dev Suite 10g (10.1.2) for Oracle AS 10g (10.1.2.0.2).
    When i test the form in DevSuite the LOVs in the form are working properly, but after i deploy the form on the server and use the default config the LOVs stop showing up.
    The same happens with Execute Query. There is no error message displayed either.
    Since the jiniitator was downloaded from the same server, so that cannot be the problem.
    The version of java used is also the same, 1.4.2.
    I have no idea why the forms are behaving like this on the server. Any help would be great.
    Thanks in advance,
    Arun

    I was able to get the trace file from the FRD.
    Please see below for the trace file of the form.
    trace.xml
    - <FORMSTRACE>
    <CollectionName>/u01/oracle/ias10g/bif/forms/trace/forms_23684.trc</CollectionName>
    ***TRACE STARTED BY EM***
    - <Form>
    <FormID>1</FormID>
    <Name>TPA_HEADER(1)</Name>
    </Form>
    - <Form.START Name="TPA_HEADER">
    <EventID>3</EventID>
    <EventNum>64</EventNum>
    <Timestamp>688001334</Timestamp>
    - <Details>
    <Name>TPA_HEADER</Name>
    <FormName>TPA_HEADER(1)</FormName>
    </Details>
    </Form.START>
    - <NETWORK.READ>
    <EventID>4</EventID>
    <EventNum>133</EventNum>
    <Timestamp>688014994</Timestamp>
    <EndEvent>7</EndEvent>
    <Duration>0</Duration>
    - <Details>
    <Packets>1</Packets>
    <Bytes>0</Bytes>
    </Details>
    </NETWORK.READ>
    - <MENU_SELECT Name="DEFAULT.Query.eXecute">
    <EventID>5</EventID>
    <EventNum>33</EventNum>
    <Timestamp>688014994</Timestamp>
    - <Details>
    <FormName>TPA_HEADER(1)</FormName>
    <Type>DEFAULT</Type>
    <Menu>Query</Menu>
    <Item>eXecute</Item>
    </Details>
    </MENU_SELECT>
    - <TRIGGER.START Name="TPA_HEADER(1).KEY-EXEQRY">
    <EventID>6</EventID>
    <EventNum>66</EventNum>
    <Timestamp>688014994</Timestamp>
    - <Details>
    <Block>TPA_HEADER</Block>
    <Item>(Null)</Item>
    <Name>KEY-EXEQRY</Name>
    <FormName>TPA_HEADER(1)</FormName>
    </Details>
    </TRIGGER.START>
    - <NETWORK.WRITE>
    <EventID>7</EventID>
    <EventNum>133</EventNum>
    <Timestamp>688014994</Timestamp>
    <StartEvent>4</StartEvent>
    <Duration>0</Duration>
    - <Details>
    <Packets>1</Packets>
    <Bytes>0</Bytes>
    </Details>
    </NETWORK.WRITE>
    - <NETWORK.READ>
    <EventID>8</EventID>
    <EventNum>133</EventNum>
    <Timestamp>688019034</Timestamp>
    <EndEvent>10</EndEvent>
    <Duration>0</Duration>
    - <Details>
    <Packets>16</Packets>
    <Bytes>0</Bytes>
    </Details>
    </NETWORK.READ>
    - <MENU_SELECT Name="DEFAULT.Help.display Error">
    <EventID>9</EventID>
    <EventNum>33</EventNum>
    <Timestamp>688019034</Timestamp>
    - <Details>
    <FormName>TPA_HEADER(1)</FormName>
    <Type>DEFAULT</Type>
    <Menu>Help</Menu>
    <Item>display Error</Item>
    </Details>
    </MENU_SELECT>
    - <NETWORK.WRITE>
    <EventID>10</EventID>
    <EventNum>133</EventNum>
    <Timestamp>688019034</Timestamp>
    <StartEvent>8</StartEvent>
    <Duration>0</Duration>
    - <Details>
    <Packets>1</Packets>
    <Bytes>0</Bytes>
    </Details>
    </NETWORK.WRITE>
    </FORMSTRACE>
    Message was edited by:
    arunm

  • Tabular form (select list Query based LOV)

    Hi all,
    I have this situation:
    a tabular form with two "select list (query based LOV)" fields.
    The first one must affect elements in the second one. And so the second query based LOV field should has a "where attr1 = first_list_selected_value" in the query.
    Is this possible ? Could you show me some advices ?
    thanks in advance.

    OK, thank you.
    But maybe I wasn't too clear.
    I need cascading LOV for each row of my tabular form.
    I have a EMP tabular form
    select
    "ROWID",
    "EMPNO",
    "ENAME",
    "JOB",
    "MGR",
    "HIREDATE",
    "SAL",
    "COMM",
    "DEPTNO"
    from "#OWNER#"."EMP" I need a Select List for DEPTNO for each record of table. After set a value, the second "Select List" for ENAME should be affected automatically.

  • Is there a problem using popup LOVs in a portal form with a bind variable?

    I have a portal form with 2 LOVs. The second LOV is a dependent LOV whose bind variable can be NULL. I have read Note 263923.1, "How To Create Dependent Lovs In Forms", and my form works as long as I use combo boxes to display the LOVs. I need to use popups so the user can search the LOVs as they are quite lengthy. Plus I want to be able to pick a value from my second LOV without selecting a value from the first LOV -- hence, my bind variable can be null and that is where my problem lies. As long as I select a value from the first LOV, the second LOV popup will work. If I click on the icon to display the second LOV without pre-selected a value from the first LOV, I get the following error:
    POPUP LOV ERROR:
    LOV: "9A17692880B6B8509F514F5B9CA9EC808DD403218B3CF19A33C04CD1FAB0ADE17ADC33E6B67998A933357CE5264D204E"
    Parse Message: Parse as pre-set global: "TORE".
    Find Message: LOV is of type DYNAMIC (LOV based on SQL query).
    Query: "SELECT ...."
    wwv_bind.prepare_bind: ORA-01403: no data found
    My form is based on a table with a custom layout. The sql for the second LOV is similar to: SELECT ENAME, EMPNO FROM SCOTT.EMP WHERE (DEPTNO = :DEPT AND :DEPT IS NOT NULL) OR :DEPT IS NULL.
    Thanks in advance for any help,
    Carol

    Don't use EPS any more! It does not support transparency nor color management.
    If you save vector files from Illustrator, use AI with PDF compatiblity.
    If you save image files from Photoshop, use PSD.
    If you save image files combined with vector forms and/or text from Photoshop, use PDP which is a Photoshop PDF.
    For vectors from Illustrator use CMYK files.
    For images use RGB, conversion to CMYK should never done before PDF export, better, if the printer allows it, is to export a PDF with live transparency as it is PDF/X-4
    If the printer requires a PDF with CMYK only export a PDF/X-1a.

Maybe you are looking for

  • Firefox 4 won't work on my Mac OSX 10.4.11, it says Firefox 3.6.17 is not secure?

    I keep getting messages to upgrade to FireFox 4, and it will not open on my Mac OSX 10.4.11. I get messages that the 3.6.17 version is not secure.

  • Missing Memory in CS5?

    Hi to all! On my Mac Pro I had CS4 and since two days aside also Photoshop CS5 installed. Since I like to use my Nik plug-ins I changed the Bit mode of CS5 to 32 Bit. After I removed the Selective Tool of those Plug-ins it seems everything was workin

  • FI Archiving

    Hello Experts, Any one can me help in this. Scenario is like this i have archived  FI DOC and EC PCA objectives for the fiscal year 2005, after that i have deleted and stored those archived objetives. now when i am checking the BKPF and GLPCA table f

  • Change Workstatus with BPF step completion using BADI

    Hi Experts, I have a requirement of changing Workstatus as soon as the user clicks on "Submit/Approve/Reject" button from the BPF. We are trying to implement the same by referring to the thread Automating Work status Change in BPF Now the thing is, w

  • InDesign CS5: Configuration Error (Error 5)

    I've installed CS5 Premium. When I try to start InDesign CS5, I get this error: "Configuration error. Please uninstall and reinstall the product. If this problem still occurs, please contact Adobe technical support for help, and mention the error cod