How to pass a litral string into cursor variable?

Hi All
I have a code like below:
I need to select the following table,column with the criteria as such but it looks like the literal string does not work for cursor variable.
I can run the SQL in sqlplus but how I can embed that in PL/SQL code??
-Thanks so much for the help
cursor ccol2(Y1 varchar2) is select table_name,column_name from user_tab_columns
where table_name like 'HPP2TT%' and table_name like '%Y1'
and column_name not in ('MEMBERID');

Literal strings are fine in a cursor, however, your logic is likely wrong, and you are not using the Y1 parameter to the cursor correctly. If you are looking for tables that either start with HPP2TT or end with Y1 (whatever you pass as Y1), then you need something more like:
cursor ccol2(Y1 varchar2) is
select table_name, column_name
from user_tab_columns
where (table_name like 'HPP2TT%' or
       table_name like '%'||Y1) and
      column_name not in ('MEMBERID');In the unlikely event that you are lookig for table that actually do start with HPP2TT and end in whatever is passed in Y1 then your query could be simplified to:
cursor ccol2(Y1 varchar2) is
select table_name, column_name
from user_tab_columns
where table_name like 'HPP2TT%'||Y1 and
      column_name not in ('MEMBERID');Note in both cases, a single member in-list is bad practice, although Oracle will transform it to an equality predicate instead.
John

