Can't display  xml sql function output in concuurent progarm in oracle apps

I am able to get the xml output for this query in TOAD.
but when i register this as sql*plus concurrent program,and run it and see output file , it has 0 bytes in it.
Can anyone did this befor?
Otherwise can any one suggest how to write this content to a file using UTIL_FILE ?
SELECT
XMLElement(
"PoList",
XMLAttributes(
'http://www.manh.com/ILSNET/Interface' as "xmlns" ),
XMLAgg(XMLElement(
"PurchaseOrder",
XMLForest(PURCHASEORDERID as "PurchaseOrderId"),
XMLElement("Vendor",XMLForest(
shipfrom as "ShipFrom"
XMLElement( "ShipFromAddress", address1
(SELECT XMLElement("Details",
XMLAgg(XMLElement(
"PurchaseOrderDetail",
XMLForest(
LineNumber as "LineNum",
item as "Item"
FROM cpo_wms_podl_lines pl
WHERE PURCHASEORDERID=ph.PURCHASEORDERID)))).getClobVal() into result
FROM cpo_wms_podl_HEADERS ph
where rownum<10 ;

Which database version are you using (all numbers please)

Similar Messages

  • Conditional display: PL/SQL Function Body Returning a Boolean

    Hi,
    can anyone give me an example how to create a PL/SQL Function Body Returning a Boolean in the Conditional Display Section of a Region?
    I have two Items on the Page and I want the region only be displayed when the two Items are not null....
    Thanks,
    tim

    Also, I have seen some "null"-values of Selectlists being stored as '%null%' instead..
    :P1_ITEM1 IS NOT NULL AND UPPER(:P1_ITEM1) != '%NULL%' AND :P1_ITEM2......
    ..might be helpful?
    Cheers,
    Vidar

  • Can't display MS SQL datetime value in SQL Developer 1.5.1

    Hi All,
    I try to select the datetime value from MS SQL Server and the SQL Developer display strange value like this:
    oracle.sql.TIMESTAMP@f37160
    The problem does not exists in the previous version. And any body can help to solve it?
    Thanks.

    ISSUE CLARIFICATION
    ====================
    Attempting to view records in a table from a MS SQL Server 2005 schema. All fields are ok, except
    the datetime fields.
    Getting Oracle.sql.date@E4F4012
    This worked (actually still works) with SQL Developer 1.2.1. In fact, I see both on my screen and
    1.2.1 views the fields fine, 1.5.4 does not.
    ISSUE VERIFICATION
    ===================
    Verified the issue by the screen shots
    DATA COLLECTED
    ===============
    SCREEN SHOTS
    SR6930954.994_SQLDeveloper.ppt
    CAUSE DETERMINATION
    ====================
    Missing option in SQL Server 2005 default datatype mapping rules.
    CAUSE JUSTIFICATION
    ====================
    Note 458294.1
    Bug 6360558 / Bug 6378114
    PROPOSED SOLUTION(S)
    ======================
    use the workaround provided in Note: 458294.1
    PROPOSED SOLUTION JUSTIFICATION(S)
    ====================================
    Note 458294.1
    Bug 6360558 / Bug 6378114
    SOLUTION / ACTION PLAN
    =======================
    You can use the following workaround if you want SQL Server 2005 DATETIME datatype map to Oracle DATE:
    - On the Captured Model, select 'Set Data Mapping'
    - Click on Apply in the 'Set Data Map' Window, this will create a record in the Repository
    - Open a connection with the Repository database
    - Click on Tables
    - Click on table MIGR_DATATYPE_TRANSFORM_RULE
    - Click on the "Data" Tab
    - Sort on column "SOURCE_DATA_TYPE_NAME"
    - Look for "DATETIME"
    - Change the value of column "TARGET_DATA_TYPE_NAME" from TIMESTAMP to DATE
    - Change the value of column "TARGET_SCALE" from 6 to (null)
    - Commit the change.
    Remark: This workaround is only suitable if the repository contains only 1 captured model, otherwise we need to identify the proper MAP_ID.
    KNOWLEDGE CONTENT
    =================
    Platform / Port Specific? = NO
    Knowledge content not created because the following note already addresses this issue: Note.458294.1
    This problem has been identified as a bug. And it has been fixed in Version 2.0.0 (Future Release)
    For available workaround refer to the above tags and NOTE: 458294.1
    Regards,
    Srikanth
    Oracle Support Services.
    Currently Support is not having any information of the release date for sql developer V2.0.0
    Regards,
    Srikanth

  • How can I order PL/SQL functions in "Called" a "Caller" order in function script file

    Does anybody know how to create PL/SQL function script file
    in "called" and "caller" (parent/child) order.
    Thanks
    Soheil

    Does anybody know how to create PL/SQL function script file
    in "called" and "caller" (parent/child) order.
    Thanks
    Soheil

  • Integration of calender functionality in the Custome form in Oracle apps.

    Hi,
    Thanks for all the support.
    I required one more help about integrating the calender functionality in the costume form of r12 Oracle Apps.
    Can Any body just give me the steps for the integrating the calender functionality. in R12 Oracle apps form.
    I have done the steps as like the 11i but its not working. Its urgent and I hv very less time to buid this form.
    Thanks
    Nihar

    Please see "Oracle Applications Developer's Guide", Page 9-18
    Oracle Applications Developer's Guide
    http://download.oracle.com/docs/cd/B53825_03/current/acrobat/121devg.pdf
    Thanks,
    Hussein

  • Can you use command lines to copy files in UNIX to Oracle Apps

    Hi! We have installed the oracle apps 11.5.0 to a unix operating system. And we use ftps to upload the rtf and xml files to the unix server. Is there any command lines we can use to copy all the rft and xml files in the server to the real location of where the report files stored without going through the XML Publisher font end through the internet explorer? Thanks for your help!

    Hi,
    From what you have mentioned, I believe you are writing custom xml pub report
    1) Storing all your template and sample xml data file on Unix box by FTPing it. This step is not required as XML publisher picks template from XDO tables (where it is stored in CLOB), unless you are explicitly Coding to use templates from a fixed location like <CUST_TOP>/<xml_templates>
    2) As part of XML setup, you need to define the template and datasource using the front end. This causes the Template and XML data (sample) to be stored in XDO tables (as clobs). This step is basically required and unavaoidable.This step can be automated using FNDLOAD tool (not sure).
    Hope it helps somewhat.
    Neeraj

  • Oracle Functional Testing for Web Applications for Oracle Apps

    I am trying to test Oracle Application 11i and R12 using Oracle Functional Testing for Web Applications.
    In 11i:
    If i open any forms then then the Application is getting crashed whereas it's recording the html events.
    In R12:
    If i open any forms then the Form is getting opened but it's not recording the events happening on the forms
    whereas it's recording the html events.
    Please let me know whether Oracle Functional Testing for Web Applications supports can be used to test Oracle Apps 11i/R12 including the Forms.
    Regards,
    Arun

    Hi,
    AFAIK, there is no official document which states that "Oracle Functional Testing for Web Applications" is certified with Oracle E-Business Suite 11i/R12. I assume it should work with Forms 10g but not with Forms 6i, so it should work (does not mean it is certified) with R12.
    I would suggest you log a SR and confirm this with Oracle Support.
    Regards,
    Hussein

  • Can window and aggregate SQL functions used in Pro*C embedded SQL?

    It appears that the window functions such as dense_rank() over(partition by ... order by ...) are not available in Pro*C embedded SQL. Can somebody please confirm that that is really the case?
    Thanks
    Rawender Guron

    Please refer to this thread: "Is this forum also used for Pro*'C Questions? "
    Is this forum also used for Pro*'C Questions?

  • Display PL/SQL funtion output in HTML Region dynamically

    I have a form/report with just 2 items (one is hidden). When I click on the displayed field, I would like the output of a function/procedure (with the form/report field as argument) to display in a region on the same form. I already have a function with varchar2 as return value and also a procedure that prints out html output through htp.p package.
    But couldn't figure out how to connect the form and the region and be in sync.
    I have a chemical structure data stored as CLOB in the DB with an ID. Basically, clicking on the ID should pass the CLOB to the procedure that outputs the <embed and so on tags for a plugin to display my chemical structure.
    Any help/guidance is appreciated.

    Hi Carl,
    Thanks for the post. I tried the static value and it works (structure displays). My problem is for it to pickup on the value of my field.
    I could give you my login credentials on htmldb but I am not sure if that would help as you would need the plugin installed on your browser (frre version may be available at www.mdl.com and search for "chime").
    I have something along these lines in procedure.
    htp.p('Hello World, I am ' || :APP_USER);
    htp.p('<table border=1 cellpadding=1 cellspacing=0 width=550><tr><td align=middle valign=top><font face=arial size=2>');
    htp.p('<input type=hidden name="queryrxn" value = "'|| :MOLCHIME ||'">');
    htp.p('<embed type=chemical/x-mdl-molfile width=300 height=100 queryformbox="document.query.queryrxn" structure='''||:MOLCHIME||'''></td></font>');
    htp.p('</tr></table>');
    Thanks for any input.
    Sridhar

  • Can window and aggregate SQL functions be used in Pro*C embedded SQL?

    It appears that window functions such as dense_rank() over(partition by ... order by ...) can not be used in Pro*C embedded SQL? Can somebody confirm that that is really the case?
    Thanks
    Rawender Guron

    Please refer to this thread: "Is this forum also used for Pro*'C Questions? "
    Is this forum also used for Pro*'C Questions?

  • XML SQL functions causing internal errors in PL/SQL

    Still busy searching through Metalink, but have yet to find anything useful. Maybe someone can point me towards a URL or a doc ref that has some hints on how to solve the following:
    Oracle: 10.2.0.1.0 46bit
    O/S: HP-UX 11
    SQL> var l varchar2(4000)
    SQL>
    SQL>
    SQL> select XMLForest( 123 as "ID" ) as L from dual;
    L
    <ID>123</ID>
    SQL> begin
      2     select XMLForest( 123 as "ID" ) into :l from dual;
      3  end;
      4  /
            select XMLForest( 123 as "ID" ) into :l from dual;
    ERROR at line 2:
    ORA-06550: line 2, column 2:
    PLS-00801: internal error [*** ASSERT at file pdw4.c, line  793;
    Cannot coerce between type 43 and type 30; anon_c000000044b37bb0__AB[2, 2]]
    SQL> begin
      2     EXECUTE IMMEDIATE 'select XMLForest( 123 as "ID" ) from dual' into :l;
      3* end;
    SQL> /
    PL/SQL procedure successfully completed.
    SQL> print l
    L
    <ID>123</ID>

    Ah.. found the problem. The function returns a type which result is implicitly type casted to a varchar2 it seems when running a SELECT on it via the SQL engine.
    PL/SQL sees it as a type (which it is) and expects you to put it into a var of the same type. It does not allow/perform the implicit conversion to varchar2.
    But then SQL is not Turing Complete so I guess we'll have to let the SQL Engine slide on doing these implicit conversions... :-)

  • Using VB application, how can one see pl/sql dbms_output output?

    Hi guys,
    Someone wrote a pl/sql procedure, using dbms_output to debug, now we promoted them to PROD, these dbms_output statements are still there in the code.
    Q1. is there any performance issue, having these statements still in code, while they are there in PROD.
    Q2. these procedures have been called by VB application in PROD, now what we are looking for, is there any way to capture those errors which may be raised, there in PROD, if some weird work done by this VB application, what we
    are looking for is to see those errors or whatever be the output of those dbms_output.
    Do inform, is there any possibility to see those output using this VB application, coming out by dbms_output.
    Please ask for clarification, if need be.
    Thanks.

    user8604530 wrote:
    Q1. is there any performance issue, having these statements still in code, while they are there in PROD.
    1) I don't think there will be a big performance issue, i.e. it won't consume noticeable cpu resources.
    2) It might cause more memory consumption of your database sesssions, as all output is temporarily buffered in memory at the database server side.
    1 + 2 heavily depend on how many times the dbms_output.put(_line) procedures are actually called.
    3) It might cause failure of your application, as at some point in time the buffer for storing the output temporarily will fill up. And from that point onwards, all put(_line) calls will result in an error.
    Q2. these procedures have been called by VB application in PROD, now what we are looking for, is there any way to capture those errors which may be raised, there in PROD, if some weird work done by this VB application, what we
    are looking for is to see those errors or whatever be the output of those dbms_output.
    Do inform, is there any possibility to see those output using this VB application, coming out by dbms_output.
    No. Not without you doing some effort at the VB side. dbms_output data is buffered at the server side, and you will have to retrieve its contents yourself. SQLplus (and dome other adhoc sql tooling) will do this automatically for you. But I bet your VB application doesn't. Read up on the dbms_output.get(_lines) procedures on how to retrieve the contents of the buffered output.
    Toon

  • How can I display the last items of a region from other Oracle Portal page?

    I want to display de last five items (f.e.) included in a region (with attributes created) from other page. I've tried using custom search, but it also shows the attribute names, and I want show the attribute values (I don´t know how can I format these attributes).
    Thanks a lot.

    create a stored procedure (f.e. in schema myschema create a stored proc named renderAsHTML)
    code for the procedure :
    PROCEDURE renderAsHTML(p_itemId varchar2,p_pageId varchar2,p_siteId varchar2) IS
        l_displayName  portal.wwsbr_all_items.display_name%type;
        l_name         portal.wwsbr_all_items.name%type;
        l_publishDate  varchar2(10);
        l_url varchar2(250);
    BEGIN
         -- Looking for item datas
         select display_name, name,   to_char(publish_date,'dd/mm/yyyy')
         into l_displayName,l_name, l_publishDate
         from portal.wwsbr_all_items
         where id =p_itemId and language=portal.wwctx_api.get_nls_language;
         -- getting the URL og the item
         l_url := portal.wwpob_page_util.get_page_url(p_pageId, p_siteId);
         -- HTML rendering
    htp.p('<.a href="'||l_url ||'/'|| l_name ||'">' ||  l_displayName ||'</.a><.br/>');
    htp.p('Published on ' || l_publishDate ');
    EXCEPTION
        WHEN others THEN
               htp.p('<.div>Somme error occured , code is ' || SQLCODE || '.</.div>');
    END renderAsHTML;
    please notice that I've added a dot in HTML tags to avoid this forum to interpret them
    note : make sure that you granted "execute" for the public user on teh procedure you've just created.
    go to item properties (navigator>shared objects>item types>modify the one you want
    go to tab3 (procedures)
    set the following options :
    type : PL/SQL
    call proc : myschema.renderAsHTML
    link text : render as HTML
    icon : keep blank
    select the "display proc results with the item" option
    pass the following parameters :
    attribute1 : item ID as p_itemId
    attribute1 : page ID as p_pageId
    attribute1 : pagegroup as p_siteId
    Now, in your custom search portlet, go to results rendering, remove all attributes and add the "associated function" attribute.
    Now, all the HTML generated by the stored proc will be rendered instead of the item.

  • SQL Query to get Account Balance in Oracle Apps

    Hi All,
    I have to use GL Account as a parameter in one of my concurrent programs but before that i need to ensure that the account parameter has no money in it.
    If anyone can help me with a SQL query to find the same, it would be a great help.
    Regards,
    Shruti

    Hi;
    Please follow Subject: Troubleshooting various Issues in Translation of Oracle General Ledger Doc ID: 296379.1 and also etrm site(etrm.oracle.com) for find out more details.
    Regards
    Helios

  • Can we call sql function  in java

    as i know i can call stored procedures ,but can i call pl/sql functions.

    Using JDBC you can execute any valid sql statement.
    For a pl/sql function you use a CallableStatement and the syntax:
    {?= call <procedure-name>[<arg1>,<arg2>, ...]}
    http://java.sun.com/j2se/1.5.0/docs/api/java/sql/CallableStatement.html

Maybe you are looking for

  • Time for a new Mac or just a new graphics card?

    My dual core Mac Pro is getting sluggish with Motion.  I was thinking of picking up a new iMac and loading it up with RAM but after reading a bit about the importance of graphics cards in Motion (Spencer's article is linked below) and the benefits of

  • New meeting in my BB Calendar not visible in Novell Groupwise

    Hello, I have a little problem with my BB 8900 Curve. When i want to create a new "meeting" in the calendar and check the "all the day" option, i can't see it in my Novell Groupwise client. It's registered as a "Note", but not as a "Meeting". Do you

  • What video adapter to use?

    On this forum I see reference to various connectors and adapters to use in hooking the MacBook Aluminum to an external monitor. When I purchased my new monitor, I also ordered a "Mini-DVI to DVI" adapter, thinking this would be the right one. WRONG.

  • Business Logic with EJB

    Hi all! I googled EJB: Enterprise Java Beans. A standard distributed component model. The encapsulation of business logic into business objects is the most recent focus of the information Technology industry. Objectified business logic. Server compon

  • Need Help with download error

    After 3.8 GB it says Unable to complete your purchase the product distribution file cannot be verified. it is either damaged or not signed. What should i do