How to pass the parameter in "Data Template"

Hi,
Can any one please help me out to sort the problem, "Passing Parameter and checking condition for the parameters in the "data template".
And also please tell me how to link the multiple query in "Data template", as per the user guide i have it says to use link tag. But its not working with my "Data template".
Please check the data template given below and help me out to sort the problem.
And one more thing is in table the data type for number and name is varchar. I dono weather i can use that data type in "Data template", please let me know if i can.
<?xml version="1.0"?>
<dataTemplate name="VENODR_DETAILS">
<parameters>
<parameter name="VENDOR_NUM" dataType="number"/>
<parameter name="VENDOR_NAME" dataType="char"/>
</parameters>
<dataQuery>
<sqlStatement name="Q1">
<![CDATA[SELECT pv.segment1 ven_num,
          pv.vendor_name vname,
                      pvs.vendor_site_code VEN_SIT_CODE,
          pvs.purchasing_site_flag PURCH_SIT_FLG,
          pvs.pay_site_flag PAY_SIT_FLG,
          pv.vendor_name VENDOR_ADDR_NAME,
          pvs.address_line1 VENDOR_ADDR1,
          pvs.address_line2 VENDOR_ADDR2,
          pvs.city VENDOR_CITY,
          pvs.state VENDOR_STATE,
          pvs.zip VENDOR_ZIP
FROM vendors pv,supplier_info pvi,vendor_sites_all pvs
where pv.segment1 = pvi.vendor_id(+)
and pv.vendor_id = pvs.vendor_id
and (pv.segment1=:VENDOR_NUM or pv.vendor_name=:VENDOR_NAME)
]]>
</sqlStatement>
<sqlStatement name="Q2">
<![CDATA[select pvc.area_code||'-'||pvc.phone Contact_Phone,
pvc.last_name||' '||pvc.first_name||' '||pvc.middle_name cname
from vendor_contacts pvc,vendor_sites_all pvs,vendors pv
where pvs.vendor_site_id = pvc.vendor_site_id
and pv.vendor_id = pvs.vendor_id
and pv.segment1=(pv.segment1=:VENDOR_NUM or pv.vendor_name=:VENDOR_NAME)
]]>
</sqlStatement>
</dataQuery>
<dataStructure>
<group name="VENDOR" source="Q1">
<element name="VENDOR_NUMBER" value="ven_num"/>
<element name="VENDOR_NAME" value="vname"/>
<element name="CATEGORY" value="VENDOR_CAT"/>
<element name="UPDATE_DATE" value="UPDATE_DT"/>
     <group name="VENDOR_SITE" source="Q1">
     <element name="VEN_SIT_CODE" value="VEN_SIT_CODE"/>
     <element name="PURCH_SIT_FLG" value="PURCH_SIT_FLG"/>
     <element name="PAY_SIT_FLG" value="PAY_SIT_FLG"/>
     <element name="VENDOR_ADDR1" value="VENDOR_ADDR1"/>
     <element name="VENDOR_ADDR2" value="VENDOR_ADDR2"/>
     <element name="VENDOR_CITY" value="VENDOR_CITY"/>
     <element name="VENDOR_STATE" value="VENDOR_STATE"/>
     <element name="VENDOR_ZIP" value="VENDOR_ZIP"/>
     </group>
</group>
<group name="VENDOR_CONTACT" source="Q2">
<element name="Contact_Phone" value="Contact_Phone"/>
<element name="cname" value="cname"/>
</group>
</dataStructure>
</dataTemplate>
Thanks in advance.
Regards,
SP

Hi Rani,
I see one issue in the Q2 with the where statement:
and pv.segment1=(pv.segment1=:VENDOR_NUM or pv.vendor_name=:VENDOR_NAME)
the right one should be
and pv.vendor_id = :VEN_VENDOR_ID
the variable VEN_VENDOR_ID you have to select from the first query Q1. Add here after select
pv.vendor_id VEN_VENDOR_ID,
Regarding the other question about the data types, well, number and varchar2 is fine, perhaps char also, but go with varchar2 instead.
One last note: you should not mix uppercase and lowercase, keep it clear and structured, check your element names and values.
Best Regards
Volker

