Call form and execute query there

hi
i have already one form and i created another form with one text-item named Code(non-base item) and i want when i enter number and click on button and it execute all records in main form with the same code which one i enter in sub form.is it possible if its possible plz guide me thanks in advance
sarah

Hi!
From the main form call the sub form with the call_form build-in like this:
begin
default_value ( null, 'global.code );
call_form ( 'sub_form', no_hide, no_replace, no_query_only );
if
  :global.code is not null
then
  go_block ( 'your_block' );
  set_block_property ( :system.cursor_block, onetime_where, 'code = :global.code' );
end if;
erase ( 'global.code' );
go_item ( :system.trigger_item );
end;In the sub form write to your when-button-pressed trigger:
begin
:global.code := :your_block.code;
exit_form ( no_validate );
end;Hope that helps
Edited by: Magoo on 30.08.2009 17:46
Edited by: Magoo on 30.08.2009 17:59

Similar Messages

  • Call form and execute query

    Hi All
    i have two forms one form is sale_order and other is order tracker what i want when i press the button
    sale order cotains information about the every sale with a unique ID
    and order tracker contains list of all orders i want a button on order tracker when-button pressed then open the sale_order and execte the sale_order as the id is selected in order tracker
    Thanks And Regards
    Vikas Singhal

    Hi My code is
    in order tracker i wrote this code
    :global.my_id := 'id';
    open_form('c:\test_report\sale_order');
    execute_query;
    the sale order form is opened but not execute the sale_order in order_tracker is id=111
    in sale order where what should i do please guide where i do the id=global.id
    Thanks And regards
    Vikas Singhal
    Edited by: vikas singhal on Jun 23, 2009 11:07 PM

  • How to implement enter and execute query in ADF

    I am new to ADF and I am trying to create a simple data entry screen in ADF 11g based on a database table. I am looking to implement the equivalent of the Enter Query and Execute Query feature in Oracle Forms. I tried the default operations that are available with the data controls. But they don't seem to have this feature. Can someone help me / point me to how this can be implemented.
    Thanks,
    Srini.

    Thanks Shay. As per your suggestion I have included the Find and Execute buttons for the VO Object and ran the page. I first clicked the Find button and entered by query condition and then clicked the Execute button. At this point I get an error popup asking me to enter values for all the mandatory fields. Am I missing something?
    Regards,
    Srini.

  • Enter and execute query in ADF

    Hi Experts,
    I am trying to implement Enter-Query/Execute-Query in adf and using Jdev 11.1.2.2.0. I put Find and execute operation on the form. When i press execute button i says me to enter value for mandatory fields. But i am try to execute query not trying to create or update records. In forms we can query on any attribute.
    Please guide
    Thanks

    Enter and execute query in Oracle Forms starts with a simple row by row form for updating a table. When you press the "Enter Query" button, the form clears and the user can enter query by example criteria for any of the fields on the form. Then the user presses the "Execute Query" button, and is back in the update form, but with the data for the first matching row shown.
    Here is a page with some links to articles by Steve Muench that explains some ways to implement this in ADF 10.1.3 - I think these techniques should still work in ADF 11g:
    http://radio-weblogs.com/0118231/2006/02/13.html#a658
    Another way with ADF 11g might be to put an af:query component in one facet of an af:switcher and the update form in the other facet. The Enter Query button on the update form tells the switcher to switch to the query facet, and executing the query also tells the switcher to switch back to the update form.

  • HST50: Unix - How Headstart calls forms and reports uppercase/lowercase from a Menu

    We are migrating a 'in production' Headstart generated application from Windows to Unix.
    We had to a little time in setting the lowercase implementation names, setting the prefs to generate lowercase file.....
    So good so far. When testing the application on Unix, all files are lowercase, the Forms start without a problem but the Reports won't start.... Renaming the report files to uppercase works fine.
    Going through the Headstart code for calling Forms and Reports I noticed the following:
    When calling Forms the qmslib50.qms$form.call procedure is invoked. In this procedure the follwoing statement is used:
    l_form_name := lower(p_form_name) So only lowercase will be found....
    For calling Reports from the Lauch Report Form the qms0012l.qms$report.run procedure is invoked.
    This procedure calls fill_par_list where the l_module_name is set. But in this procedure no uppercase or lowercase is used......
    Not consequent I think !!
    Is this done for a specific reason ?
    PS: Change qms0012l and it works fine.

    Hi,
    cannot use run_report_object here cause I cannot create a report object in menu (like how we can do it in forms).
    Create a generic named Report node in the forms that you reference from the RunReport object request. This way you can run Reports from a menu
    Frank

  • Return values from a popup to calling form and refresh page?

    Hi,
    Following thread Re: Popup report window from a PL/SQL proc.? I'm trying to pass the record values(checkbox + record values) to the parent windows (the retruned value is always a unique record). I was able to set the variables values with a procedure ( I vierfied in session state), but I'm unable to pass these values to the parent form and then refreshing the page. I tried the following thread without success : Refresh from Popup page
    Any hint would be appreciated.
    Thanks

    Andy,
    My page has the following query for the report region (PL/sql function):
    DECLARE
    v_string VARCHAR2(2000);
    vc VARCHAR2(2):=chr(39);
    BEGIN
    v_string:= 'SELECT '||vc||'<img src="/i//edit_big2.gif" onClick="f_payment_clrRow(this)"></img>'||vc||' Clr, '||
    ' APEX_ITEM.SELECT_LIST_FROM_QUERY(1,NULL,'||vc||'SELECT TRX_DESCRIPTION, TRX_ID FROM WTL_V_TRX_PAYMENTS WHERE TRX_EFFECT='''||V_Effect||''' '||vc||',''onchange=f_payment_trx_paymode(this); '',''NO'') Description,'||
    ' APEX_ITEM.SELECT_LIST_FROM_QUERY(2,NULL,'||vc||'SELECT DESCRIPTION, ID_VALUE FROM GEN_PR_TYPES_ENTITY '||vc||',null,''NO'') Bank,'||
    ' APEX_ITEM.TEXT(3,NULL,10,10,''ondblclick=f_callMyPopup(this);'') Document,'||
    ' APEX_ITEM.TEXT(4,NULL,10,15) Account,'||
    ' APEX_ITEM.SELECT_LIST_FROM_QUERY(5,NULL,'||vc||'SELECT ID_VALUE, ID_VALUE FROM WTL_V_TRX_CURRENCY'||vc||',''onchange=f_payment_currency_rate(this);'',''NO'') Currency,'||
    ' APEX_ITEM.TEXT(6,NULL,15,20,''onblur=f_payment_trx_amount(this); style="text-align:right;" '') Amount, '||
    ' APEX_ITEM.TEXT(7,NULL, 5, 8,''onblur=f_payment_trx_amount(this); style="text-align:right;" '') Rate, '||
    ' APEX_ITEM.TEXT(8,NULL,15,20,''readonly style="text-align:right;" '') Trx_Amount, '||
    ' APEX_ITEM.HIDDEN (9,NULL), '||
    ' APEX_ITEM.HIDDEN (10,NULL) '||
    ' from dual';
    return v_string;
    As u can see, the 3rd item uses the ondblclick to call the js function f_callMyPopup.
    My js function in the header of the page is below:
    <script>
    function f_open_lov2(page, request)
    { var url;
    url = 'f?p='+$x('pFlowId').value+':'+page+':'+$x('pInstance').value+':'+request;
    w = open(url,"winLov","Scrollbars=1,resizable=1,width=500,height=600");
    if (w.opener == null)
    w.opener = self;
    w.focus();
    function f_callMyPopup(x)
    var f01;
    var p = x.parentNode;
    while (p.tagName != "TR")
    { p = p.parentNode;}
    var inputs = p.getElementsByTagName("INPUT");
    var zz;
    for (zz = 0; zz < inputs.length; zz++)
    {if (inputs[zz].name = 'f01')
    {f01 = inputs[zz].id;}
    f_open_lov2(17,97);// I sent 97 as an example.
    </script>
    and the js in the custom popup page (17) has the following function which is executed when the user selects one of the rows using a button.
    <script>
    function f_return_value(cstring)
    opener.document.getElementById("f03").value = cstring;
    close();
    </script>
    When f_return_value is executed, the selected value is pasted in the first row of the parent page.
    Sorry , i don't know what do you mean when you say to pass the id to the custom popup page.
    Thanks again,
    Fernando
    Edited by: fnovilloes on 16/09/2009 12:01 PM
    Edited by: fnovilloes on 16/09/2009 03:56 PM
    Edited by: fnovilloes on 16/09/2009 03:59 PM

  • Which block get effected by save and execute query

    Hello,
    I'm using forms 9i , database oracle 9i.
    Case:
    i made a simple application with 4 stack canvas on each i place data from 4 tables. convention is like every stack canvas get visible when the corresponding button is pressed. once visible i don't set it to invisible i just place other stack canvas over it.
    Although i don't get any error or problem while doing normal work like saving records or Executing query. but i don't understand whether these operation only effect the table which is visible(on stack canvas). and rest of are unaffected.
    if No then how i can do it with only on visible canvas
    and if yes is there any way that i can do execute query on all of them.
    thanks
    Rahul.

    The SAVE (COMMIT_FORM or COMMIT) will affect the whole form if you are using simple blocks based on tables, every block that does have changed or new data it will saved in the database.
    The EXECUTE_QUERY will affect only the current block, the block where the cursor is in currently. If this block is a master block then the EXECUTE_QUERY on the master block will also affect the detail block.
    If it's a standalone (not a master) block, the EXECUTE_QUERY will only affect the block your cursor is in.
    Tony

  • Calling form in Enter-Query mode

    Hi
    how can i Have a form called from the menu (generated with
    headstart) start in Enter-Query mode ?
    Is there any method to do this easily ??
    TIA
    Olivier
    null

    Olivier,
    Look in the Headstart Template Package users guide. In the
    Runtime Behaviors chpt, under Inter-Form Navigation, Named Passed
    Values and Argument Passed Values, you will find an explanation
    of how to start a form in Enter-Query mode.
    Regards,
    Lauri
    Olivier GIBERT (guest) wrote:
    : Hi
    : how can i Have a form called from the menu (generated with
    : headstart) start in Enter-Query mode ?
    : Is there any method to do this easily ??
    : TIA
    : Olivier
    null

  • Problem with call transaction and a query

    Hi,
    Whe have a query that has its own Z tcode, we are working with this "EXIT_SAPLCORF_103"  within the tcode CO11N. Inside the include "ZXCOFU13" we call the query Tcode and it is displayed on screen but with no data.
    The table "itbdcdata" record well the data of the inputs in the query recording so you can see with the WERKS and the number of reserve (3994) in the recording.
    Why the call transaction display the query screen with no data...? and how can i pass the inputs to the query screen so it be executed.
    Thanks on advance.
    David Fúnez
    Tegucigalpa, Honduras.
    This is the recording:
    AQZZZ_USER_GRMA=Z_QUERY_PP_003     1000X                                                                                BDC_CURSOR     SP$00002-LOW
                                                                BDC_OKCODE     =CRET
                                                                S_WERKS-LOW     1202
                                                                SP$00002-LOW           3994
                                                                %ALV     X
    this is the code in the INCLUDE
    *&  Include           ZXCOFU13
    DATA: itbdcdata TYPE bdcdata    OCCURS 0 WITH HEADER LINE,
          optoption TYPE ctu_params.
    REFRESH itbdcdata.
    CLEAR   itbdcdata.
    itbdcdata-program  = 'AQZZZ_USER_GRMA=Z_QUERY_PP_003'.
    itbdcdata-dynpro   = '1000'.
    itbdcdata-dynbegin = 'X'.
    APPEND itbdcdata.
    itbdcdata-fnam = 'BDC_CURSOR'.
    itbdcdata-fval = 'SP$00002-LOW'.
    APPEND itbdcdata.
    itbdcdata-fnam = 'BDC_OKCODE'.
    itbdcdata-fval = '=CRET'.
    APPEND itbdcdata.
    itbdcdata-fnam = 'S_WERKS-LOW'.
    itbdcdata-fval = '1202'.
    APPEND itbdcdata.
    itbdcdata-fnam = 'SP$00002-LOW'.
    itbdcdata-fval = caufvd_imp-rsnum.
    APPEND itbdcdata.
    itbdcdata-fnam = '%ALV'.
    itbdcdata-fval = 'X'.
    APPEND itbdcdata.
    CLEAR optoption.
    optoption-dismode = 'A'. "A is visible
    optoption-updmode = 'S'.
    CALL TRANSACTION 'ZRESV' USING itbdcdata OPTIONS FROM optoption.

    problem solved.

  • 10g Form - first execute query - very slow

    I have the following issue:
    Enter an application
    open a form in enter query mode
    first time execute query is very slow (several minutes)
    every other time it's quick (couple seconds or less)
    I can leave the form, use other forms within the app, come back and query is still quick. It's only the first time after initially launching the app.
    Any ideas what might be causing this?

    We have the same application running in 6i client/server DB-9i in production. We are testing the upgraded application that is 10g forms on OAS DB-10g. We don't have the issue in the current production client/server app.

  • Oracle forms and report query..!

    Hi all,
    I am new to oracle forms & reports.here in my project we r using oracle forms and reports 6i.
    Is there any option in oracle forms by which I can know which oracle form is hitting which procedure,packages ,table etc in backend database.I dnt know for which oracle form which packages has been called .
    How to know database object name which is calling by oracle forms.
    kindly help me to know package name so that i can start my development work with database packages..
    Regards
    PC arya

    What exactly you want to achieve ? What packages and procedures are being called, you would come to know by opening the form in Forms Builder and going to the relevant sections.
    Anything specific to Oracle Forms you may want to post in Forms forum at Forms

  • Is The Current Called Form Running in Query Only Mode?

    How can identify the current called form is running in either QUERY_ONLY / NO_QUERY_ONLY MODE progrmatically?

    You can use :system.form_status to check for this. Be aware that this can change quite frequently throughout navigational processes both visibly and "behind the scenses"
    n

  • What role is required to open and execute query in BE query designer

    Hi,
    Am new to BE, need to know what role should i be assigned with to open and execute  a query in query designer.
    OPEN dialobox displays "NO role availabe".
    Is this a problem of role assignment or am i missing some steps
    thanks
    srikanth

    IN Enterprise portal plz check whether these roles are present or not.
    pcd:portal_content/com.sap.pct/platform_add_ons/com.sap.ip.bi/Roles/com.sap.ip.bi.business_explorer_showcase
    pcd:portal_content/com.sap.gm.cnt/core/VCRole
    pcd:portal_content/com.sap.pct/platform_add_ons/com.sap.ip.bi/Roles/com.sap.ip.bi.bi_showcase
    pcd:portal_content/administrator/content_admin/content_admin_role
    pcd:portal_content/com.sap.pct/platform_add_ons/com.sap.ip.bi/Roles/com.sap.ip.bi.business_planning_showcase
    pcd:portal_content/every_user/general/eu_role
    in BW front end , you have to create role with the auth objects S_RS_COMP, S_RS_COMP1, S_RS_MPRO, S_RS_ICUBE auth objects.
    include the t-codes if necessary. RSRT you can include.
    Hope this would help you.

  • Import java code applet into form and execute it

    Hi all.
    I'm on devsuite 10g.
    I have the following applet code:
    import java.applet.Applet;
    import java.awt.event.*;
    import java.awt.*;
    public class simple2 extends Applet
      implements MouseListener, MouseMotionListener {
          double r0 = 100.0;
          double r1 = 40.0;
        public void paint(Graphics g) {
          int n = 400;
          int x0=0,y0=0,x1,y1;
          for(int i=0;i <=n;i++)
               double rho   = 2*Math.PI*i/n;
               double theta = 16*Math.PI*i/n;
               double x = r0*Math.cos(rho) + r1*Math.cos(theta);
               double y = r0*Math.sin(rho) + r1*Math.sin(theta);
               // cambio sistema di riferimento
               x1 = getSize().width/2+(int)x;
               y1 = getSize().height/2+(int)y;
               // disegno
               if(i>0) g.drawLine(x0,y0,x1,y1);
               x0 = x1;
               y0 = y1;
        public void init() {
          addMouseListener(this);
          addMouseMotionListener(this);
        public void mouseClicked(MouseEvent e) {}
        public void mousePressed(MouseEvent e) {}
        public void mouseReleased(MouseEvent e) {}
        public void mouseEntered(MouseEvent e) {}
        public void mouseExited(MouseEvent e) {}
        public void mouseMoved(MouseEvent e) {}
        public void mouseDragged(MouseEvent e) {
          int x = e.getX(), y = e.getY();
          r0 = x-getSize().width/2;
          r1 = y-getSize().height/2;
          repaint();
          e.consume();
    } I want to import this code into my form in order to execute it.
    Code make possible drawing graphs to screen...
    What I want is to execute this code into my form, in a when-new-block instance trigger or something else.
    How can I achieve this???
    Thanks all for collaboration,
    Fabrizio

    It isn't quite as simple as just "importing" your java code if your goal is to have the forms and the java app communicate with each other. Interaction occurs when a properly designed Java Bean is created.
    Take a look at some of the examples on the following page as they can likely provide you with a good starting place:
    http://sheikyerbouti.developpez.com/forms-pjc-bean/menu/

  • Call Forms And Reports through node

    Dear All,
    i have a hierarchy tree menu look like this
    +GL
    Accounts
    Inform
    +Export
    Export Entry Form
    +Security
    New User Entry
    when i click Gl==>Accounts, accounts form opens
    when i click EXPORT==>Export Entry Form opens
    and i want call my forms and reports through nodes
    Kindly any one tell me how i can i do this.
    thnks
    Regards,
    zubair saleem.

    Welcome to the forum.
    Please visit https://forums.oracle.com/forums/ann.jspa?annID=432 and https://wikis.oracle.com/display/Forums/Forums+FAQ. It will help members of the forum to help you better.
    Forms and Reports version?
    Client/server or web? (if it is 6i)
    Regards,
    PS : Check this out https://sites.google.com/site/craigsoraclestuff/oracle-forms---how-to-s/forms-how-to-create-a-hierachical-tree-form
    Edited by: Prabodh on Jun 12, 2012 6:09 PM
    Edited by: Prabodh on Jun 12, 2012 6:32 PM

Maybe you are looking for

  • Can't Install mavericks on SSD

    I have a 2012 Macbook Pro 13". I had a hard disk failure almost 2 weeks ago. [I accidently kept the mac running by using the Caffeine app while keeping macbook in my backpack and roaming around an exhibition]. I saw blinking folder icon and couldn't

  • I am unable to install the creative cloud update - error 43 comes up at around 77%

    I am unable to install the creative cloud update - error 43 comes up at around 77%. I'm a relatively new user.

  • Cannot print a simple Text File

    Hello All, I wrote the following program import java.io.*; import java.awt.print.*; import javax.print.*; import javax.print.attribute.*; import javax.print.attribute.standard.*; public class TestPrint      public static void main(String[] args) thro

  • Oracle 10G

    When Oracle 10G is MOUNT, beside cold backup, and recovery, What can you do ?

  • How do I gain points in LUV?

    QuestionHow do I gain points in LUV? Answer  There are two ways to gain points for LUV. Let me just explain how that works. One way is by giving LUV to another user. Each time you give LUV you'll earn points. See this chart below to see how much you