Passing value thru parameters

select *
from (select b.accode,c.actitle,nvl(sum(b.debit),0) op_dr,nvl(sum(b.credit),0) op_cr
from v_mast a, v_det b, chart c
where a.v_type=b.v_type
and a.vouchno=b.vouchno
and b.accode=c.accode
and a.VOID='F'
and a.posted_by is not null
and a.v_date < '01-JUL-04'
and b.accode in (select accode from account where open='T')
and b.accode in (select accode from chart)
and a.v_type in ('RN','PV','CV','RV','JV')
and b.accode = '0104002'
group by b.accode,c.actitle
order by b.accode )
full join
(select b.accode,c.actitle,nvl(sum(b.debit),0) dur_dr,nvl(sum(b.credit),0) dur_cr
from v_mast a, v_det b, chart c
where a.v_type=b.v_type
and a.vouchno=b.vouchno
and b.accode=c.accode
and a.VOID='F'
and a.posted_by is not null
and a.v_date between '01-JUL-04' and '30-JUN-05'
and b.accode in (select accode from account where open='T')
and b.accode in (select accode from chart)
and a.v_type in ('RN','PV','CV','RV','JV')
and b.accode = '0104002'
group by b.accode,c.actitle
order by b.accode )
using (accode)
Problem :- The above qurey is works perfect but if use parameters instead of using fixed dates it gives an erroe ( "VARIABLE TODT IS NOT DECLARED".
Please expedite.
Regards,
Hassan

select *
from (select b.accode,c.actitle,nvl(sum(b.debit),0) op_dr,nvl(sum(b.credit),0) op_cr
from v_mast a, v_det b, chart c
where a.v_type=b.v_type
and a.vouchno=b.vouchno
and b.accode=c.accode
and a.VOID='F'
and a.posted_by is not null
and a.v_date < :fmdt
and b.accode in (select accode from account where open='T')
and b.accode in (select accode from chart)
and a.v_type in ('RN','PV','CV','RV','JV')
and b.accode = '0104002'
group by b.accode,c.actitle
order by b.accode )
full join
(select b.accode,c.actitle,nvl(sum(b.debit),0) dur_dr,nvl(sum(b.credit),0) dur_cr
from v_mast a, v_det b, chart c
where a.v_type=b.v_type
and a.vouchno=b.vouchno
and b.accode=c.accode
and a.VOID='F'
and a.posted_by is not null
and a.v_date between :fmdt and :todt
and b.accode in (select accode from account where open='T')
and b.accode in (select accode from chart)
and a.v_type in ('RN','PV','CV','RV','JV')
and b.accode = '0104002'
group by b.accode,c.actitle
order by b.accode )
using (accode)
This qurey is running and generating report only and only if I use fixed dates in place of :FMDT and :TODT like '01-JAN-05' , but if I use :FMDT and TODT to ask date parameters at run time then the qurey gives an error at compilation.
I am sure u must have understood kinldy help me out OR do tell me other way to pass vaules thru parameters

Similar Messages

  • Passing values as parameters to an applet

    I would like to pass some parameters from a HTML page to an applet. I want to know which would be better in passing the values to the applet. Will java script, php, or applet be better. The HTML page has some list boxes, text field and i want to pass these values as parameters to my applet which opens in different page. The HTML page & the applet will be in the same codebase.
    Thanks

    Here's an example of what you can do in an Applet:-
    <html>
    <head>
    <title> My slide show</title>
    </head>
    <body>
    <center>
    <applet code ="Show.class" width=480 height=300>
    hspace = "10"
    vspace = "10"
    <PARAMETERS>
    <param name="leg0" value= "1: Some text for this slide">
    <param name="leg1" value= "2: Some other text for this slide">
    <param name="leg2" value= "3: text etc">
    <param name="leg3" value= "4: text etc">
    <param name="leg4" value= "5: text etc">
    <param name="leg5" value= "6: text etc">
    <param name="leg6" value= "7: text etc">
    <param name="leg7" value= "8: text etc">
    </center>
    </applet>
    </body>
    </html>
    The parameters leg0, leg1 etc stand for legend btw and can be got from the web page in an array with this;-
    for (int i=0; i<=7; i++) {
         slide=getImage(getDocumentBase(),"slide"+i+".jpg");
         legends[i]=getParameter("leg"+i);
    Where your images are labelled from slide0 to slide7. This has the advantage of everything having the same value, so if you want to use
    i++;
    everything moves to the same value ie: slide[2] will be = legend[2]
    Finally you will discover at the expense of the learning curve that
    1. This is a far more reliable way for applets to operate
    2. Depending on what you want to do javascript, perl, servlets, JSP and PHP are more robust and reliable.
    Ask the next question !!! What do you want to do? It is possible that an applet can handle it best.

  • Logical DB - passing values for parameters

    Hi experts,
    i writing program basing on logical DB. How can i pass default values for parameters, which are defined in a selection screen for this logical DB?
    Thanks
    Juzio

    in my program PNP is used. identify the selection screen fields. and then use it in initialization event,
    report ztest.
    tables: pernr.
    initialization.
    PNPPERNR-LOW = '12455'.
    PNPPERNR-sign = 'I'.
    PNPPERNR-option = 'EQ'.
    append PNPPERNR.
    PNPBEGDA = SY-DATUM.

  • Passing values to parameters in row created by createInsert method

    Hi,
    I am passing some values from one task flow to other as input parameters for the other.
    There(in second task flow) i am using a createInsert method to create a row.
    How can i pass the values of the input parameters received to the parameters of the createInsert row before reaching create page.
    Any suggestions will be really helpful.
    Thanks.

    User, which jdev version do you use?
    Instead of the createInsert you can use createWithParameters. Check Andrejus Baranovskis's Blog: CreateWithParams Operation for Oracle ADF BC 11g
    Timo

  • Passing values as parameters from forms

    We are trying to use the On successful submission of a form area to forward to a report based on a value entered on the form.
    Is there a way to use a value from the form in the url?

    Here is the code I used. The code in bold allowed me to use the value entered on the form as a parameter for the report I am forwarding to.
    declare
    bidder_id number := 0;
    blk varchar2(10) := 'DEFAULT';
    begin
    bidder_id := p_session.get_value_as_number(p_block_name => blk,
    p_attribute_name => 'A_BIDDER_ID');
    go('PBR.SUM_REG_INFO.show?p_arg_names=pbr_bidder.bidder_id&p_arg_values='||bidder_id);
    end;

  • Passing values to parameters in Documents using se61..

    Hi Experts/Gurus,
    Can we define parameters in SE61 under type "Document  class: General Text" for a document?
    If so can any one please tell the steps?
    Regards,
    Yugesh
    Edited by: Yugesh Reddy on Nov 6, 2009 8:39 AM

    Hi  yugesh,
      Yes you cane create the documentation for document .
        Give the name of the document in Name field and click on create Button .
       now you can write the document and save it.
    Thanks
    Shambhu

  • Passing values thru application Item.

    All,
    Ive issue here with Apex4.1.x.
    I created an application item to which a value is set using javascript like (document.getElementById('P135_GLOBAL1').value = '100'; ) executed onclick when a LIST ITEM is clicked to display another page/page2. On the called page2 i want its region title set to ="Something&135_GLOBAL1." and same application item value i want to assign to another hidden item in the called page/page2......any idea is appreciated.

    koloo wrote:
    All,
    Ive issue here with Apex4.1.x.
    I created an application item to which a value is set using javascript like (document.getElementById('P135_GLOBAL1').value = '100'; ) executed onclick when a LIST ITEM is clicked to display another page/page2. Application item values cannot be set in this way: they only exist in session state on the server, not as HTML elements in the page that can be manipulated using JavaScript DOM methods/properties in the browser. (Furthermore, when setting page items in this way, always use the built-in APEX method<tt>$s</tt> APEX method to set values in JavaScript as this contains logic to correctly process APEX item types.)
    To set the value of application items in JavaScript, use a Dynamic Action with a Set Value action, triggered by a Change event on your list item.

  • Passing values to parameters

    Good morning all,
    I want to assign default value to parameter which is not equal to some fixed value
    for example :if i take currency field .i have to declare waerk field with default not equal to "INR" like that.
    can any one help me in this .
    thanks and regards,
    gopal

    Hi Gopal
    As per my understanding we use DEFAULT to assign a particular fixed value to the parameter.
    However if you do not want to some value like 'INR' in that parameter , you can always check the input at the selection screen before proceeding.
    Something like
    AT SELECTION-SCREEN.
    IF pa_waers = 'INR'.
    MESSAGE e000(Message class)... message can be smtg like 'Please enter a valid currency' etc.
    ENDIF.
    I am not sure if i have understood what you really are asking for.
    Thanks
    Shivika
    Edited by: Shivika Bhorchi on Aug 21, 2008 8:28 AM

  • Pass Values to Edit Form thru Query String and Save in List

    I have developed a custom Edit form from SharePoint Designer and I am passing values thru Query String as below;
    http://<>/cli/acc/Lists/GIInfo/testEdit.aspx?ID=262&com=POD_Send
    And, user supposed to save the form directly without changing the values came thru Query String as below. 
    Now, issue is, when user saves the form, values is not getting saved. It saves when we change the value in text box or when we do a text change event in form. Becasue data binding says Text Change even in data binding property.
    __designer:bind="{ddwrt:DataBind('u',concat('ff22',$Pos),'Text','TextChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Actions')}"/>
    Kindly guide me what is the issue, or correct approach to do that? I want to pass values to Edit Form thru Query string and save in List without changing those.
    -Rajesh A.

    I know this is late, but i found a very good solution on this post and credit goes to the author.
    https://social.msdn.microsoft.com/Forums/sharepoint/en-US/4be1be38-0663-4b80-8f28-45f38f98f9d0/sharepoint-designer-2010-custom-newformaspx-data-in-textbox-fields-dont-save-on-submission?forum=sharepointcustomizationprevious
    The issue was resolved by changing the textbox values,
    <asp:TextBox runat="server" id="ff1{$Pos}" Name="Title" Text="" Value="{$Destination}"  __designer:bind="{ddwrt:DataBind('i',concat('ff1',$Pos),'Text','TextChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Title')}">
    instead of
    <asp:TextBox runat="server" id="ff1{$Pos}" Name="Title" Text="{$Destination}"  __designer:bind="{ddwrt:DataBind('i',concat('ff1',$Pos),'Text','TextChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Title')}">

  • How to pass values of the prompt through Action Link - URL in 11g

    Hi All,
    I am in OBIEE 11g v6.
    Let's say, I have two dashbaord pages P1 and P2.
    P1 page contains
    1. Prompt PR1 - containing a single column EmpName
    2. Report R1
    P2 page contains
    1. Prompt PR2 - containing a single column EmpName (same column as in PR1)
    2. Report R2
    Requirement :
    Let's say a user select a value = David from the EmpName column in prompt PR1. In the Report R1, on one the measure columns 'Sales', I am using an action link - Navigate to URL ( I can't use Navigate to BI Content for some reasons). In the URL, I am giving the URL to page P2. Can I pass the selected value (which is David) to the EmpName column of the Prompt PR2 of Page P2 so that Report R2 is automatically limited by David when I land on that page through the URL?
    Few things to consider are, I can't use EmpName column in my report R1 on page P1, I just want to pass the value of a common column from one prompt on Page1 to another prompt on Page2. Is that possible. Can anybody please help?
    Thanks,
    Ronny

    Hmm can you give a try one more time with
    Add EmpName name and hide it on report R1 on page P1
    and set EmpName as Is Prompted on report R2 on page P2 and with my earlier steps should work.
    Other option is read this doc once that helps you how to pass value thru url.
    http://docs.oracle.com/cd/E21043_01/bi.1111/e16364/apiwebintegrate.htm#z1005224
    You need to have a EmpName as Is Prompted on report R2 on page P2
    If helps pls mark

  • Using Form to pass value to query parameters in the selct part of query

    I created a form in Access 2007 to pass 2 values to an Access query.  I am doing this to create delimited output (very large) with the parameters included in the selected data. The select works and is something like this:
    SELECT "^"+!FORM!EXPORT2DAT!PREF_VALUE+"_"+Replace(UCase([column_1])," ","_")+"^|" AS OUTPUT_column1, "^"+!FORM!EXPORT2DAT!COMPANY_VALUE+[COLUMN_3]+"
    ([COMPANY_VALUE])"+"^|" AS OUTPUT_column2,....................
    The form has text boxes for the values I want to pass PREF_VALUE and COMPANY_VALUE to the query parameters, and an execute button to open the query when clicked.
    However when I enter the values and click the execute button, I still get the parameter boxes for the 2 parameters. 1 for this: !FORM!EXPORT2DAT!PREF_VALUE, and FORM!EXPORT2DAT!COMPANY_VALUE. I thought I was filling in with the form text box values.
    Can I use the form's text boxes to pass values to concatenated using(+) columns in the select part of the query as I'm doing above?
    Thanks in advance for your response.

    I have never seen a select statement like that! 
    For query criteria I would use this --
       [FORMS]![EXPORT2DAT]![PREF_VALUE]
                   and              [FORMS]![EXPORT2DAT]![COMPANY_VALUE]
    Build a little, test a little

  • Passing different (multi-) values for parameters to drill-through report, based on clicked subtotal in main report

    In Report Builder 3.0, I have made a main report in which the user can filter the underlying dataset using three parameters (all multi-value). The report shows totals grouped by these three parameters, as well as a grand total. What I want is to click
    on a total, which then opens the drill-through report for the corresponding records. I have achieved this for the grand total; the action in the corresponding text box passes all selected values of the parameters to the drill-through report.
    What I cannot figure out is how to make this work right when clicking on a subtotal. When I use the same expression as for the grand total, the same values for the parameters are passed, instead of the subset that apply to the corresponding text box in the
    main report. I expected this to work, because Report Builder /does/ correctly calculate the SUMs for the different levels, even though the expressions are the same.
    My question is: how do I pass different drill-through (multi-) values for parameters, corresponding to the respective subtotals in the main report?
    (FYI: I am using Microsoft SQL Server 2008 R2 and Report Builder 3.0 .)

    Hello Katherine,
    Thanks once more for your quick reply.
    I was aware of the textbox action "Go to report", and how to pass parameters in general. My question concerned how to determine the scope of the passed multi-value parameters (to the values that apply to the respective group/subtotal). The article you linked
    to is informative, but not a solution to my problem.
    A colleague of mine came up with a pragmatic solution: instead of trying to determine the scope of the parameter values, now I "look to the left in the results table". The two screenshots below should illustrate this. (Screenshots are in Dutch. Specific information
    is pixelated.)
    Unfortunately, I am not able to post images. Once my account is verified, I will edit them in. For now, I hope the text speaks for itself enough.
    [Screenshot: Drill-through parameters - 01: Report Builder tablix with subtotals]
    [Screenshot: Drill-through parameters - 02: Textbox properties (selected in screenshot 01) - Action - Go to report]
    The first screenshot shows the tablix in the Report Builder. The second screenshot shows the properties of the textbox selected in the first.
    Notice that I do not pass parameters for the first two columns, but the actual values. I only pass the parameter (containing /all/ user-selected values) for the third column. In the textbox below the selected one, I pass the actual values for the first column,
    and parameters for the last two. In the textbox above the selected one, I pass the actual values for all three columns.
    The only (cosmetic) flaw this approach has is that in the drill-through report, the list of selected parameters might show values that do not occur in the (corresponding part of the) results, and only for those parameters for which the main report passes (all
    user-selected) parameter values, and not the actual values in the results. The results are correct, though.
    If there is a way to directly determine the scope of multi-value parameters for passing to a drill-through report, I would still like know. But for now, this seems to work.

  • Passing user defined parameters in oracle reports thru command line

    Hi All
    We are currently using Reports 6i with Oracle 10g 10.2.0.4.0
    I would like to know that is it possible to pass user defined parameters values while calling report from command line.
    For Example: I am using following coding to call report from command line.
    for /f "tokens=1-3 delims=/ " %%a in ('date /t mm/dd/yyyy -1') do (
    set mm=%%b
    set dd=%%a
    set yyyy=%%c)
    rwrun60 report=c:\reports\banks.rdf userid=express/test@test_rs2 destype=FILE desname=c:\reports\banks%dd%%mm%%yyyy%.pdf desformat=PDF BACKGROUND=NO BATCH=YES
    The report contains some user defined parameter which is using in where condition of reqport query.
    Select * from banks
    where id = :Bank_ID
    Now I want to Pass value for :Bank_Id from command line (like we pass parameter list while calling report with run_product), how it is possible?
    Thanks
    Hassan

    Hi guys
    Fortunately I am able to perform the required task as I just added the report parameter field as follows:
    rwrun60 report=c:\reports\banks.rdf userid=express/test@test_rs2 destype=FILE desname=c:\reports\banks%dd%%mm%%yyyy%%h%%mi%%ss%%ts%.pdf desformat=PDF BACKGROUND=NO BATCH=YES ERRFILE=c:\reports\error.log LOGFILE=c:\reports\joblog.log bank_id='MCB'
    bank_id is the report parameter using in where clause.
    Regards,
    Hassan

  • Background Job pass value

    Hi, I am calling a Background job in my program. I am using JOB_OPEN, JOB_SUBMIT and JOB_CLOSE FM to start a job. My need is to pass a value to the job program(job program doesnt have any selection screen values). Is their any way without creating variants each time to pass value to it.
    Please advice.....

    Hello,
    You can first use  JOB_OPEN which returns job number. Then build ranges or parameters to use SUBMIT to call the program.
    Eg: SUBMIT RM06BB20 AND RETURN
          WITH S_EKGRP IN R_EKGRP
          WITH S_EKORG IN R_EKORG
          WITH S_FLIEF IN R_FLIEF
          WITH S_KONNR IN R_KONNR
          USER sy-uname VIA JOB w_jobname
          NUMBER w_job_number.
    Now use JOB_CLOSE.
    Thanks,
    Venu

  • SSRS Report with mutli select values in parameters

    Hi All,
    I am creating a SSRS report and displaying the result in tablix. I want to make the report to filter by multi select values from the parameters.
    I have 3 parameters. For all the three parameters, I have set "Default  Values" and "Available Values". Also, modified my result dataset to get the values from parameters using "WHERE ID = @Parameter1" (example) and so
    on..
    3 Parameters types:   1. Yes or No       
    2. Date          3. Values with NULL in the DB
    Problems:
    1. When I am passing the default values "Yes" "No" - it is throwing errors because default values is passed as Yes "AND" No instead of "OR" condition. The value stored in the DB wil have either Yes or No but not both.
    2. When I am querying the date values, it is a DateTime field in the DB. But I have queried like SELECT CONVERT(DATE, EXE_DATE) AS DATE FROM table which is giving only date in SQL but in SSRS displaying date with time.
    3. When I pull the list of values for third Parameter from SQL, it has some NULL values. When I try to use it in SSRS, it is not displaying the NULL value as select option in the list of values
    Any suggestions for the above three problems for SSRS with multi select values as filter will be helpful.
    Maruthu | My Blog

    Hi Maruthi,
    Regarding the three things:
    1.) I believe your first parameter is mutliselect , please convert it to single select.
    Steps: 
    a.) Select the parameter, right click and go to parameter properties
                    b.) Under General Tab in DataType section remove the checkbox for Allow Multiple Value.
    2.) Instead of returning as the date please return string. For example : 
    SELECT CONVERT(VARCHAR, GETDATE(),101)
    Here is the list of conversion : http://www.sqlusa.com/bestpractices/datetimeconversion/
    3.) As such there is no concept of null in SSRS. (Its a relational concept) . We do have nothing , which means empty. In Order to use null please select the Allow null option in the DataType section of the Parameter, This will add an checkbox for null in
    the report preview. Its developer job to handle the null values in there query.
    Regards Harsh

Maybe you are looking for