Similar Messages

  • How to pass the parameter of a stored procedure to iReport

    Hi... i don't know how to pass the parameter of the stored procedure to the iReport.
    In the Report Query, i tried
    1. sp_storedprocedure ' value'
    2. sp_storedprocedure +''''+$P{parameter}+''''+
    3. sp_storedprocedure +$V+$P{parameter}++$F($F is a variable having a value of ' (a single quote))may you enlighten us please? thank you

    For M$ SQL server I find that it only works when U use the fully qualified name...
    e.g. catalod.dbo.my_procedure_name 'variable'
    My full query in the Report Query window is something like this:
    EXEC arc.dbo.jasper_Invoice 1000
    Note that you may find that selecting from VIEWS / TABLES fails for no apparent reason and iReport will prompt you with the usual very unhelpful (we have what we "pay" for) prompt, stating that "The document is empty".
    To work around this issue, where a statement like "SELECT * FROM arc.dbo.acc_invoices WHERE Invoice_id=1000" does not work, simply create a PROC, something like:
    CREATE PROC jasper_MyProc (@my_rec_id integer) AS
    SELECT * FROM arc.dbo.acc_invoices WHERE Invoice_id= @my_rec_id integer
    ...to wrap your SELECT statement, then call the PROC
    Edited by: Sylinsr on Apr 22, 2008 4:23 PM

  • How to use Report Parameter  on Data Template

    Hello All ,
    I 've tried to create a Report using Data template and Report Parameter. I create a report using data template and I also created a parameter (P_company_name).
    Data Template :
    <dataTemplate name="test_Data_template" description="test" dataSourceRef="test">
    <parameters>
    <parameter name="company_name" dataType="character" include_in_output="false" defaultValue= *** HOW TO DEFINE THE REPORT PARAMETER (P_Company_name) HERE ** />
    </parameters>
    <dataQuery><sqlStatement name="Q1"> <![CDATA[SELECT customer_no,Company_name, from customers where acquisition_id = :company_name  ]]>
    </sqlStatement>
    Report Parameter
    Identifier : P_Company_name
    Data Type : String
    Default Value : Test
    Parameter Type : Text
    When the endusers run the Report they will provide the Company name through the report parameter.
    I have tried to use the same approach that I used to pass the Parameter to SqlQuery on data Template but it is not working . XML Publisher cannot define the parameter.
    How can I do that ?
    If you have any suggestion or document I will really appreciate.
    Thanks,
    Robson

    use this <parameter name="P_Company_name" dataType="character" include_in_output="false" defaultValue= 'Test Value' />and in the querySELECT customer_no,Company_name, from customers where acquisition_id = :P_Company_namehttp://download.oracle.com/docs/cd/E12844_01/doc/bip.1013/e12187/T421739T434255.htm
    Just keep the parameter name in datatemplate and the definition same.

  • How to pass the internal table data to smartforms

    Hi Gurus,
    I have a problem in passing the internal table data to the smartforms. In the print program
    I get the data into one internal table "LT_PRDLBL1". I am passing this internal table to the other in print program by calling the FM_NAME.
    CALL FUNCTION fm_name
      EXPORTING
      ARCHIVE_INDEX              =
      ARCHIVE_INDEX_TAB          =
      ARCHIVE_PARAMETERS         =
        CONTROL_PARAMETERS         = T_SSFCTRLOP
      MAIL_APPL_OBJ              =
      MAIL_RECIPIENT             =
      MAIL_SENDER                =
        OUTPUT_OPTIONS             = T_SSFCOMPOP
        USER_SETTINGS              = ' '
    IMPORTING
      DOCUMENT_OUTPUT_INFO       =
      JOB_OUTPUT_INFO            =
      JOB_OUTPUT_OPTIONS         =
      TABLES
        LT_PRDLBL                 = LT_PRDLBL1
    EXCEPTIONS
       FORMATTING_ERROR           = 1
       INTERNAL_ERROR             = 2
       SEND_ERROR                 = 3
       USER_CANCELED              = 4
       OTHERS                     = 5
    In the print program I had defined the internal tables like
    Data: lt_prdlbl  type standard table of zprdlbl.
    Data: Begin of lt_prdlbl1 occurs 0.
            include structure zprdlbl.
    Data: End of lt_prdlbl1.
    How do I define the internal table in the smartform to get the values printed in the smartform?.
    <REMOVED BY MODERATOR>
    Thanks,
    Edited by: Alvaro Tejada Galindo on Apr 21, 2008 1:01 PM

    Nehal,
    Thanks for quick response.
    In the smartform under the Form Interface->Tables tab
    I had defined
    LT_PRDLBL LIKE ZPRDLBL. If I define TYPE instead of LIKE I get the error message saying "FLAT TYPES may only be referenced using LIKE for table parameters".
    In the main window I have created LOOP, in which I have ticked the internal table and
    LT_PRDLBL INTO LT_PRDLBL. In the text node I am passing the values of this internal table
    &LT_PRDLBL-XXXX&.
    I am able to get the print but the data is not printing.
    Please help me with this.
    Thanks,

  • How to Pass the internal table data?

    DearAll,
    How to pass the Data of one internal table on a 1.html page to another html page for output, in BSP Application.
    regards.

    Hi ,
    In the onInputProcessing event of the first page , write the following code...
    call method NAVIGATION->SET_PARAMETER exporting
        name = 'it_filt_cur'
        value = it_filt_cur.
    Here it_filt_cur is internal table.
              NAVIGATION->GOTO_PAGE('next.htm').
    In the next page , you can make the internal table as auto in the attributes.
    Since you have made the itab as auto transfer , you can directly access the itab in the initialization event of the next page if it is stateless.
    Regards,
    Laxman Nayak.
    Message was edited by: Laxman  Nayak

  • How to pass the page item data from tabA to TabB of a discoverer report

    I have a discoverer repoort, it is master_detail (Dept-Emp) report
    TabA is a master worksheet, which has a page item Deptno
    (the data is from a customized query)
    TabB is detail report which has a Deptno as the page item
    which show the emp detail info on this deptno
    (the date is from another customized query).
    What I want to do is;
    When I change the Deptno in TabA, TabB should automatically change to the deptno of Tab A when I click TabB.
    How can I pass the page item deptno from TabA to page item of TabB?
    Thanks for your help

    Hi.
    You are absolutely right, you cannot create a link from Page Item.
    My Idea was (and I'm sorry taht I didn't mention it at the beginning) to create one link for each and every column in the report in the TabA.
    All these links would be exactly same and pass the Deptno to the TabB.
    So the end user can click wherever he wants (all cells on the worksheets have the link to the TabB) and he is always redirected to the TabB with the Department parameter seted to Deptno Page Item from TabA.
    As I already said before, it is not exactly what you expected, but it's probably the best you can get out of Plus.
    Jakub

  • How to pass the parameter values to the stored procedure from java code?

    I have a stored procedure written in sqlplus as below:
    create procedure spInsertCategory (propertyid number, category varchar2, create_user varchar2, create_date date) AS BEGIN Insert into property (propertyid, category,create_user,create_date) values (propertyid , category, create_user, create_date); END spInsertCategory;
    I am trying to insert a new row into the database using the stored procedure.
    I have called the above procedure in my java code as below:
    CallableStatement sp = null;
    sp = conn.prepareCall("{call spInsertCategory(?, ?, ?, ?)}");
    How should I pass the values [propertyid, category, create_user, create_date) from java to the stored procedure?[i.e., parameters]
    Kindly guide me as I am new to java..

    Java-Queries wrote:
    I have a stored procedure written in sqlplus as below:FYI. sqlplus is a tool from Oracle that provides a user interface to the database. Although it has its own syntax what you posted is actually PL/SQL.

  • How to pass the parameter in the where clause of the select statement

    Hi All,
    Iam getting one of the value from the Input otd and using this value i need to query one of the tables in oracle database and selected the table using the oracle eway otd like shown below .
    otdRISKBLOCK_1.getRISKBLOCK().select() .
    where clause in side the select takes a string parameter as Iam getting the string parameter from the input otd and passing this to where clause by creating a string literal after deployment it is giving an error saying "ORA-00920: invalid relational operator".
    can any one throw some input on this .
    Thanks in Advance
    Srikanth

    You will see this error if the search condition was entered with an invalid or missing relational operator.
    You need to include a valid relational operator such as
      =, !=, ^=, <>, >, <, >=, <=, ALL, ANY, [NOT] BETWEEN, EXISTS, [NOT] IN, IS [NOT] NULL, or [NOT] LIKE in the condition. in the sql statement.
    Can you throw some more light on how are you designing your project?

  • How  to pass the BAPI Parameter

    Hi,
    I can able to connect the Sap using sap .net connector in vb.net. also using SAP .Net Connector wizard in C#.net,i can able to create Dll files of BAPI .also when im adding the dll reference in visualbasic.net it has been added successfully.but after i dont know how to pass the parameter to BAPI function and how to get the return records from BAPI.Can any one guide me how to do this in Visualbasic .net?

    Yes. Thankx . Actualy problem is that SAP .net connector 1.0.1 is not uninstalled completely on my system .
    Now i can able to see all the function using filter in  server explorer.Now i selected BAPI_CUSTOMER_GETLIST.Can you guide how to (code)get the datas into ADOtable or any recordset in Visual basic.net.
    Please give me the example program .
    Thanks in advance
    Message was edited by: Prakash N
    Message was edited by: Prakash N

  • How to pass a parameter into execute sql task and later use it into dataflow task?

    i am in a situation, where i have a logging table in which i have a primary key called ETL_log_ID which is an identity column and acts as a foreign key for various fact table and dimension tables which are populated using SSIS packages. Now i wanna use the
    ETL_log_ID as a parameter in the execute sql task which populates the log table and pass the same value in the data flow task which populates the facts and dimension. Can you let me know how to pass the parameter in a step by step procedure.
    Thanks,
    Nikhil
      

    Nikhil,
    You can check the following :
    http://www.programmersedge.com/post/2013/03/05/ssis-execute-sql-task-mapping-parameters-and-result-sets.aspx
    http://stackoverflow.com/questions/7610491/how-to-pass-variable-as-a-parameter-in-execute-sql-task-ssis
    Regarding the usage in Dataflow task, Can you elaborate on that a little?
    Thanks,
    Jay
    <If the post was helpful mark as 'Helpful' and if the post answered your query, mark as 'Answered'>

  • How to pass dynamic parameter to a database function in OBIEE

    Hi,
    I have a requirement like this. I have to create one report in OBIEE which was in Discoverer. Now in discoverer report there are some calculated item in the worksheet based on database pkg.functions. The parameter which user gives at run time that parameters are then passed to the discoverer calculated items dynamically. But I am not able to do this in OBIEE answers.
    Can anyone tell me step by step how I can able to pass the user selected parameter values in OBIEE answer level.
    The example:
    GET_COMM_VALUE_PTD("AFE Cost & Commitment".Afe Id,:"Period Name(AFE)","AFE Cost & Commitment".Data Sel,"AFE Cost & Commitment".Org Id)
    GET_COMM_VALUE_PTD --- Function database
    ("AFE Cost & Commitment".Afe Id,:"Period Name(AFE)","AFE Cost & Commitment".Data Sel,"AFE Cost & Commitment".Org Id --- Parameters... :"Period Name(AFE)" is the dynamic parameter selected run time by user.
    Please help.
    Thanks
    Titas

    Hi,
    I already did that. But the existing discoverer re value report is showing correct value but the OBIEE report with EVALUATE function shows incorrect value.
    The requirement is to create a OBIEE Dashboard from a Discoverer existing report. Now in discoverer report theere are several calculated items in worksheet level where database custom function is used and user selected parameter value is passed run time in that function. But when that is created in OBIEE with EVALUATE function in RPD, the report shows incorrect data. Could not understand how to pass the parameter value runtime.
    Below is the discoverer 'Show SQL' query and EVALUATE function syntax which has been used.
    SELECT APPS.XXBG_PL_PROJ_ANALYSIS_AFE_PKG.GET_COMM_VALUE_PTD(XXBG_PL_PROJ_AFE_V.AFE_ID,
    :"Period Name(AFE)",
    XXBG_PL_PROJ_AFE_V.DATA_SEL,
    XXBG_PL_PROJ_AFE_V.ORG_ID),
    XXBG_PL_PROJ_AFE_V.AFE_DESC,
    XXBG_PL_PROJ_AFE_V.AFE_NUMBER,
    XXBG_PL_PROJ_AFE_V.APPROVED_AFE_AMOUNT
    FROM APPS.PA_PERIODS_ALL PA_PERIODS_ALL,
    APPS.XXBG_PL_PROJ_AFE_V XXBG_PL_PROJ_AFE_V
    WHERE ((XXBG_PL_PROJ_AFE_V.ORG_ID = PA_PERIODS_ALL.ORG_ID))
    AND (XXBG_PL_PROJ_AFE_V.DATA_SEL = :"Data Selection(AFE)")
    AND (PA_PERIODS_ALL.PERIOD_NAME = :"Period Name(AFE)")
    AND (XXBG_PL_PROJ_AFE_V.AFE_NUMBER = :"AFE Number(AFE)")
    AND (XXBG_PL_PROJ_AFE_V.OPERATING_UNIT = :"Operating Unit(AFE)")
    The EVALUATE function syntax is as below:
    EVALUATE('XXBG_PL_PROJ_ANALYSIS_AFE_PKG.GET_COMM_VALUE_PTD(%1,%2,%3,%4)' AS FLOAT , "BG PL Project Analysis Report_1"."AFE Cost & Commitment"."AFE Cost & Commitment.Afe Id", "BG PL Project Analysis Report_1"."Periods 1"."Periods 1.Period Name", "BG PL Project Analysis Report_1"."AFE Cost & Commitment"."AFE Cost & Commitment.Data Sel", "BG PL Project Analysis Report_1"."AFE Cost & Commitment"."AFE Cost & Commitment.Org Id")
    The PERIOD needs to be passed at run time which user will select.
    Please help to solve the issue.

  • Web link to pass the parameter to custom web app then update the field

    Hi,
    I have created the web link in service request object to refer Account Object. I want to let user able to select the account from web link then base on the current SR no and account that have created update the record in CRMOD. My question is how to pass the parameter out to my external web app so that they can update my SR correctly?
    Thank you

    Hi Messer,
    I have put in the syntax as below :-
    https://secure-ausomxega.crmondemand.com/OnDemand/user/AssocAccountPopup?mapBC=Service+Request&OACTRL=Account&ophi=PopupNewForm.Account+Id&pfid=PopupNewForm&OMTHD=AssocPopup&OMTGT=PopupSearchList&assocInit=Y&opht=4&OAOBJ=Service+Request&mapField=Account&ophd=PopupNewForm.Account&ophpd=3&disableclear=Y&ophr=AssocAccountPopup&assocval=&ParentType=Edit
    This pop up screen wil let the user to select the account then i will pass the account and the SR to external web app to update back the CRMOD. I am not too sure the above syntax is correct or maybe can you give some example.
    I am new in CRMOD, hope that you can advice on this.
    Thank you,
    SK

  • How to pass the data from a input table to RFC data service?

    Hi,
    I am doing a prototype with VC, I'm wondering how VC pass the data from a table view to a backend data service? For example, I have one RFC in the backend system with a tabel type importing parameter, now I want to pass all the data from an input table view to the RFC, I guess it's possible but I don't know how to do it.
    I try to create some events between the input table and data service, but seems there is no a system event can export the whole table to the backend data service.
    Thanks for your answer.

    Thanks for your answer, I tried the solution 2, I create "Submit" button, and ser the mapping scope to  be "All data rows", it only works when I select at least one row, otherwise the data would not be passed.
    Another question is I have serveral imported table parameter, for each table I have one "submit" event, I want these tables to be submitted at the same time, but if I click the submit button in one table toolbar, I can only submit the table data which has a submit button clicked, for other tables, the data is not passed, how can I achieve it?
    Thanks.

  • How to pass the uwl data in BPM to other portal?

    Hi,gurus,
    I have two questions about BPM?
    1. I want to pass the UWL data in BPM to other portal (BEA Websphere portal),how to do that?If websphere portal offered a method  to me,how can I pass the parameter to that method?At first,we want to use the SAP EP uwl,and display the uwl in BEA portal.But at last,they want to create some  tables in BEA and offer a method to CE BPM. So how to do that?
    2.How to call ecc workflow in BPM?And how to call BPM in ECC workflow?
    Thanks in advance.Any help will be appreciated!

    Hi,
    Regarding your qustion on calling SAP Busines Workflow from BPM and vice versa, I think directly it is not possible to give a call. You can invoke outside functionality only if you can expose it as a Web Service which can be used as an automated activity or in a Human Task with custom code.
    Hope this help!!
    Regards,
    Arafat

  • Regarding how to pass the data from web dynpro to workflow

    hi gurus,
    how to pass the data from web dynpro to workflow.
    Regards
    vijay

    Check this [thread|SAP_WAPI_START_WORKFLOW;

Maybe you are looking for

  • Error in Background Job:CALL_FUNCTION_CONFLICT_TYPE

    Hi We ran one job some 2 or 3 times on the same day but it is getting cancelled now due dump error ABAP/4 processor: CALL_FUNCTION_CONFLICT_TYPE. This dump is coming due to parameter type conflict in the function module JOB_CLOSE. Error analysis An e

  • RMIClassLoader hangs

    Hi all! I have a problem (probably) with RMI class loading: under cirtain circumstances (using a native dll b4 rather than after some code) the thread that calls the following code simply hangs (no exception!). Class realClass = java.rmi.server.RMICl

  • Web service enabled BAPI - PI

    Hai, How can I find BAPIs for which web service is enabled (to use in Proxy examples, I dont have auth to SICF and related tcodes for activating etc.) Regards, Bobby

  • Closest Match algorithm using Strings..

    Hi all, I am wondering if there is any built in mechanism, or if not, any thought on how to get find a "close" match in a list of Strings, given a String and a set number of characters to match from the start of the String. Basically I have a combo b

  • Website sound not coming thru iPod Touch - Is there a solution???

    Hello all, I have the iPod Touch and when connecting to the internet with it, to a site such as Sirius.com to listen to music or talk, no audio comes thru. For instance, if I want to log into my sirius.com account, and listen to a talk show, how do I