Similar Messages

  • How to pass the grep result into a variable in Unix

    I have the following statements in my unix batch script:
    JOBNAME=`grep "$1" rssc_plsbatch.txt|awk -F'~' '{print $1}'`;
    PROCNAME=`grep "$1" rssc_plsbatch.txt|awk -F'~' '{print $2}'`;
    JOBDESC=`grep "$1" rssc_plsbatch.txt|awk -F'~' '{print $3}'`;
    PARMS=`grep "$1" rssc_plsbatch.txt|awk -F'~' '{print $4}'`;
    I want to grep the the first line in the text file and pass it to a variable and then using awk programming, I want to print for each variable (JOBNAME, PROCNAME, JOBDESC and PARMS), instead of using grep 4 times.
    Can somebody please help.
    Each line of my text file is in the the following format:
    00001JOB1~PROCNAME1~This is a procedure~10,'A','B'~
    And also I want to check whether $1 passed (part of JONAME) is not fount, then it should exit with error message, if $1 (input parameter) does not match, I want to exit the program, instead of processing further statements.

    If you want to return error codes, you can do that with the return command.
    If the process name isn't found, grep will return a specific error code... from man grep
    Normally, exit status is 0 if selected lines are found and 1 otherwise.
    But the exit status is 2 if an error occurred, unless the -q or quiet or silent option is used and a selected line is found.
    So you can use the exit code of grep in an if statement to decide what return code you want to return with your own script.
    Mike

  • How to pass in a parameter into a report viewer on a jsp - and hidden

    Hi, I've built a php application and am using the java environment to enable the crystal report/viewer.  The developer was looking how to pass in a parameter into a report viewer on a jsp. Ultimately the end product we need is to get an HTML report viewer loading a report file with hidden parameters so to not expose other customer data (it's a shared database for multiple customers) preferably loaded from php using maybe the php java bridge. Would anyone happen to have any sample code or any guidance?
    <%@ page contentType="text/html; charset=UTF-8"
       pageEncoding="ISO-8859-1"%>
    <%@ taglib uri="/crystal-tags-reportviewer.tld" prefix="crviewer"%>
    <%
    // just a test to grab rpt name from GET
    String rptFile = "report_files/" + request.getParameter("rpt");
    %>
    <crviewer:viewer reportSourceType="reportingComponent" viewerName=""
    isOwnPage="true">
       <crviewer:report reportName="<%= rptFile %>" />
    </crviewer:viewer>
    Many thanks in advance!
    Mark

    I am not aware of any html tags you can pass to the viewer for parameter values.  Normally, you would load the report in code and then use the SDK with the report object to pass parameter values.

  • How to pass apex item value into custom xml for chart or guage?

    Re-opening the old thread : Re: How to pass apex item value into custom xml for chart or guage?
    Which was not answered.
    Roel - Thanks. Its working - but in a semi quotes in the custom XML
    <pointers>
    <pointer value= '&P5_RUNNING_TOTAL.'
    <label enabled="true">
    <position placement_mode="ByPoint" x="50" y="15" />
    <format>{%Value}{numDecimals:1}</format>
    <background enabled="false" />
    </label>
    </pointer>
    </pointers>This question was helpful for us to resolving one recent thread : AnyChart - set Dial axis intervals dynamically?
    (Re: AnyChart - set Dial axis intervals dynamically?
    Edited by: P.Ranish on Dec 13, 2012 6:23 AM

    P.Ranish wrote:
    Is there any update for this question ???
    Edited by: P.Ranish on Dec 13, 2012 3:36 AMNo, And there won't be in the future.
    Please stop posting followup's to old threads, if you have a real problem please search the forum first and post a new question with all information
    Roel wrote:
    Try using &P5_RUNNING_TOTAL. or #P5_RUNNING_TOTAL#Just to make it clear - this will only work if page is reloaded after setting the item values dynamically via AJAX

  • How do you turn a string into an integer?

    how do you turn a string into an integer?
    for ex, if i wanted to turn the string "5" into the integer 5, how would i do that?

    String stringNumber="5";
    try{
    int number=Integer.parseInt(stringNumber);
    }catch(NumberFormatException e){
    System.out.println("The string "+stringNumber+" must be a number!");
    }

  • How to pass Input file data into BAPI BAPI_0035_CREATE

    Hi Friends,
    Need a help.. First time i am developing a report using this BAPI BAPI_0035_CREATE..
    actually i am uploading the Input file data using this BAPI.. my input file having 14 fields.. this 14 fields are corresponding into difeerent strutures and tables to  this bapi.. so after completion GUI_UPLOAD , how to Pass this internal table into this BAPI strutures and tables  for creating the GRANTS in the system.
    Regrads,
    Kumar.

    Execute the function module "BAPI_0035_GET_DETAIL" passing Grant number to get an idea about what needs to be passed into "BAPI_0035_CREATE".

  • How can i write a string into a specified pos of a file?

    How can i write a string into a specified pos of a file without read all file into ram and write the whole file again?
    for example:
    the content of file is:
    name=123
    state=456
    i want to modify the value of name with 789
    (write to file without read all file into ram)
    How can i do it? thank you

    take this as an idea. it actually does what i decribed above. you sure need to make some modifications so it works for your special need. If you use it and add any valuable code to it or find any bugs, please let me know.
    import java.io.*;
    import java.util.*;
    * Copyright (c) 2002 Frank Fischer <[email protected]>
    * All rights reserved. See the LICENSE for usage conditions
    * ObjectProperties.java
    * version 1.0, 2002-09-12
    * author Frank Fischer <[email protected]>
    public class ObjectProperties
         // the seperator between the param-name and the value in the prooperties file
         private static final String separator = "=";
         // the vector where we put the arrays in
         private Vector PropertiesSet;
         // the array where we put the param/value pairs in
         private String propvaluepair[][];
         // the name of the object the properties file is for
         public String ObjectPropertiesFileName;
         // the path to the object'a properties file
         public String ObjectPropertiesDir;
         // reference to the properties file
         public File PropertiesFile;
         // sign for linebreak - depends on platforms
         public static final String newline = System.getProperty("line.separator");
         public ObjectProperties(String ObjectPropertiesFileName, String ObjectPropertiesDir, ObjectPropertiesManager ObjectPropertiesManager)
         //     System.out.println("Properties Objekt wird erzeugt: "+ObjectPropertiesFileName);
              this.ObjectPropertiesFileName = ObjectPropertiesFileName;
              this.ObjectPropertiesDir = ObjectPropertiesDir;
              // reference to the properties file
              PropertiesFile = new File(ObjectPropertiesDir+ObjectPropertiesFileName);
              // vector to put the param/value pair-array in
              PropertiesSet = new Vector();
         //     System.out.println("Properties File Backup wird erzeugt: "+name);
              backup();
         //     System.out.println("Properties File wird eingelesen: "+PropertiesFile);
              try
                   //opening stream to file for read operations
                   FileInputStream FileInput = new FileInputStream(PropertiesFile);
                   DataInputStream DataInput = new DataInputStream(FileInput);
                   String line = "";
                   //reading line after line of the properties file
                   while ((line = DataInput.readLine()) != null)
                        //just making sure there are no whitespaces at the beginng or end of the line
                        line = cutSpaces(line);
                        if (line.length() > 0)
                             //$ indicates a param-name
                             if (line.startsWith("$"))
                                  // array to store a param/value pair in
                                  propvaluepair = new String[1][2];
                                  //get the param-name
                                  String parameter = line.substring(1, line.indexOf(separator)-1);
                                  //just making sure there are no whitespaces at the beginng or end of the variable
                                  parameter = cutSpaces(parameter);
                                  //get the value
                                  String value = line.substring(line.indexOf(separator)+1, line.length());
                                  //just making sure there are no whitespaces at the beginng or end of the variable
                                  value = cutSpaces(value);
                                  //put the param-name and the value into an array
                                  propvaluepair[0][0] = parameter;
                                  propvaluepair[0][1] = value;
                             //     System.out.println("["+ObjectPropertiesFileName+"] key/value gefunden:"+parameter+";"+value);
                                  //and finaly put the array into the vector
                                  PropertiesSet.addElement(propvaluepair);
              // error handlig
              catch (IOException e)
                   System.out.println("ERROR occured while reading property file for: "+ObjectPropertiesFileName);
                   System.out.println("ERROR CODE: "+e);
                   // System.out.println("in ObjectProperties");
         // function to be called to get the value of a specific paramater 'param'
         // if the specific paramater is not found '-1' is returned to indicate that case
         public String getParam(String param)
              // the return value indicating that the param we are searching for is not found
              String v = "-1";
              // looking up the whole Vector
              for (int i=0; i<PropertiesSet.size(); i++)
                   //the String i want to read the values in again
                   String s[][] = new String[1][2];
                   // trying to get out the array from the vector again
                   s = (String[][]) PropertiesSet.elementAt(i);
                   // comparing the param-name we're looking for with the param-name in the array we took out the vector at position i
                   if (s[0][0].equals(param) == true)
                        //if the param-names are the same, we look up the value and write it in the return variable
                        v = s[0][1];
                        // making sure the for loop ends
                        i = PropertiesSet.size();
              // giving the value back to the calling procedure
              return v;
         // function to be called to set the value of a specific paramater 'param'
         public void setParam(String param, String value)
              // looking up the whole Vector for the specific param if existing or not
              for (int i=0; i<PropertiesSet.size(); i++)
                   //the String i want to read the values in again
                   String s[][] = (String[][]) PropertiesSet.elementAt(i);
                   // comparing the param-name we're looking for with the param-name in the array we took out the vector at position i
                   if (s[0][0].equals(param) == true)
                        //if the param-names are the same, we remove the param/value pair so we can add the new pair later in
                        PropertiesSet.removeElementAt(i);
                        // making sure the for loop ends
                        i = PropertiesSet.size();
              // if we land here, there is no such param in the Vector, either there was none form the beginng
              // or there was one but we took it out.
              // create a string array to place the param/value pair in
              String n[][] = new String[1][2];
              // add the param/value par
              n[0][0] = param;
              n[0][1] = value;
              // add the string array to the vector
              PropertiesSet.addElement(n);
         // function to save all data in the Vector to the properties file
         // must be done because properties might be changing while runtime
         // and changes are just hold in memory while runntime
         public void store()
              backup();
              String outtofile = "# file created/modified on "+createDate("-")+" "+createTime("-")+newline+newline;
              try
                   //opening stream to file for write operations
                   FileOutputStream PropertiesFileOuput = new FileOutputStream(PropertiesFile);
                   DataOutputStream PropertiesDataOutput = new DataOutputStream(PropertiesFileOuput);
                   // looping over all param/value pairs in the vector
                   for (int i=0; i<PropertiesSet.size(); i++)
                        //the String i want to read the values in
                        String s[][] = new String[1][2];
                        // trying to get out the array from the vector again
                        s = (String[][]) PropertiesSet.elementAt(i);
                        String param = "$"+s[0][0];
                        String value = s[0][1];
                        outtofile += param+" = "+value+newline;
                   outtofile += newline+"#end of file"+newline;
                   try
                        PropertiesDataOutput.writeBytes(outtofile);
                   catch (IOException e)
                        System.out.println("ERROR while writing to Properties File: "+e);
              catch (IOException e)
                   System.out.println("ERROR occured while writing to the property file for: "+ObjectPropertiesFileName);
                   System.out.println("ERROR CODE: "+e);
         // sometimes before overwritting old value it's a good idea to backup old values
         public void backup()
              try
                   // reference to the original properties file
                   File OriginalFile = new File(ObjectPropertiesDir+ObjectPropertiesFileName);
                   File BackupFile = new File(ObjectPropertiesDir+"/backup/"+ObjectPropertiesFileName+".backup");
                   //opening stream to original file for read operations
                   FileInputStream OriginalFileInput = new FileInputStream(OriginalFile);
                   DataInputStream OriginalFileDataInput = new DataInputStream(OriginalFileInput);
                   //opening stream to backup file for write operations
                   FileOutputStream BackupFileOutput = new FileOutputStream(BackupFile);
                   DataOutputStream BackupFileDataOutput = new DataOutputStream(BackupFileOutput);
              //     String content = "";
                   String line = "";
                   // do till end of file
                   while ((line = OriginalFileDataInput.readLine()) != null)
                        BackupFileDataOutput.writeBytes(line+newline);
              // error handlig
              catch (IOException e)
                   System.out.println("ERROR occured while back up for property file: "+ObjectPropertiesFileName);
                   System.out.println("ERROR CODE: "+e);
                   System.out.println("this is a serious error - the server must be stopped");
         private String cutSpaces(String s)
              while (s.startsWith(" "))
                   s = s.substring(1, s.length());
              while (s.endsWith(" "))
                   s = s.substring(0, s.length()-1);
              return s;
         public String createDate(String seperator)
              Date datum = new Date();
              String currentdatum = new String();
              int year, month, date;
              year = datum.getYear()+1900;
              month = datum.getMonth()+1;
              date = datum.getDate();
              currentdatum = ""+year+seperator;
              if (month < 10)
                   currentdatum = currentdatum+"0"+month+seperator;
              else
                   currentdatum = currentdatum+month+seperator;
              if (date < 10)
                   currentdatum = currentdatum+"0"+date;
              else
                   currentdatum = currentdatum+date;
              return currentdatum;
         public String createTime(String seperator)
              Date time = new Date();
              String currenttime = new String();
              int hours, minutes, seconds;
              hours = time.getHours();
              minutes = time.getMinutes();
              seconds = time.getSeconds();
              if (hours < 10)
                   currenttime = currenttime+"0"+hours+seperator;
              else
                   currenttime = currenttime+hours+seperator;
              if (minutes < 10)
                   currenttime = currenttime+"0"+minutes+seperator;
              else
                   currenttime = currenttime+minutes+seperator;
              if (seconds < 10)
                   currenttime = currenttime+"0"+seconds;
              else
                   currenttime = currenttime+seconds;
              return currenttime;

  • Pls help...How to pass a executed value to a variable?

    hi everyone im new here..
    ok im having prob in passing the executed value of a string into a variable for me to manupulate the value. sample codes as below :
    declare @Str varchar(500)
    declare @Str1 varchar(50)
    declare @Int varchar(50)
    declare @Str2 varchar(50)
    set @Str1 = 'where ET.isVerified = 1'
    set @Str = 'select sum(ET.Sundries+ET.Entertainment+ET.BalReimbursement+ET.Fee+ET.TrainerCharges+ET.SeminarPack+ET.Food+ET.Accomodation+ET.Flight) from ExpensesTransactions ET ' + @Str1
    EXEC(@Str)
    Answer : 16935.00
    so now i want to pass the output(Answer) into a variable so that i can insert the value into a table. anyone can help me in this thing . thank you so much..
    regards
    -nash-

    hi Jurek
    thanx for ur help dude, i change as what u said but i got this error msg "Incorrect syntax near '@Answer'"
    declare @Str varchar(500)
    declare @Str1 varchar(50)
    declare @Int varchar(50)
    declare @Str2 varchar(50)
    declare @Answer varchar(50)
    set @Str1 = 'where ET.isVerified = 1'
    set @Str = ' BEGIN select sum(....) INTO @Answer From ExpensesTransactions ET ' + @Str1 + ' END;'
    EXEC(@Str)
    print @Answer
    but then i change the script abit to 'Begin select....' + @Answer + ' From ..' + @Str1 + 'END;'...this time i got no error msg but there is no value in variable @Answer...
    thanx everyone
    - nash -

  • Passing Order By String to Cursor

    Hello, I am attempting to do the following:
    Pass a parameter to a cursor that tells the cursor what to order by. I.e., if user clicks a date column, the tablename_datecolumn string is passed to the cursor. I thought this would have been relatively simple. However, for some reason, I can't get the following to work:
    PROCEDURE my_procedure (pv_sort_code IN VARCHAR2 DEFAULT NULL)
    IS
    CURSOR lcur_requests (pv_sort_code IN VARCHAR2)
    IS SELECT column1, column2, column3 FROM table1 WHERE column1 = item_id ORDER BY pv_sort_code ASC;
    BEGIN
    OPEN lcur_requests (pv_sort_code);
    LOOP
    FETCH lcur_requests INTO lv_value1, lv_value2, lv_value 3;
    EXIT WHEN lcur_requests%NOTFOUND;
    END LOOP;
    END my_procedure;
    When the above procedure gets called, it is aware of the pv_sort_code, which can equal any of the following:
    pv_sort_code = column1, column2 -or- column3
    Any ideas as to how I can accomplish the dynamic order by in the cursor?
    Thanks ahead of time.

    Here is a sample example of doing it using Dynamic SQL + Collections:
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bit Production
    With the Partitioning, OLAP and Data Mining options
    SQL> set serveroutput on
    SQL> select * from my_tab;
            C1         C2
             1          5
             2          4
             3          3
             4          2
             5          1
    SQL> declare
      2      sort_order1 varchar2(100) := 'c1,c2';
      3      sort_order2 varchar2(100) := 'c1 desc,c2';
      4 
      5      type my_tab_rtype is table of my_tab%rowtype index by binary_integer;
      6      my_tab_rows my_tab_rtype;
      7 
      8      str1 varchar2(32000) := 'select * from my_tab order by '||sort_order1 ;
      9      str2 varchar2(32000) := 'select * from my_tab order by '||sort_order2 ;
    10  begin
    11      execute immediate str1 bulk collect into my_tab_rows;
    12          dbms_output.put_line('Sort Order :: ' || sort_order1);
    13          dbms_output.put_line('c1 c2');
    14          dbms_output.put_line('-----');
    15      for i in my_tab_rows.first..my_tab_rows.last loop
    16          dbms_output.put_line(my_tab_rows(i).c1 || ' ' || my_tab_rows(i).c2);
    17      end loop;
    18     
    19      dbms_output.put_line(chr(10));
    20     
    21      execute immediate str2 bulk collect into my_tab_rows;
    22          dbms_output.put_line('Sort Order :: ' || sort_order2);
    23          dbms_output.put_line('c1 c2');
    24          dbms_output.put_line('-----');
    25      for i in my_tab_rows.first..my_tab_rows.last loop
    26          dbms_output.put_line(my_tab_rows(i).c1 || ' ' || my_tab_rows(i).c2);
    27      end loop;
    28  end; 
    29  /
    Sort Order :: c1,c2
    c1 c2
    1 5
    2 4
    3 3
    4 2
    5 1
    Sort Order :: c1 desc,c2
    c1 c2
    5 1
    4 2
    3 3
    2 4
    1 5
    PL/SQL procedure successfully completed.
    SQL>

  • How to pass a locale object into another function?

    Greetings,
    i like to pass a locale object into another function. These are my code below
    import java.util.*;
    public class Locales{
         public static void main(String[] args){
              Locale locale= new Locale("EN", "US");
              convert(locale);
    public void convert(Locale convert)
         String language = convert.getDisplayLanguage();
         System.out.println(language);          
    }I got this error:
    Locales.java:6: non-static method convert(java.util.Locale) cannot be referenced from a static content
                    convert(locale);
                    ^How do i correct it?
    Thanks

    Did you bother to do a search?
    Did you bother to read any of the material that the search would have linked you to?
    If you had then you would be able to understand where you are going wrong and how to fix it yourself. Instead of being spoonfed by us.

  • How to split a delimited string into an array...

    I have a delimited string coming in to a stored procedure (SP) for vb.net that needs to be parsed/converted into multi-dimensional arrays. The reason I am using delimited string because I do not know how to pass arrays to oracle SP from vb.net using ODP or MPO (Microsoft's Provider for Oracle).
    My delimited string looks something like this: "level1_1|level2_1:level3_1;level3_2|level2_2:level3_1;level3_2~Level1_2|level2_2:level3_1"
    So, its going to be 3d array. I would greatly appreciate if anyone could help me solving this puzzle. Any examples would be a great help.
    Thanks for everything in advance,
    Vincent

    Hi Andrew,
    I appreciate your response. Currently I use "Microsoft provider for Oracle" to connect to Oracle Database because when I started with my application there wasn't ODP (Oracle Data Provider for .Net) available. So, I used Microsoft provider and still using it.
    I know how to use arrays in .Net but the problem is I can not find the Oracle Type to pass the array to Oralce Stored Procedure using this provider.
    It would be very helpful if someone shows me the syntax for both to receive from oracle and transport to Oracle. I haven't tried using ODP yet. May be now its the time to see how it works.
    And of course, your link was very helpful but I am already doing that (which is very slow for multi-dimentional array). So, I thought there might be a built in function in oracle which does that. Because most of the programming languages does have built in function for this conversion. for example: Split() in vb, java, javascript etc.
    Anyway, if anyone finds any clues as to how to pass milti-dimentional arrays from .Net (microsoft) to oracle stored procedure please, please let me know how to do that.
    -Vincent

  • 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 do I convert a string into a decimal

    I've been tryin to convert a string into decimal but I can't get it to work at all. I keep getting an exception.
    I've tried all of these:
    double myDouble = Double.valueOf(string).doubleValue();
    int myint = Interger.parseInt(string);
    float myfloat = Float.parseFloat(string);
    I can't get anything to work.
    That string i'm reading in is an array containing values with decimals. ex: -45.09348
    All the above work fine if there is no decimal, but fails when it comes to one.
    How do I go about doing this?
    Thanks!

    This works for me:String s = "-45.6789";
    double d = Double.parseDouble(s);
    System.out.println(d);Mark

  • How to get an xml string into a Document w/o escaping mark-up characters?

    Hi,
    I am using one of the latest xerces using Java. I am pretty sure I am using xerces-2.
    I have an existing Document and I am trying to add more content to it. The new content itself is xml string. I am trying to insert this xml string into the document using document.createTextNode. I am able to insert, but somewhere it is escaping the mark-up characters (<,>,etc). When I convert the document into String, I can see, for example, <userData> instead of <userData>.
    There is an alternative option to accomplish this by creating a new document with this xml string, get the root element, import this element into my document. Execution time for this procedure is very high - means, this is very bad in terms of time-wise performance.
    Can any help on how to accomplish this (bringing an xml string into a document without escaping mark-up characters) in time-efficient way.

    So you want to treat the contents of the string as XML rather than as text? Then you have to parse it.
    Or if your reason for asking is just that you don't like the look of escaped text, then use a CDATA section to contain the text.

  • How to pass concurrent request_id dynamically into workflow Business event subscription.

    Hi All,
    I created a workflow to send notification to user with the details in the message body of the workflow.
    Attached the same workflow to the subscription created under the seeded Business event 'oracle.apps.fnd.concurrent.request.completed'.
    Enabled the Business event for the concurrent program 'XXTEST' for 'request completed.'
    Workflow flow is:  Event>FUNCTION>Notification>END.
    In my workflow there are 4 attributes, 1 attribute is input (request id) for the function(procedure) attached in the workflow, based on that 1 input attribute (request id) the rest of 3 attributes are derived.
    Presently I have given constant value for the Attribute (request id) under its properties. I need to pass it dynamically as soon as the conc request is submitted.
    As I said its working perfectly, i.e., user (EG_AFZAL) receives notification after conc request is completed.
    Kindly suggest how to pass request id in the workflow.
    Regards,
    Afzal.

    Hi SamK,
    I applied as u suggested above in the procedure, but it is giving compilation errors.
    Below is my procedure which is attached to function in the workflow.
    CREATE OR REPLACE PROCEDURE APPS.XXWF_EMP_DETAILS
    ( ITEM_TYPE IN VARCHAR2,
      ITEM_KEY IN VARCHAR2,
      ACT_ID IN NUMBER,
      FUNC_MODE IN VARCHAR2,
      RESULT_OUT OUT VARCHAR2)
      AS
      V_REQUEST_ID NUMBER;
      V_USER_NAME VARCHAR2(240);
      V_PAYROLL_NAME VARCHAR2(40);
      V_CREATION_DATE DATE;
       BEGIN
      IF FUNC_MODE = 'RUN' THEN
        --  V_REQUEST_ID := getvalueforparameter('REQUEST_ID') ;
      SELECT REQUEST_ID INTO V_REQUEST_ID
    FROM PAY_PAYROLL_ACTIONS
    WHERE CREATION_DATE IN (SELECT MAX(CREATION_DATE) FROM PAY_PAYROLL_ACTIONS);
    select pap.payroll_name, fu.user_name, paa.creation_date
    INTO V_PAYROLL_NAME, V_USER_NAME,V_CREATION_DATE
      from
    pay_payroll_actions paa,
    pay_all_payrolls_f pap,
    fnd_user fu
    WHERE PAA.REQUEST_ID =V_PERSON_ID-- 44345723
    and paa.payroll_id = pap.payroll_id
    and fu.user_id = paa.created_by;
      --ASSIGNING VALUES TO THE ATTRIBUTES IN THE WORKLOW
      WF_ENGINE.SETITEMATTRTEXT(ITEM_TYPE,ITEM_KEY,'EMP_NUMBER',  V_PAYROLL_NAME);
      WF_ENGINE.SETITEMATTRTEXT(ITEM_TYPE,ITEM_KEY,'FULL_NAME', V_USER_NAME);
      WF_ENGINE.SETITEMATTRDATE(ITEM_TYPE,ITEM_KEY,'HIRE_DATE',V_CREATION_DATE);
      END IF;
        RESULT_OUT := 'COMPLETE';
      END;
    Kindly suggest.
    Regards,
    Afzal.

Maybe you are looking for