How to fetch final PO approver?

hi
i am trying to fetch final PO approver from the database but i am not sure which basic tables to use. i am using following query but it gives me the list of approvers. how do i get the final approver:
SELECT distinct (he.FULL_NAME) "Approver Name",pall.APPROVER_ID
FROM po_requisition_lines_all prla
, po_requisition_headers_all prha
, po_distributions_all pda
, po_headers_all pha
, po_req_distributions_all prda
, po_approval_list_lines pall
, po_approval_list_headers palh
, per_people_f he
WHERE prla.REQUISITION_HEADER_ID =prha.REQUISITION_HEADER_ID
AND prla.REQUISITION_LINE_ID = prda.REQUISITION_LINE_ID
AND prda.distribution_id = pda.req_distribution_id (+)
AND pda.po_header_id = pha.po_header_id (+)
AND prha.REQUISITION_HEADER_ID = palh.document_id
AND pall.approval_list_header_id = palh.approval_list_header_id
AND he.PERSON_ID = pall.APPROVER_ID
can anyone help. thank you.

Under the assumption that final = maximum approval date you would need to add a filter condition on the maximum approval date, which in turn would mean you would have to query for it. Probably as a sub-query or inline view.
If this is an Oracle Application query you should have stated so as well as listed the version.
If you identify which table the approval is on someone may point out how to code the filter condition.
HTH -- Mark D Powell --

