Pass-parameter to query

Hi guys,
JDev Newbie here.
I wish to make a 2 pagelayout. The main layout is composed of ex. single textbox. If the user pressed enter on that textbox, the 2nd pagelayout. The 2nd pagelayout will use the 1st page layout textbox value for query.
How to achieve it?
Thanks
Criz

http://blogs.oracle.com/shay/2009/01/setting_parameter_for_before_p.html
or
http://blogs.oracle.com/shay/2009/11/passing_value_between_pages_to.html

Similar Messages

  • Problem in passing parameter to query

    SELECT     OWOR.DocNum, OWOR.Series, OWOR.ItemCode AS Parent, WOR1.ItemCode, OWOR.PlannedQty, WOR1.BaseQty, WOR1.PlannedQty AS 'POD Qty',
                          WOR1.IssuedQty, IGE1.Quantity, IGE1.OpenQty, ITM1.Price, OITW.OnHand
    FROM         OITW INNER JOIN
                          IGE1 ON OITW.WhsCode = IGE1.WhsCode RIGHT OUTER JOIN
                          WOR1 INNER JOIN
                          OWOR ON WOR1.DocEntry = OWOR.DocEntry INNER JOIN
                          ITM1 ON WOR1.ItemCode = ITM1.ItemCode ON OITW.ItemCode = ITM1.ItemCode AND IGE1.BaseEntry = WOR1.DocEntry AND
                          IGE1.BaseLine = WOR1.LineNum
    WHERE     (ITM1.PriceList = 1) AND  OWOR.ItemCode='\[%0]'
    ORDER BY OWOR.DocNum
    This query runs if I remove parameter i.e AND  OWOR.ItemCode='\[%0]'.
    What correction should be done to pass parameter in the above query ?

    Dilip,
    You just need to qualify your query with an Alias.  I have fixed it for you..
    SELECT T3.DocNum, T3.Series, T3.ItemCode AS Parent, T2.ItemCode, T3.PlannedQty, T2.BaseQty, T2.PlannedQty AS 'POD Qty', T2.IssuedQty, T1.Quantity, T1.OpenQty, T4.Price, T0.OnHand
    FROM [DBO\].[OITW\] T0 INNER JOIN [DBO\].[IGE1\] T1 ON T0.WhsCode = T1.WhsCode RIGHT OUTER JOIN [DBO\].[WOR1\] T2
    INNER JOIN [DBO\].[OWOR\] T3 ON T2.DocEntry = T3.DocEntry
    INNER JOIN [DBO\].[ITM1\] T4 ON T2.ItemCode = T4.ItemCode ON T3.ItemCode = T4.ItemCode AND T1.BaseEntry = T2.DocEntry AND T1.BaseLine = T2.LineNum
    WHERE (T4.PriceList = 1) AND T3.ItemCode='[%0\]'
    ORDER BY T3.DocNum
    Suda

  • How to pass parameter in query string

    Hi Friends,
    I have a working struts app with Action classes and Servlets...now I need to pass query paramter to one of the servlets,can someone please tell me how to do that.I tried to put this code in web.xml but failed:
    <servlet>
    <servlet-name> test</servlet-name>
    <servlet-class>com.app.Test </servlet-class>
    </servlet>
    <servlet-mapping>
        <servlet-name>test</servlet-name>
        <url-pattern>/app/Test</url-pattern>
      </servlet-mapping>And then I tried to pass parameter as:
    http://localhost:8080/app/Test?param=value
    Please tell me guys how to accomplish this.
    Thanks in advance

    What do you mean by fails? Can you access the Servlet without the parameter? Do you get a null value when trying to retrieve the parameter?

  • Passing parameter in query

    Hi,
    I have one crystal report which retrieves data from Oracle and display report in ASP.NET page.
    I have below query.
    Select * From CustomerDetails cust
    Where cust.Order_date Between ({?From_Order_date} AND {?To_Order_date} )
    AND cust.joining_date({?From_joining_Date} AND {?To_joining_Date} )
    Here I am passing the parameter form ASP.NET page, when I am passing all parameters then it is working fine.
    when I am filtering the data only joining date, then query will be like this.
    Select * From CustomerDetails cust
    Where cust.Order_date Between (null AND null)
    AND cust.joining_date(06/09/2009 AND 08/09/2009)
    and It display 0 records. Any idea to solve this scenerio.

    Modify your query like this and give it a try
    select *
      from CustomerDetails cust
    where (
              ( cust.Order_date between {?From_Order_date} AND {?To_Order_date} )
              or
              ( {?From_Order_date} is null AND {?To_Order_date} is null )
       and (
              ( cust.joining_date between {?From_joining_Date} AND {?To_joining_Date} )
              or
              ( {?From_joining_Date} is null AND {?To_joining_Date} is null )
           )

  • Passing parameter in query dynamically

    -- I have a query that is stored in a table column, the query contains a parameter 
    -- I tried to pass the parameter, but failed. How can I accomplish this task?
    CREATE TABLE #testFullQuery(longString varchar(Max))
    INSERT INTO #testFullQuery(longString) VALUES ('SELECT * FROM @NewValue');
    DECLARE @SourceCode nvarchar(MAX);
    SELECT @SourceCode = longString FROM #testFullQuery
    DECLARE @NewValue VARCHAR(MAX) = 'TableName';  
    DECLARE @FullQuery nvarchar(MAX);
    SET @FullQuery = '';
    SET @FullQuery = @SourceCode 
    EXEC sp_executesql @FullQuery;
    print @fullQuery, @NewValue
    l__j

    Simply replace the placeholder with the value of the variable:
    DECLARE @testFullQuery TABLE (longString varchar(Max))
    INSERT INTO @testFullQuery(longString) VALUES ('SELECT * FROM @NewValue');
    DECLARE @SourceCode nvarchar(MAX);
    SELECT @SourceCode = longString FROM @testFullQuery
    DECLARE @NewValue VARCHAR(MAX) = 'TableName';
    DECLARE @FullQuery nvarchar(MAX);
    SET @FullQuery = '';
    SET @FullQuery = REPLACE(@SourceCode,'@NewValue',@newValue)
    EXEC sp_executesql @FullQuery;
    print @fullQuery

  • 'Driver]Parameter missing' Error while trying to pass parameter to MS query & Return Data to Microsoft Excel

    I am trying to set up a parameter query using ODBC-Microsoft Query
    to BMC Remedy The ODBC connection is "AR System ODBC Data Source".
    I want to pass a parameter to modified date field and get all the remedy tickets for which the modified date is<= to the passed parameter date.
    So in MS query, SQL- 
    the query looks like
     WHERE ("Trouble Ticket"."Create Date">={ts '2014-10-01 00:00:00'}) AND ("Trouble Ticket"."Modified-date"<=?)
    I am getting the data fetched from database in the MS query window, but unfortunately
    When I click File-Return Data to Microsoft Excel, its showing an error: Driver]Parameter missing
    I set the connection properties- parameter-Prompt for value using the following string.
    Please help

    Hi,
    Based on the error message, I recommend we try the suggestion: Replace all "..."  with [...]
    http://www.pcreview.co.uk/forums/error-parameter-query-odbc-remedy-bmc-software-com-t3232964.html
    Then, if you want to connect the Remedy's oracle database, please see the thread:
    http://www.tek-tips.com/viewthread.cfm?qid=1123112
    We may try the workaround: Write an Excel macro which connects to the database and fetch the data based on the SQL query.
    Please Note: Since the web site is not hosted by Microsoft, the link may change without notice. Microsoft does not guarantee the accuracy of this information.
    If you have further question about write macro, I recommend you post the question to the MSDN forum for Excel
    http://social.msdn.microsoft.com/Forums/en-US/home?forum=exceldev&filter=alltypes&sort=lastpostdesc
    The reason why we recommend posting appropriately is you will get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction with us. Thank you for your understanding.
    George Zhao
    TechNet Community Support
    It's recommended to download and install
    Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
    programs.

  • How to pass multiple query string values using the same parameter in Query String (URL) Filter Web Part

    Hi,
    I want to pass multiple query string values using the same parameter in Query String (URL) Filter Web Part like mentioned below:
    http://server/pages/Default.aspx?Title=Arup&Title=Ratan
    But it always return those items whose "Title" value is "Arup". It is not returned any items whose "Title" is "Ratan".
    I have followed the
    http://office.microsoft.com/en-us/sharepointserver/HA102509991033.aspx#1
    Please suggest me.
    Thanks | Arup
    THanks! Arup R(MCTS)
    SucCeSS DoEs NOT MatTer.

    Hi DH, sorry for not being clear.
    It works when I create the connection from that web part that you want to be connected with the Query String Filter Web part. So let's say you created a web part page. Then you could connect a parameterized Excel Workbook to an Excel Web Access Web Part
    (or a Performance Point Dashboard etc.) and you insert it into your page and add
    a Query String Filter Web Part . Then you can connect them by editing the Query String Filter Web Part but also by editing the Excel Web Access Web Part. And only when I created from the latter it worked
    with multiple values for one parameter. If you have any more questions let me know. See you, Ingo

  • How to pass parameter to the Query String of the Named Queries'SQL

    Firstly to say sorry,I'm a beginner and my English is very little.
    Now I want to know
    How to pass parameter to the Query String of the Named Queries'SQL in the Map editor.
    Thanks.

    benzi,
    Not sure if this is on target for your question, but see #5 in the link below for some web screencasts that show how to pass an input text form field value to the bind variable of a view object. If you're looking for something different, maybe provide some more details such as what you are trying to accomplish and what technology stack you are using - for example, ADF BC, JSF, etc.
    http://radio.weblogs.com/0118231/stories/2005/06/24/jdeveloperAdfScreencasts.html
    Also see section 5.9 and chapter 18 in the developer's guide.
    thanks

  • From scorecard Pass parameter to be used as Measure in query of analytic Grid report in PPS in SP2013

    From scorecard Pass parameter  to be used as Measure in query of analytic grid report in PPS
    Any idea of how we can pass this parameter while connecting scorecard and report
    any use of MDX in connection formula ?
    Parameter needs to be assigned on click of scorecard cell

    Hi,
    That API has restrictions on its usage. Please see http://docs.oracle.com/cd/E23903_01/doc/doc.41/e21676/apex_util.htm#CHDICGDA
    The lines to be referred to are Also, this method requires that the parameters that describe the BLOB to be listed as the format of a valid item within the application. That item is then referenced by the function.Regards,
    PS: Your report must be on Page 98 , so it is able to reference the item P98_NAV_IMAGE. List being a Shared Component it may not be able reference that Item.
    Edited by: Prabodh on May 28, 2012 3:16 PM

  • How to get month value from custom calendar without passing parameter from SSRS in MDX query

    Could you please throw some light to achieve below requirement?  
    I need to filter the data between two periods dynamically . The date calendar here works differently(ex:-Date 26-Aug-2014 will fall in period 7 which is last date and 27-Aug-2014 will fall in period 8 and it is first date of period 8),so I cannot go
    with system date period/Month. Date Hierarchy is like YEAR,QUARTER,PERIOD ,WEEK and DAY.
    I cannot use SSRS for passing parameter. Requirement is to extract last 2 period of data dynamically in Power Pivot with MDX.
    Thanks Chandan

    Hi Chandan,
    You might try something like this
    Tail(null:
    Extract(
    StrToMember("[FYDay].[DATE].&[ + cStr(Format(Now(),"yyyy-MM-ddT00:00:00")) + "]")
    *[FYDay].[DateHierarchy].[Day]
    ,[FYDay].[DateHierarchy]).parent.parent
    ,2)
    What it is doing is multiplying Day by the current date, which returns a set of one date with cardinality of (Date,Day).  The Extract is pulling out just the datehierarchy Day.  the the Tail() is getting it and the previous day.
    Hope that helps,
    Richard

  • How to pass parameter values to Bex query through xcelsius (LO or QWAAS)

    Hi,
    I have prompt in Bex query and want to pass values to query prompt through xcelsius .
    In xcelsius i have selection
    e.g 1] Combo selection is for Vendor
    2] Combo selection is for Fiscal Year
    If i select value from Combo list  and refresh the dashboard im getting below error
    A database error occured. The database error text is: The MDX query SELECT  { [Measures].[4IKKZVYWWD3XKQK7Z1BK34VTL], [Measures].[4IKKZVJJUFWIJHHBND6VJ0YE1], [Measures].[4IKKZV46SIP3I8EFBP26YX0YH], [Measures].[4IKKZUOTQLHOGZBJ00XIET3IX] }  ON COLUMNS , NON EMPTY [0CREDITOR].[LEVEL01].MEMBERS ON ROWS FROM [0FIAP_O03/ZFIAP_O03_UNIVERSE] SAP VARIABLES [VN_VAR] INCLUDING A00140 [0S_FYEAR] INCLUDING V3/2010 : V3/2010 failed to execute with the error Unknown error. (WIS 10901)
    I have tried using LO and QWAAS but not able to do so......
    if any one knows plz help....

    Hi,
    most likely yo are passing the wrong value.
    you need to send the key or the member unique name.
    Ingo

  • Issue on How to mimic Deski document from CMS to local machine, pass parameter, execute and save in a mutiple report format then store in a network drive.

    Post Author: usaitconsultant
    CA Forum: JAVA
    Would you know if there's a way to mimic Deski
    document from BOXI server(CMS) to local machine, pass parameter, execute and
    save in a mutiple report format then store in a local drive or network
    drive? Most examples and tutorials in BO XI R2 I've seen are scheduling while drilling report is for web intelligence only and not desktop intelligence.  Please let me know your ideas. I would really appreciate your help. Thanks.

    Post Author: usaitconsultant
    CA Forum: JAVA
    Hi Ted,
    Thanks for the reply.The file is not available in the server. Though, I checked CMS and I found an instance in history tab and the status is failed with error below. 
                Error Message:
                A variable prevented the data provider Query 1 with BANRRD30 from being refreshed. (DMA0008).When I checked my codes, I found out that the object Im using is for web intelligence data provider. However, I cannot find any documentation and example for passing parameter values in desktop intelligence data provider. Any idea on this? You think this is not suported by Report Engine SDK?Thanks.    

  • How to pass parameter [bind variable or substitution variable] to a view?

    How can I pass a parameter [bind variable or substitution variable] to a view in Oracle?
    Some will tell me that this is not necessary, that I can only pass the parameter when I query the view, but I found some case where this cause performance issue. In long view where I use subquery factoring [WITH], it's necessary to pass the parameter many time through different subqueries and not only to the resulting view.
    In other database (SQL Server, Access), we can pass parameters through query. I can't find how to do that in Oracle. Can some one tell me what is the approach suggest by Oracle on that subject?
    Thank you in advance,
    MB
    What I can do:
    CREATE VIEW "HR"."EMP_NAME" ("FIRST_NAME", "LAST_NAME")
    AS
    SELECT FIRST_NAME, LAST_NAME FROM EMPLOYEES;
    What I want to do:
    CREATE VIEW "HR"."EMP_NAME" ("FIRST_NAME", "LAST_NAME")(prmEMP_ID)
    AS
    SELECT FIRST_NAME, LAST_NAME FROM EMPLOYEES WHERE EMPLOYEE_ID IN (:prmEMP_ID);

    Blais wrote:
    How can I pass a parameter [bind variable or substitution variable] to a view in Oracle?
    Some will tell me that this is not necessary, that I can only pass the parameter when I query the view, but I found some case where this cause performance issue. In long view where I use subquery factoring [WITH], it's necessary to pass the parameter many time through different subqueries and not only to the resulting view.Yes, there can be performance issues. Views are a form of dynamic SQL and it is hard to predict how they will perform later.
    You can't pass parameters to a view. They are not functions. The mechanism to put the values in is what you mentioned, passing the parameter when you query the view.
    In other database (SQL Server, Access), we can pass parameters through query. I can't find how to do that in Oracle. Can some one tell me what is the approach suggest by Oracle on that subject? This functionality is not supported.
    What I can do:
    CREATE VIEW "HR"."EMP_NAME" ("FIRST_NAME", "LAST_NAME")
    AS
    SELECT FIRST_NAME, LAST_NAME FROM EMPLOYEES;
    What I want to do:
    CREATE VIEW "HR"."EMP_NAME" ("FIRST_NAME", "LAST_NAME")(prmEMP_ID)
    AS
    SELECT FIRST_NAME, LAST_NAME FROM EMPLOYEES WHERE EMPLOYEE_ID IN (:prmEMP_ID);Include the bind value when you use the view in a SELECT. The value will be applied to the view at run-time, somthing like
    CREATE  VIEW "HR"."EMP_NAME_VW" ("FIRST_NAME", "LAST_NAME","EMPLOYEE_ID")(prmEMP_ID)
    AS  SELECT FIRST_NAME, LAST_NAME FROM EMPLOYEES;
    select *
      from emp_name_vw
      WHERE EMPLOYEE_ID IN (:prmEMP_ID);To use EMPLOYEE_ID I added it to your list of columns in the view so it can be referenced in the WHERE clause. If you don't want to see that value don't select it from the view.

  • Looking for a way to pass parameter to external list from infopath

    Hey, i have a Sharepoint 2010 list for which I want to create Infopath form. I have an external content type and external list based on it.
    I want to prepopulate some fields in my Sharepoint list with data from external list. I tried to use external list as a secondary data source and query it for needed values. The issue I encounter is that my ECT has a finder with filter and I can't figure
    out how to pass a value to this filter within infopath.
    How can it be done with infopath? How can I pass the filter value to the external list using Infopath?

    Hi,
    According to your post, my understanding is that you wanted to pass parameter to external list from infopath.
    You need to query the external list from InfoPath using coding and CAML Query.
    Here is a similar thread for your reference:
    http://sharepoint.stackexchange.com/questions/33575/filtering-sharepoint-external-list-bcs-from-infopath
    Thanks,
    Linda Li
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Linda Li
    TechNet Community Support

  • Passing parameter in a method

    hi i have a situation where i have to pass parameter to my method i don't what to pass the parameter define from the viewO because am not using parameter to query from the view,i just what to pass it to my procedure,my method is
                    public void submit_agr(String par_id,String dref_id,String tas_id,String agr_id){
                        ViewObject sub = this.findViewObject("AGR1");
                      i don't what to use this-> sub.setNamedWhereClauseParam("tas_id", tas_id); the tas_id is not in AGR1 VIEWO
                      // sub.
                        sub.executeQuery();
                        Row row = sub.first();
                        par_id = (String)row.getAttribute("par_id");
                        agr_id = (String)row.getAttribute("id");
                        callPerformSdmsLogon("SMS_FORM_TO_ADf.delete_agr(?)", new  Object[] {par_id,dref_id,tas_id,agr_id});
                    }

    i try this AM IN jDEVELOPER 11.1.2.1.0
                    public void submit_agr(String par_id,String dref_id,String tas_id,String agr_id){
                        ViewObject sub = this.findViewObject("AGR1");                 
                        Row row = sub.first();
                        sub.setNamedWhereClauseParam("tas_id", new Number(10));-how will i pass this to my procedure
                        sub.setNamedWhereClauseParam("dref_id", new Number(10));-how will i pass this to my procedure
                        par_id = (String)row.getAttribute("par_id");
                        agr_id = (String)row.getAttribute("id");
                        sub.executeQuery();
                        callPerformSdmsLogon("SMS_FORM_TO_ADf.delete_agr(?)", new  Object[] {par_id,dref_id,tas_id,agr_id});
                    }how will i pass the two prameter to my procedure
    Edited by: Tshifhiwa on 2012/07/01 3:14 PM

Maybe you are looking for

  • Opening a .txt file from an application

    I have an application that extends JFrame. There is a JButton that I want to use to open a file called "Instructions.txt." and the path to the file is "E:\CM0112\Code\Instructions.txt". I want to open this file using TextPad, I have tried the code Ru

  • Missile Command widget

    While this new widget is fun, it eats up CPU capacity, even when not playing!  My Mac Mini was running hot (fan going fast) and I didn't have that much open, so I opened Activity Monitor and found that the widget was using 30% of the CPU, and I wasn'

  • Snow Leopard distroyed Norton! Help!

    Um... My Norton won't work now that I have upgraded to Snow Leopard. It kept telling me that it was Error 10, I think? Now it isn't giving me the message anymore but the Auto File Scan is still not functioning. The only problem I found was that Snow

  • Will an imessage show as 'delivered' if the recipients battery is dead??

    While using the imessage text feature on the iphone 4, will an imessage show as 'delivered' if the recipients battery is dead at the time the message was sent?

  • Good bye Safari, hello Chrome

    I just started using Google Chrome browser on my new iPad Air and it blazes compared to Safari.   Also the one thing I found terribly frustrating with Safari is the auto page refresh when you switch between tabs or switch between apps -- slow perform