Similar Messages

  • How to fetch APPROVER NAME  and approval date dynamically for an user

    Hi all..
    How to fetch approver name and approval date dynamicall for an user in an email template..
    can any help me to sort out this pbm,i am new to IDM..
    Thanks in advance..

    Access policies get a static value.  You can't populate a field with an adapter.  If you must do this, leave the field blank, and put an adapter on the process form for your field that must be populated using code or logic.
    -Kevin

  • How to fetch post goods issue date and sales order creation date

    Hi All,
    How to find out the difference between SD Sales Order Item Creation Date and final Post goods issue Date. I would like to know how to fetch those dates and what is the relationship between the tables from which i will get the dates.
    Please let me know the solution .
    Thanks in advance.

    Hi,
    Sales order creation date is when u raise a sales order in favor of the customer using VA01.......using ATP logic system purposes the material availability date....
    after saving ur sales order...when u raise the Delivery using VL01n  w.r.t to OR...than u have to perform picking ....In the picking Tab...specify the amount to be picked than press Post Good Issue....means the goods left the company premises ..
    You can the fetch the values using tables-  Use T code   SE12  or SE16
    Vbak-----order header
    Vbap-----order item
    Vbek-----order schedule line
    Likp-----Delivery header
    Lips----Delivery item

  • How to fetch a package's commit messages as text?

    I use a set of my own scripts for building everything from abs/aur from source.  I track dependencies, including makedepends, package groups, package splits, etc by scanning PKGBULDs to extract the info into my database.  My build script attempts to automatically show me the README and configuration options via "configure --help" or "cmake -LH", and after the package is built it shows me the namcap output so that I can approve the build and go on or change the PKGBUILD to correct errors.
    I would really like to have my build script also show me the changelog, as a text file, for the package by fetching the commit messages from the Arch web interface, such as http://projects.archlinux.org/svntogit/ … &showmsg=1, but I don't know how to fetch that dynamic page as a text file. 
    If it were a simple static page like the main page for archlinux.org I could get it with lynx -dump or html2text, but these don't give me anything useful for the package's "View Changes" pages.
    I hope that seems like a simple problem to someone.  Please give me a clue how to fetch dynamic pages like that as text...
    Last edited by sitquietly (2012-02-03 20:56:44)

    karol wrote:Have you seen https://bbs.archlinux.org/viewtopic.php?id=134591 ?
    Yes, of course, and it may be helpful if I have to dig into it's code, but by itself it gives markup (colorized text intended for a terminal emulator) rather than plain text.  If I dump its output into vim I still have what looks like trash.  I could filter out the markup.  Argh.
    Any other help out there??

  • How to fetch file from app. server without complete filename?

    Hi,
    In my report I have to read data from txt file on application server.
    My file name on App. server conatain system id and date and time stam.
    my file path :- /User/IDD/S10009112007101525
    here,'User'  is dirctory
            'IDD' is folder in directory
            'S100' is system id
             '09112007' is date
             '101525'  is time in hour,miniute,second format.
    From my program I can only pass directory , Folder name,System Id,Date only. I don't have time value in my program.
    So please tell me how to fetch files without having time stamp value from app. server.
    Plz send me exact code.It's urgent.
    Message was edited by:
            Manisha Kadam
    Title was edited by:
            Alvaro Tejada Galindo

    Do you want to return the file to the user on click of button or something?
    Then, use web_show_document with http link which you are speaking about.
    Else download the file to client using Webutil.

  • How to fetch year till date value for earning for current ,last and year

    hi,
    how to fetch year till date value for earning for current ,last and year before that from payroll result
    plz reply soon,
    pratyush

    Dear Pratyush,
    Pick this from CRT.
    Use LDB PNPCE & Fire event GET PAYROLL &
    then you can pick from CRT.
    Hope this helps.
    Kindly reward in case useful.
    Regards & Thanks,
    Darshan Mulmule

  • How to fetch accounting document number from known material document number

    Hi,
    Using MIGO transaction, by giving mblnr(material document number) as input, I get accounting document number by clicking FI document.I have to add this accounting document number in my report for corresponding known mblnr(material document number) values.
    My question is how to fetch the accounting document number present in MIGO to add in my report program.
    I used the xblnr(Reference Document Number) which is present both in mkpf and bkpf tables to fetch values.
    I extracted xblnr values with known mblnr values from mkpf (Header: Material Document table).
    and then extracted belnr(accounting document number) from bkpf (Accounting Document Header table) by using xblnr values.
    But the query is running for a long time.
    Is there any other method  to extract the values in a simpler way.
    Kindly advise.
    Thanks and Regards,
    Sanjeev

    I had the values of xblnr and some other fields such as mblnr, budat etc in wi_item table.
    I created a new internal table i_xblnr and got down those values.
    And then created a new internal table i_belnr and tried to get values of belnr in it.
    The code I wrote is given below:
    IF not wi_item[] is initial.
    loop at wi_item.
       at new xblnr.
        ws_xblnr-xblnr = wi_item-xblnr.
         append ws_xblnr to i_xblnr.
       endat.
    endloop.
      select belnr xblnr from bkpf into table i_belnr for all entries in i_xblnr where xblnr = i_xblnr-xblnr.
    ENDIF.
    Kindly look after it.Thank you.
    Regards,
    Sanjeev

  • How to fetch NO DATA FOUND exception in Ref Cursor.

    In my procedure ref cursor is out parameter with returns dataset. in my proceudre
    its like...
    OPEN pPymtCur FOR
    select.....
    when I call this procedure from report to get dataset it causes NO DATA FOUND exception.
    How to fetch this exception in my oracle procedure so I can get some other data.
    Any Idea to do this?
    Edited by: Meghna on 17-Jun-2009 22:28

    Mass25 wrote:
    Correct me if I am wrong.
    So if I do something as follows in my stored proc, I do not have to check for NO_DATA_FOUND?
    OPEN my_CuRSR FOR
          SELECT DISTINCT blah blah blahmy_cursr is what I am returning as OUT param in my SP.Correct. At the point you open the cursor, oracle has not attempted any 'fetch' against the data so it won't know if there is any data or no data. that only occurs when a fetch is attempted.
    Take a read of this:
    [PL/SQL 101 : Understanding Ref Cursors|http://forums.oracle.com/forums/thread.jspa?threadID=886365&tstart=0]

  • Opening Stock+Purchase-Closing stok ,how to fetch in P&L Statement

    HI! All,
    In Schedule 15 in India showing the opening Stock+Purchases-Closing Stock .In FSV or in report painter how to fetch these figure  to prepair in the P&L Statement.
    Thanks & Regards
    Archana

    Hi,
    You need to use FSI3. The opening balance will be the last month's as off. Create a formula for the Purchases where it will be the stock balance as of the current period less the balance in previous period.

  • How to fetch data from different sources into one source (like into Ztable)

    hi friends,
    As per our client requirements they want to develope an Inventory and an Ontime delivery report in BO on top of Oracle database.
    Situation is some thing like they have ECC 6.0.and they want to collect all inventory and ontime delivery data at one place.According to me that could be one Ztable in which we can gather all data.Apart from that they are going to use Data Integrator in which they can directly fetch the data from R/3 system(They dont want to have BI system) and put all data in Oracle DB.On top of ORacle BO person can develop BO reports.
    My question is how to fetch all data at one place and what are the tables going to be use.
    kindly help me out as its very important project.
    Thanks
    Abhishek

    The following is my standard reply to those who need to get old data from a backup in one account and add it to another account.  The method described here may be applied to your case.  It would be a bit of a long process, though.
    When connected to the account you want to GET data from, Go to Settings>iCloud and turn all data that is syncing with iCloud (contacts, calendars, etc.) to Off. 
    When prompted choose to keep the data on the iPhone. 
    After everything is turned off, scroll to the bottom and tap Delete Account.  Next, set up a new iCloud account using a different Apple ID and turn iCloud data syncing for contacts, etc. back to On.  When prompted, choose Merge.  This will upload the data to this new account.
    Note that this only affects the "Apple data" like contacts, calendars, reminders, etc.  Many third party apps also use iCloud to store data files there.  These files may be lost in the process, unless the apps also keep the data locally on the device.
    NOTE:  Photos in the photo stream (if you use it) will not transfer to the new account.  It is advised that you save the photos to a computer before performing the account switch. 

  • How to minimize Final Cut pro with one click?

    I know you can minimize windows (canvas, timeline, etc) by pressing Command+M 4 times but how to minimize Final Cut pro with one click?

    Hold down the Option key and click the Minimize button on any window, all windows in the app will minimize.
    Don't know what or if the reverse of this is - so although it's a one click minimize all windows, I believe you have to re-enlarge them one at a time.
    MtD

  • HOW TO CONFIGURE MANAGER or APPROVER USER IN ACCESS REQUEST MANAGEMENT TO APPROVE OR REJECT REQUEST

    hi sap gurus,
    i configured grc 10 system successfully. I created one user: GR_AR_APP001 and assign following roles:
    SAP_GRAC_ACCESS_APPROVER
    SAP_GRAC_ACCESS_REQUEST_ADMIN
    SAP_GRC_FN_BASE
    SAP_GRC_FN_NUSINESS_USER
    and I maintained GR_AR_APP001 in access control owners as "POINT OF CONTACT", "SECURITY LEAD" and "WORKFLOW ADMINISTRATOR"
    but when i am creating access request for new user and defining MANAGER under user details tab as GR_AR_APP001.
    the user GR_AR_APP001 is not receiving any request for APPROVE or REJECT in his WORK INBOX.
    can u please guide me how to configure APPROVER or MANAGER to approve or reject request.
    I will be very much thankful if you guide me successfully.

    Hi Colleen,
    thanks a lot for your time.
    PIC1: I created one user: GR_AR_APP001
    and assigned all the GRC ROLES.
    PIC2: I assigned owner type to GR_AR_APP001 user : POINT OF CONTACT, SECURITY LEAD and WORKFLOW ADMINISTRATOR in NWBC ACCESS CONTROL OWNERS
    PIC3: I created one EUP 980 (copied from default EUP)
    PIC4: I maintained default manager as GR_AR_APP001 user in 980 EUP
    PIC5: I selected SAP_GRAC_ACCESS_REQUEST process id
    PIC6: I created one agent id as ZGRAC_MANAGER11 in which I added approver user id: GR_AR_APP001
    PIC7: I saved agent id
    PIC8: I added agent id as ZGRAC_MANAGER11 in stage5 in manager stage.
    PIC9: I saved
    PIC10: I maintained EUP 980 (in which I configured manager as GR_AR_APP001 user) in stage 5 task settings
    PIC11: Maintain Route Mapping, I clicked on next
    PIC12 and PIC13: I saved and activated.
    After this process I created one request for new account and selected the manager as GR_AR_APP001 and one request is created with request no 9000000030.
    now I logged into system by user GR_AR_APP001 and checked, there is no request under his work inbox.
    please guide me at least one procedure, how to receive request in approver work inbox so that I can learn other procedures to configure approver as per our organization requirement.
    thanks for your support Colleen.

  • How to fetch some certain records at a time

    Hi everyone,
    I dont know how to fetch some records at a time,
    for some reason,there is not enouht memory.so I cant
    fethch all the records at a time.
    example, every time I only want to fetch 10
    records. Does anyone know that?
    thanks
    Krussi

    I think you may be getting setFetchSize(int) and setMaxRows(int) confused. I may have added to the confusion with my breaking out of the loop comment.
    setFetchSize(int) gives the driver a hint as to how many rows it should store in memory at a time internally, ie. within the driver. It has no real effect on how you write your program at all. Its only purpose is to limit memory usage by the driver. To limit the rows returned, use setMaxRows.
    For example, assume a result set has 20 rows and you use:
    rs.setFetchSize(5);
    while (rs.next()) {
       System.out.println("Rows: " + (++count));
    }  You still get a count from 1 to 20. However, internally the driver is only holding in memory 5 records at a time, after the 5 returned it will discard those and get the next 5. So instead of holding 20 rows, its only holding 5 at a time. If you change rs.setFetchSize(5) to rs.setMaxRows(5) you will only get a count from 1 to 5, the rest are silently discared and rs.next() returns false.
    Check your documentation to see if your driver supports the method. I believe many drivers don't. If not, I believe there is no way around multiple queries. Even if there is no rowid, as long as you order your queries you should be able to start again where you left off.
    Disclaimer: Both drivers I commonly use do not implement setFetchSize(int). Someone let me know if I've fudged something here.
    Good Luck

  • How to fetch Error message

    Hi folks,
    I am new to c/c++.
    And i am finding it difficult to figure it out ..............
    char* APIParser::parseDocument(const char *xmlInput) {
              XMLParser parser;
              const char *doc;
              uword ecode;
              doc = xmlInput;
              if(doc == NULL)
    //Return XML output
                   return getDefaultXMLOutput(-1, 0, "XML input document is null");
              if (ecode = parser.xmlinit()) {
                   cout << "Failed to initialize XML parser, error " << ecode;
                   //return ecode;
                   return getDefaultXMLOutput(-1, 0, "Failed to initialize XML parser");
              if (ecode = parser.xmlparseBuffer((oratext *) doc, strlen(xmlInput), (oratext *) 0,
                   XML_FLAG_DISCARD_WHITESPACE)) {
                   cout << "Parse failed, error " << ecode << "\n";
                   //          return 3;
                   return getDefaultXMLOutput(-1, 0, "Parse failed");
              if (ecode = schema.initialize(&parser))     {
                   cout << "Failed, code " << ecode << "!\n";
                   //return 4;
                   return getDefaultXMLOutput(-1, 0, "Error in initialize Schema");
              root = parser.getDocumentElement();
              if (ecode = schema.validate(root, NULL )){
                   cout << "Validation failed, error " << ecode << "\n";
                   ub4* ub4;
                   unsigned char** path;
                   int i=0;
                   boolean value;
                   while((value = parser.xmlwhere(ub4, path, i++))){
                        cout<<ub4<<endl;
                        cout<<ub4<<path;
                   cout<<value;
                   schema.terminate();
                   //return 5;
                   return getDefaultXMLOutput(-1, 0, "Validation failed");
              return "";
    Where i am passing xmlInput which is a char*.
    Things work fine.
    I need to send back exact error message to client to debug the messages.
    How to fetch the messages, line number etc.
    By seing docs i wont be able to figure it out.
    Can any one send piece of code to fetch the error messages.

    If you access the FacesContext you find a method called
    getMessages()
    Return an Iterator over the FacesMessages that have been queued, whether or not they are associated with any specific client identifier.

  • How to fetch data from Mysql with SSL.

    I am using jdk1.5 and mysql 5.0.
    How to fetch data from Mysql with SSL
    I am using url = jdbc:mysql://localhost/database?useSSL=true&requireSSL=true.
    It shows error. how to fetch

    I have created certificate in mysql and checked in mysql.
    mysql>\s
    SSL: Cipher in use is DHE-RSA-AES256-SHA
    but through ssl how to fetch data in java.

Maybe you are looking for

  • Logical Database (PNPCE) , selection screen hide.

    Hi Gurus,          i have couple of questions related to logical database pnpce. 1.Since i know logical database has there own selection screen , my requirement is i want to add my custom fields to the selection screen other than what is provided is

  • Downloading files from DVD or hard drive cameras

    Is it possible to download files from hard drive or dvd cameras to be used in Premiere without using the capture function which needs to be done in real time?

  • Is it possible to video ichat with windows?

    Hi, I have a friend using a Windows XP pc and she would like to video conference with my Mac. Is it possible for me to connect and have a video conference with a Windows XP guest? What software (application) is needed? I am using iChat with my powerm

  • Help: Calendar entries disappear on Pearl 8100

    I have a BB Pearl 8100 and have the problem that calendar entries disappear from the device. Entries as recent as those from the previous week all of a sudden disappear. I have re-synchronized several times (I use Outlook 2003 for calendar and contac

  • Windows doesn't recognize my hd on ide2

    I have a Neo FIS2R K8T800 mobo and the Bios correctly recognizes the hd, which is an old 9Gb Ultra-ATA Seagate I have to copy data from to my regular hd's (which are both on ide3). When I go here : Control Panel -> System -> Device Manager -> Disk Dr