Handling No Data found in e-Text Outbound type template

Hi,
I am facing the following issue. I am new to BI Publisher / e-Text templates. Can someone help in getting the issue resolved?
My XML file looks like this when there is data:
<?xml version="1.0" encoding="UTF-8" ?>
- <XX_GIFTAID_CLAIM_REP_XMLP>
<p_start_date>2010/10/01 00:00:00</p_start_date>
<p_end_date>2010/10/31 00:00:00</p_end_date>
- <LIST_G_GIFT_AID>
- <G_GIFT_AID>
<C_SUPPORTER_NUMBER>18967929</C_SUPPORTER_NUMBER>
<C_SUPPORTER_NAME>Barnett</C_SUPPORTER_NAME>
<C_RECEIPT_DATE>2010-10-03T00:00:00.000+01:00</C_RECEIPT_DATE>
<C_APPLIED_AMOUNT>33.5</C_APPLIED_AMOUNT>
</G_GIFT_AID>
</LIST_G_GIFT_AID>
</XX_GIFTAID_CLAIM_REP_XMLP>
When there is no data:
<?xml version="1.0" encoding="UTF-8" ?>
- <XX_GIFTAID_CLAIM_REP_XMLP>
<p_start_date>2010/10/01 00:00:00</p_start_date>
<p_end_date>2010/10/31 00:00:00</p_end_date>
<LIST_G_GIFT_AID />
</XX_GIFTAID_CLAIM_REP_XMLP>
When there is no data request is completing with warning. When there is data, request completed successfully. I am using data template to generate the XML output. I think I need to handle no data found situation in rtf file. But I have no idea how to write. I tried the following, but it did not work:
IF NOT(//G_GIFT_AID) THEN
No data found
END IF;
<?if:not(//C_SUPPORTER_NUMBER) =0?>No Data Found<?end if?>
Any pointers in this regard are highly helpful as this is an critical issue to be delivered ASAP.
Thanks in Advance!!
Mukthi

Try this: <?if:count(/XX_GIFTAID_CLAIM_REP_XMLP/LIST_G_GIFT_AID/G_GIFT_AID/C_SUPPORTER_NUMBER) =0?>No Data Found<?end if?>
I tried it for both cases of your xml data snapshot provided and it works...
Thanks,
BIPuser

Similar Messages

  • No Data Found Error in Transaction Source Types Form

    Hi All,
    We are using 11.5.10.2 version of Oracle Apps.
    When i navigate to INV responsibility, Setup -> Transactions -> Source Types, upon the opening of the Transaction Source Types form, i get a series of "No Data Found" error pop up messages. I searched in metalink too but couldn't find any resolution for the same.
    Does anyone know as to how to resolve this issue? Is there any patch that needs to applied? Kindly help.
    Regards,
    Hemanth

    Hi Julie,
    On the "Process Row of..." process, make sure that it is unconditional and that the Delete opertion checkbox is ticked. Deletions from the main table should only be triggered by a DELETE request which should be issued by the "Delete" button.
    On the "Apply MRD" process, make sure that the condition is "Request is Contained within Expression 1" and Expression 1 is: APPLY_CHANGES_MRD,SAVE
    This process should be triggered by the "Delete Checked" button, which should have a URL target of:
    javascript:confirmDelete(htmldb_delete_message,'APPLY_CHANGES_MRD');This triggers the confirmation popup and submits the page with APPLY_CHANGES_MRD as the REQUEST value which should be picked up by the "Apply MRD" process only.
    Andy

  • Emailing data found in input text fields

    Hi,
    I have a simple form that users fill in various "input" text
    fields like "Name", "Email", etc... now all I want is when the
    click on the "send" button, it should automatically send an e-mail
    to "info@...".
    I got it to enter the proper recipient email address and
    subject but there's not content. What am I missing?
    Thanks,
    Phalconheart

    Thanks for the prompt reply.
    Just to clarify (programming is not my primary function...
    far from it)
    Yes, just opening the clients e-mail program and populating
    it with all the variable info he's selected is fine.
    so, in your code:
    url ="mailto:[email protected]?subject=Message
    Subject&body=First line of message.%0ASecond line." + "%0A" +
    "Third line.";
    1) what does the "%0A" do exactly?
    2) do I simply replace where you wrote "First Line of
    message" with the code "variables.item = itemChoice.text;"? and so
    on and so forth?
    Thanks,
    Pat

  • How does everyone handle sweep data from loops

    There's a type of test I've done a few times over the years and I'm researching what are some standard ways to handle the data in TestStand. The test type is sweeping multiple parameters in a nested loop. For example, sweep Vcc from 5.1V to 5.5V in .1V steps, at each voltage sweep Q DC Bias from 1.9 to 2.3 in steps of .2, and at each Q DC Bias sweep LO Drive Level from -5 to -20 dBm in steps of .5 dBm. For each input combination record IM3 Suppression. This example produces 310 data records.
    If I did all this inside a single code module I could pass it back to TestStand as four arrays, one for each input param and one for the data. Done. I'd still need to log it.
    What if I want to do the looping in TestStand? Here's how I could collect data.
    1. Record the three params and one data into the ResultList as single points with Numeric Limit steps and sort it out in some datalogger callback.
    2. Collect four arrays or a 2D array in Locals and then copy the arrays into the ResultList as four arrays (or 1 2D), not as scalars in #1 above. Log it in some datalogger callback.
    3. Collect four arrays or a 2D array in Locals and just use a code module in the client sequence to save the data.
    4. Any others?
    Thanks

    Hi dowNow,
    I can't immediately think of any significantly different alternatives to accomplish what you are wanting to do.  In the past, I have personally used the external code module to do the looping and measurements and then returned the data as a 2-D array.  You can then add this array to the ResultList.  This has typically given me the most efficient tests and the simplest overall setup.
    Additionally, I am not sure if you are planning to store the results in a Database, but if you are, you will need to keep in mind that logging a 2-D array to a Database works differently than a 1-D array.  I have included a link to one of our KnowledgeBase articles that details exactly how to store a 2-D array in a Database:  http://digital.ni.com/public.nsf/allkb/1307679F845B162286257160000510ED
    Thanks,
    Jonathan C
    Staff Application Engineering Specialist | CTD | CLA
    National Instruments

  • Oracle report , when no data found in query then ptint zero in text how

    hi ,
    i have use oracle report in one query if no data found then i have return O but no row select is there
    query is
    select sum(nvl(a.pitm_matl_cost,0)),
    decode(b.pm_assy_type,'B','B','Z')
    from pumpitems a, pumpmast b
    where a.pitm_proj_code like 'KAWASII' and
    a.pitm_pump_type = b.pm_pump_type and
    a.pitm_comp_type = b.pm_comp_type and
    a.pitm_sr_no = b.pm_sr_no and
    substr(a.pitm_matl_code,1,1) = 'X' and
    pitm_itm_cal = 'N'
    group by decode(b.pm_assy_type,'B','B','Z')
    order by decode(b.pm_assy_type,'B','B','Z')
    no data then it return no row select but
    i have return 0 how is possible , in report i have check cf, and cs to total , and no data then print 0 in text box so.
    sol1:
    select count(*), sum(nvl(a.pitm_matl_cost,0)),
    decode(b.pm_assy_type,'B','B','Z')
    from pumpitems a, pumpmast b
    where a.pitm_proj_code like 'KAWASII' and
    a.pitm_pump_type = b.pm_pump_type and
    a.pitm_comp_type = b.pm_comp_type and
    a.pitm_sr_no = b.pm_sr_no and
    substr(a.pitm_matl_code,1,1) = 'X' and
    pitm_itm_cal = 'N'
    /*and
    substr(a.pitm_matl_code,1,1) != 'C' and
    substr(a.pitm_matl_code,1,1) != 'F' and
    substr(a.pitm_matl_code,1,1) != 'S'*/
    group by decode(b.pm_assy_type,'B','B','Z')
    order by decode(b.pm_assy_type,'B','B','Z')
    count(*) is return 0 but it's notworking in this query why i dont no
    another soluction than help

    This sounds like it's similar to another recent post
    Re: How do I print some value when there is no record against field

  • NEED HELP IN CONFLICT HANDLER ERROR ORA-01403: no data found

    Hi All,
    I am using Oracle Streams to replicate the data...
    I need to update the records on the destination with some particular condition like if USER_COUNTRY = 'XXX' then the data need to be updated in the destination side else skip ...
    I wrote the procedure ..below .. the data is not replicating and found the below error from dba_apply_error..
    ORA-01403: no data found
    ORA-06512: at "SYS.LCR$_ROW_RECORD", line 419
    Table called history_row_lcrs is created in the strmadmin to store the lcr values...
    CREATE OR REPLACE PROCEDURE proc_test(in_any sys.anydata)IS
    lcr sys.lcr$_row_record;
    rc pls_integer;
    v_type varchar2(20);
    col_1 sys.anydata;
    lcr_usercountry varchar2(20);
    TRANS varchar2(20);
    skip_routine Exception;
    BEGIN
    rc:=in_any.GetObject(lcr);
    v_type:=lcr.get_command_type();
    col_1:=lcr.get_value('NEW','USER_COUNTRY');
    rc:=col_1.GetVarchar2(lcr_usercountry);
    for x in ( select user_country from TEST.TESTREP1
    where USER_COUNTRY=lcr_usercountry)
    Loop
    IF (x.USER_COUNTRY = 'XXX')
    THEN
    insert into strmadmin.history_row_lcrs VALUES (SYSDATE, lcr.GET_SOURCE_DATABASE_NAME(), lcr.GET_COMMAND_TYPE(),
    lcr.GET_OBJECT_OWNER(), lcr.GET_OBJECT_NAME(), lcr.GET_TAG(), lcr.GET_TRANSACTION_ID(), lcr.GET_SCN(),
    lcr.GET_COMMIT_SCN,lcr.GET_VALUES('old'), lcr.GET_VALUES('new', 'n'));
    lcr.EXECUTE(true);
    ELSE
    Raise Skip_routine;
    END IF;
    END Loop;
    Exception
    when skip_routine Then
    null;
    END;
    BEGIN
    DBMS_APPLY_ADM.SET_DML_HANDLER(
    object_name => 'TEST.TESTREP1',
    object_type => 'TABLE',
    operation_name => 'UPDATE',
    error_handler => false,
    user_procedure => 'STRMADMIN.PROC_TEST',
    apply_database_link => NULL,
    apply_name => NULL);
    END;
    Please try to help me if am doing something wrong...because I need to update only one colums am using DML_HANDLER instead of SET_UPDATE_CONFLICT_HANDLER...
    Any other inputs are also appreciated...
    Thanks In Advance and appreciate for the quick reply...

    I fired the query, am not getting any output from dbms_output.put_line('..|USER_COUNTRY..');
    Is that no data is reading or may be any reason else..
    in this table store_id is the primary key ..
    SQL> set serveroutput on
    SQL> CREATE OR REPLACE PROCEDURE test(in_any sys.anydata) IS
    2 lcr sys.lcr$_row_record;
    3 rc pls_integer;
    4 v_type varchar2(20);
    5 col_1 sys.anydata;
    6 col_2 sys.anydata;
    7 lcr_usercountry varchar2(20);
    8 lcr_storeid number;
    9 TRANS varchar2(20);
    10 store_id number;
    11 USER_COUNTRY varchar2(20);
    12
    13 BEGIN
    14 rc:=in_any.GetObject(lcr);
    15 v_type:=lcr.get_command_type();
    16 col_1:=lcr.get_value('NEW','USER_COUNTRY');
    17 rc:=col_1.GetVarchar2(lcr_usercountry);
    18 col_2:=lcr.get_value('NEW','STORE_ID');
    19 rc:=col_2.getnumber(lcr_storeid);
    20 select user_country into user_country from dev03.testrep1 where user_country=lcr_usercountry and store_id=lcr_storeid;
    21 dbms_output.put_line('---------||USER_COUNTRY ||-----------');
    22 END;
    23 /
    Procedure created.
    Thanks for your help ....

  • Forms application returns "ORA-01403 no data found" exception on Windows 7

    Hi everyone,
    I am currently involved in an application compatibility project for an O/S migration from Windows XP to Windows 7.
    We have a legacy Oracle Dev6i P18 Forms application that has been working perfectly on Windows XP for the last decade or so. When we installed the same application on Windows 7, it returned a pop-up error message with the text: "ORA-01403 no data found" when performing a certain operation (clicking on a Submit button in a specific form). The same operation works successfully on Windows XP displaying the message "Submit has been successful".
    This error is well documented and the solution involves adding an exception handler to the faulting SQL statement(s) in order to handle the ORA-01403 exception. Unfortunately, the application is composed of compiled forms (.FMX) and we no longer have the source code so I can't implement this solution.
    I ran a file comparison utility (WinDiff from the Windows SDK) and confirmed that all the files in the application folder and the Oracle Dev6i P18 folder are identical on both the Windows XP and Windows 7 systems.
    I enabled tracing in SQLNet.ORA by configuring TRACE_LEVEL_CLIENT=SUPPORT (I know, too verbose) and other related settings on both systems and have uploaded the traces to my SkyDrive for public viewing:
    http://sdrv.ms/10BNYtI
    The traces show that the "ORA-01403" exception occurs many times on both Windows XP and Windows 7 systems as a result of various SQL statements being executed, for instance:
    SELECT TASK_ID,TASK_DETAIL_STATUS,ASSIGNED_DATE FROM TASK_DETAILS WHERE TASK_ID = :b1 AND TASK_DETAIL_STATUS = (SELECT ID FROM V_TASK_STATUS WHERE ABBREVIATION = 'PLANNED' ) FOR UPDATE OF TASK_DETAIL_STATUS,ASSIGNED_DATE
    UPDATE TASK_DETAILS SET ASSIGNED_DATE=NTMS_UTIL.GET_SERVER_DATE,TASK_DETAIL_STATUS=(SELECT ID FROM V_TASK_STATUS WHERE ABBREVIATION = 'ASSIGNED' ) WHERE ROWID = :b1
    ORA-01403: no data found.
    So the same error happens on both Windows XP and Windows 7.
    On Windows XP, the error is somehow handled, and does not cause the "Submit" operation to fail.
    On Windows 7, however, the error bubbles to the surface and is displayed to the user, thus halting the "Submit" operation.

    Thank you. I'm well aware that adding an exception handler is the classic solution to the ORA-01403 error. However, like I mentioned in my original post, I don't have the source code. All I have are the compiled .FMX forms so I can't implement such a solution:
    From my original post:
    This error is well documented and the solution involves adding an exception handler to the faulting SQL statement(s) in order to handle the ORA-01403 exception. Unfortunately, the application is composed of compiled forms (.FMX) and we no longer have the source code so I can't implement this solution.

  • Ora-01403: no data found error in stead off messag

    Hi all,
    In a form there is a button that calls a stored procedure. In this procedure certain checks are made and if violated, QMS$ERRORS.SHOW_MESSAGE is called. Normally we can see the message text from the messages table. However, in this paricular situation we receive ora-01403: no data found. The message shows up later, when another message is invoked.
    So, our conclusion is that the stack is not correctly read.
    Problem occurs in Client server as in Webforms.
    Architecture:
    - Designer 6.0.3.9.0
    - Forms 6.0.5.34.0
    - Oracle 8.0.5.2.1
    - Windows NT 4.0 SP5 on Client as on Server
    - Oracle Forms Generator 6.0.3.2.0
    - Headstart Template Package 5.0.4
    Template Form (qmstpl50) 5.0.2
    Object Library (qmsolb50 (WEB)) 5.0.4
    Event Handler Library (qmsevh50) 5.0.3.2
    Core Library (qmslib50) 5.0.4
    Thanks in advance,
    Joep Hendrix
    [email protected]

    Sandra,
    It just happens that I am confronted with the same ora message (0ra-01403) raised apparently under similar conditions. The solution you presented, however, does not help much I am afraid in my case.
    I use a qms$errors.show_message statement in a procedure stored in a package on the database. This raises the same error that Joep receives (ora-01403). If I remove the qms$errors.show_message statement from the package no error is raised. If I use the statement in a form trigger I also do not encounter any problems. It therefore appears that the statement can not be raised from the serverside although according to the headstart 5.0.3 documentation that problem is resolved (issue 792479).
    In the headstart documentation I find a reference to qms$errors.DisplayServerQMSError. However, maybe this is outdated. This component is not included the qms$error package I have.
    Any suggestions to solve this?
    My system
    Forms 6.0.8.10.3
    Designer 7.04
    Headstart 5.04
    Oracle 8i Enterprise Edition 8.1.7
    Windows NT4
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Headstart Team:
    Joep,
    If you don't use the CDM RuleFrame version of the Headstart Template Package, normally only one message should be on the stack. It seems like in this case you have 2 messages on the stack: ORA-01403 and your custom message, and only the first is shown.
    It should not occur that there are 2 messages on the stack. Have you debugged what causes the ORA-01403? Can you catch the exception so that only your own custom message is shown?
    Hope this helps,
    Sandra<HR></BLOCKQUOTE>
    null

  • Collapsed Tabular Form Heading when "No data found".

    The ' Collapsed Tabular Form Heading when "No data found" ' problem (speculated to be bug 9893564) is discussed here: {message:id=4419231}. Warning link is out of date. I'm still seeing it in APEX 4.2.
    I support Kelly's comments "looks like something is broken" and "Now this header (which is sized smaller before data is retrieved) comes between the search items and the help message and looks clumsy.".{message:id=9185914}.
    Any suggestion to get around it when no data is found?
    1) Is there a way to hide the header when there is no data? Or,
    2) Is there a way to adjust the width of the columns if the header must display? I'd like them to be about what they are when data is displayed. I know those lengths but not how to affect the header width for a tabular report with no data.
    Example:
    WS APEX_EXAMPLES_01
    demo
    demo
    Appl 78329 Tabular Form - page 1. (I forced query not to find any data for demo purposes.)
    Thanks,
    Howard

    Howard (... in Training) wrote:
    Paul --
    Great! So many new techniques here -- new to me. Generally, I much prefer positive logic as well. But this solution seems to have more pieces than the other.There is method in that.
    Firstly, with Aljaz's approach you can see a flicker as the tabular form is actually rendered and then hidden when the script in the footer is eventually run. This will be more apparent with a longer or more complicated page where it takes longer to reach the script and more content needs to be adjusted following removal of the form. Reversing the logic and hiding the form using CSS in the page header prevents this as the form elements are initially created as hidden nodes in the DOM before any of the page is rendered.
    More important is that this approach applies the principles of the separation of concerns and unobtrusive JavaScript. At some point when developing in APEX you're going to find yourself seriously losing your cool in a situation where you know the app is executing some JavaScript, but you can't find where that script is defined (maybe you've already been there). Look at the page 2 definition using the tree view: where's the JavaScript that is going to run? Now look at page 1: ah, there are a couple of dynamic actions...
    APEX now includes a lot of containers specifically for JavaScript: File URLs, Function and Global Variable Declaration and Execute when Page Loads in page templates and page headers, and declarative and custom Execute JS Code Dynamic Actions. These provide for good separation of concerns: we should use these locations for JS code, and avoid the exasperation of hunting through templates, page/region headers/footers, page 0 regions, pre-/post-element text or wherever to find the script we can see in the page source or JS debugger.
    Aljaz's solution also depends on detecting the presence of the No Data Found message with class <tt>nodatafound</tt>, and on modifying the Add Row button.
    What if someone changes the class of the No Data Found message in the report attributes? The Exists... condition on the dynamic action performs this check in a more direct way (although it's not ideal: DRY is violated by having both 2 copies and 2 executions of the report SQL; nor is it reusable on other form regions).
    Modifying the Add Row button JavaScript directly is intrusive. Like footers and templates, it's another non-obvious location for JS customisation. By using a dynamic action to bind another click handler to the button we're making the modification more obvious, and more importantly we don't have to modify what it's already doing&mdash;or in this instance, even care what that is (in other circumstances we might need to change the order or propagation of events, or suppress the original behaviour).
    As for reusability, my original solution didn't really consider this (as it wasn't mentioned in the OP). Since the subject has been raised, and in accordance with my comments above, I'd approach it in a different way.
    As discussed, I suggest not squirrelling JavaScript away in region templates. I'd create a reusable report template for tabular forms rather than a region one. A <tt>class</tt> defined on the report container there will provide a more direct selector for hide/show behaviour. I'd stick to initially hiding this report via CSS, and use dynamic actions defined on the global page to conditionally show it on page load and bind show behaviour to the Add Row button click. To make these DAs reusable I'd remove the Exists... condition from the first one and replace it with a JS condition that checks to see if the tabular form report contains any visible data rows (the class on the report template will help there as well). Binding the show behaviour to the Add Row button would use the <tt>onclick</tt> attribute as a selector (rather than an ID selector that requires an intrusive edit of the button) so that all Add Row buttons would be affected: <tt>$('button[onclick^="apex.widget.tabular.addRow"]')</tt>.
    And about the style code:
    #report_tabular-form,
    #report_tabular-form .report-standard {
    min-width: 90%;
    } That is an improvement. I had read about it but not considered it for this. I tried the technique used to adjust column width on other reports but when I use "div," it makes the data in that column display only. I really want to adjust the width of the individual column header. Is there a way to do that?I'm not really clear what you're asking here. (Use "div"? Where? How?)
    To control the width of individual report column headers, use the following CSS:
    th#COLUMN_ALIAS {
      width: 10em;
    }Where <tt>COLUMN_ALIAS</tt> is the alias of the column in the query: APEX uses this as the HTML <tt>id</tt> attribute for the column table header element. (Note that <tt>id</tt> attributes must be unique within a document, so it the same column appears in multiple reports/forms, ensure each column alias is unique.)

  • Design studio 1.3 - No matching data found in getDataAsString

    I had developed a dashboard using DS1.2 and we have no upgraded our Business objects platform to BO 4.1 and upgraded to Design studio 1.3
    I am not getting an error message "No matching data found in getDataAsString("006EI2SHD6LIVHQ6UOHCIDRDB", {}).", which worked in DS1.2.
    I see the data on a cross table but it is only when I try and set the text as per below coding.
    // Master data spend Items
    TEXT_1.setText(DS_1.getDataAsString("006EI2SHD6LIVHQ6UOHCIDRDB",{}));

    com.sap.ip.bi.zen.rt.framework.jsengine.JsEngineException: org.mozilla.javascript.WrappedException: Wrapped java.lang.NullPointerException
    at com.sap.ip.bi.zen.rt.framework.jsengine.rhino.RhinoJsEngine.handleError(RhinoJsEngine.java:141)
    at com.sap.ip.bi.zen.rt.framework.jsengine.rhino.RhinoJsEngine.doRunScript(RhinoJsEngine.java:70)
    at com.sap.ip.bi.zen.rt.framework.jsengine.JsEngine.runScript(JsEngine.java:32)
    at com.sap.ip.bi.zen.rt.framework.jsengine.rhino.RhinoScriptInterpreterBialService.interprete(RhinoScriptInterpreterBialService.java:191)
    at com.sap.ip.bi.base.command.impl.Command.interprete(Command.java:189)
    at com.sap.ip.bi.webapplications.runtime.impl.page.Page.processCommandSequence(Page.java:4662)
    at com.sap.ip.bi.webapplications.runtime.impl.page.Page.doProcessRequest(Page.java:2537)
    at com.sap.ip.bi.webapplications.runtime.impl.page.Page._processRequest(Page.java:774)
    at com.sap.ip.bi.webapplications.runtime.impl.page.Page.processRequest(Page.java:5080)
    at com.sap.ip.bi.webapplications.runtime.impl.page.Page.processRequest(Page.java:5073)
    at com.sap.ip.bi.webapplications.runtime.impl.controller.Controller.doProcessRequest(Controller.java:1238)
    at com.sap.ip.bi.webapplications.runtime.impl.controller.Controller._processRequest(Controller.java:1088)
    at com.sap.ip.bi.webapplications.runtime.impl.controller.Controller.processRequest(Controller.java:1054)
    at com.sap.ip.bi.webapplications.runtime.impl.controller.Controller.processRequest(Controller.java:1)
    at com.sap.ip.bi.server.runtime.sevice.impl.BIRuntimeServerService._handleRequest(BIRuntimeServerService.java:538)
    at com.sap.ip.bi.server.runtime.sevice.impl.BIRuntimeServerService.handleRequest(BIRuntimeServerService.java:943)
    at com.sap.ip.bi.server.execution.engine.runtime.BIExecutionEngineRuntime.executeRequest(BIExecutionEngineRuntime.java:48)
    at com.sap.ip.bi.framework.base.execution.impl.BIExecutionService.executeRequest(BIExecutionService.java:54)
    at com.sap.ip.bi.client.execution.AbstractExecutionServlet.handleRequest(AbstractExecutionServlet.java:161)
    at com.sap.ip.bi.client.servlet.BIPrivateServlet.handleRequest(BIPrivateServlet.java:36)
    at com.sap.ip.bi.client.execution.AbstractExecutionServlet.doPost(AbstractExecutionServlet.java:140)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:755)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
    at org.eclipse.equinox.http.servlet.internal.ServletRegistration.service(ServletRegistration.java:61)
    at org.eclipse.equinox.http.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:38)
    at com.sap.ip.bi.zen.webserver.internal.ZenSessionFilter.doFilter(ZenSessionFilter.java:42)
    at org.eclipse.equinox.http.servlet.internal.FilterRegistration.doFilter(FilterRegistration.java:81)
    at org.eclipse.equinox.http.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:35)
    at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:132)
    at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:60)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
    at org.eclipse.equinox.http.jetty.internal.HttpServerManager$InternalHttpServiceServlet.service(HttpServerManager.java:386)
    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:669)
    at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:457)
    at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:229)
    at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1075)
    at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:384)
    at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
    at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1009)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
    at org.eclipse.jetty.server.Server.handle(Server.java:368)
    at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:489)
    at org.eclipse.jetty.server.AbstractHttpConnection.content(AbstractHttpConnection.java:953)
    at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.content(AbstractHttpConnection.java:1014)
    at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:861)
    at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)
    at org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:82)
    at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:628)
    at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:52)
    at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
    at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
    at java.lang.Thread.run(Unknown Source)
    Caused by: org.mozilla.javascript.WrappedException: Wrapped java.lang.NullPointerException
    at org.mozilla.javascript.Context.throwAsScriptRuntimeEx(Context.java:1786)
    at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:183)
    at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:247)
    at org.mozilla.javascript.Delegator.call(Delegator.java:229)
    at com.sap.ip.bi.zen.rt.framework.jsengine.rhino.shared.CustomFunction.call(CustomFunction.java:36)
    at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:1701)
    at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:854)
    at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:164)
    at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:426)
    at com.sap.ip.bi.zen.rt.framework.jsengine.rhino.CustomContextFactory.doTopCall(CustomContextFactory.java:54)
    at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3178)
    at org.mozilla.javascript.Context.callFunctionWithContinuations(Context.java:1204)
    at org.mozilla.javascript.Context.executeScriptWithContinuations(Context.java:1171)
    at com.sap.ip.bi.zen.rt.framework.jsengine.rhino.RhinoJsEngine.doRunScript(RhinoJsEngine.java:60)
    ... 51 more
    Caused by: java.lang.NullPointerException
    at com.sap.ip.bi.zen.rt.components.ds.impl.DataSourceCommandResolver.getCell(DataSourceCommandResolver.java:1239)
    at com.sap.ip.bi.zen.rt.components.ds.impl.DataSourceCommandResolver.getDataAsString(DataSourceCommandResolver.java:1095)
    at sun.reflect.GeneratedMethodAccessor103.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:161)
    ... 63 more

  • "no data found" run-time error masking SQL/report mismatch

    Hi all,
    At last, figured out a vexing problem and wondering if anyone else either:
    a) has also hit the problem, and hopefully
    b) has figured out a clever way around it.
    Namely, in our AppEx apps, we rely on SQL query generation from PL/SQL packaged functions. This "best practice" promotes reuse, automated testing, etc. Great idea - works great.
    However, we've repeatedly come across a situation where we go to run a page with a report on it only to get a "report error: ORA-01403: no data found" message where the report should be. Not much to go on. After trial and error, it turns out that simply going to the Region Definition page (where the PL/SQL function call is defined) and clicking the "Apply Changes" button cleared the problem up.
    Mystifying because the actual SQL query generated by the PL/SQL is valid (we've got a nightly testing job that pulls the PL/SQL function calls out of the AppEx metadata tables, executes them to get back the SQL and then validates the SQL).
    Turns out this problem looks to be a result of columns changing in the actual SQL itself, and hence not matching up to the Region Attributes (column names, one assumes) that AppEx knows about. Simply clicking Apply Changes causes AppEx to validate the returned query and then it adjusts the column attributes (one assumes) so that things match up.
    So - the $64,000 question(s):
    1) Are there any cool AppEx APIs to be able to try and detect this situation? Given an app of middling complexity (50-100 pages, each with various queries/reports), this is not an attractive issue to deal with manually.
    2) Any cool AppEx APIs to fix, or auto-sync these situations? (Essentially programmatically calling the "Apply Changes" button if you will).
    At a minimum, it would be great if AppEx could be updated to put out some kind of more informative error message when this occurs - maybe something along the lines of "Region Attributes Do Not Match Data Returned from Query", or something like that at least.
    Thanks for any input/ideas,
    Jim C.

    Thanks to all for your prompt responses.
    Vikas actually did me the favor of pretty much clarifying my info for me (tks Vikas). Yes, to all the above. It's PL/SQL code generating a SQL query, so 1 is (a); we want to use query-specific columns so it is (2a). And yes, the whole problem is that the something does change to cause the SELECT statement column list to change...nature of the beast, so "don't do that" doesn't really help here.
    Scott - sorry, should have been more explicit. Basically, we have a PL/SQL function behind a report that returns a SQL statement for the report. If that PL/SQL code changes to add a new column to the report (without going to the corresponding Report Attributes page and clicking the "Apply Changes" button to get AppEx to revalidate the query), then you wind up with this "no data found" error msg, which doesn't exactly point you to the root of the problem.
    It seems as though the "parse at compile-time" is really what's going on here. There must be some kind of "run-time" check going on as well, that is resulting in the "no data found" message. Seems as though it ought to be fairly straightforward to add some kind of check at run-time to handle that exception a little cleaner. Is there an official process to register a "Request for Process Enhancement" for AppEx to do this?
    In the meantime, thank you Vikas for the pointer to the APEX_APPLICATION_PAGE_RPT_COLS view - that looks like it will do the trick nicely. Given that, we can now add logic to our nightly "app tester" job that can compare what columns AppEx expects to find in a given report (for a given page) with the actual SQL (coming back from the PL/SQL function call) to essentially "validate" the AppEx meta data and at least let us know when these things get out of sync.
    BTW - if anyone would be interested in the actual contents of that "app tester" logic, I'd be happy to post it (someplace...here? Studio site?). It's basically just a PL/SQL block of code that currently runs in cron that just validates any SQL embedded in our app. (I suppose it is a little "hard-coded" since it does use our naming conventions for packages/functions to parse the PL/SQL calls from the Meta Data but it might still serve as a usefull starting point...) Since our AppEx app(s) sit on top of a database schema that is in fairly constant flux, we need the ability to know when somebody has changed something in the schema that needs to be accounted for in AppEx. The job primarily just parses the AppEx meta data to find PL/SQL function calls that return SQL, executes that PL/SQL to get the generated SQL, then just validates that SQL and reports back any invalid SQL calls. Perhaps we're in some unusual development environment (15-20 people working on a database schema with 700-800 tables/views) but it seems as though it would be fairly easy, for anybody using PL/SQL to generate SQL (which is a GREAT and powerful thing, by the way - thanks to whoever thought that up in AppEx land) to run into this issue.
    Jim C.

  • No Data Found Exception in bulk updates

    I am trying to catch no data found exception in bulk updates when it does not find a record to update in the forall loop.
    OPEN casualty;
    LOOP
    FETCH casulaty
    BULK COLLECT INTO v_cas,v_adj,v_nbr
    LIMIT 10000;
    FORALL i IN 1..v_cas.count
    UPDATE tpl_casualty
         set casualty_amt = (select amt from tpl_adjustment where cas_adj = v_adj(i))
         where cas_nbr = v_nbr(i);
    EXCEPTION WHEN NO_DATA_FOUND THEN dbms_output.put_line('exception')
    I get this error at the line where i have exception:
    PLS-00103: Encountered the symbol "EXCEPTION" when expecting one of the following:
    begin case declare end exit for goto if loop mod null pragma
    raise return select update while with <an identifier>
    <a double-quoted delimited-identifier> <a bind variable> <<
    close current delete fetch lock insert open rollback
    savepoint set sql execute commit forall merge pipe
    Can someone pls direct me on how to get around this?
    If I do not handle this exception, the script fails when it attempts to update a record that does not exist and the error says : no data found exception.
    Thanks for your help.
    Edited by: user8848256 on Nov 13, 2009 6:15 PM

    No Data Found isn't an exception raised when an UPDATE cannot find any records to process.
    SQL%ROWCOUNT can be used to determine the number of rows affected by an update statement, but if 0 rows are updated then no exception will be raised (it's just not how things work).
    If you post your actual CURSOR (casualty) declaration, it's quite possible we can help you create a single SQL statement to meet your requirement (a single SQL will be faster than your current implementation).
    Have you looked in to using the MERGE command?

  • Search report - error-no data found when printing to csv format

    Hi all,
    I have a search report,
    I have 4 select list and two text field and two date field to search for the result.
    I have even put the computation for the select list items in
    on load - before header ie setting the items to default value.
    Still when i try to print it in the csv format , and try to open the excel, it is saying "no data found" error
    Please, Could any one give me a solution to solve this bug?
    Note: Ordinary report is getting printted in the csv format.
    Thanks in advance
    bye
    Srikavi

    Hi Denes and Scott,
    sorry, only when i select the values for all the 4 select list
    csv is working. default values are not restored in the session.
    How to restore the values in the session state after pressing the search button.
    i have set the default values for the select list and the query is working fine
    but when i see the session from the toolbar the default values are not present.
    but when i see the debug from the toolbar the values are set properly.
    @Denes
    In your example the session is showing the values of the select list and check box
    The same way i did, but in "session" values are not seen so again no data found is seen when printing csv .
    Bye
    Srikavi

  • No Data Found for SQL query

    Hello,
    I have a simple SQL query in a report.
    select
          null as "Complete",
             a.col1,
             a.col2,
             a.col3,
             a.col4,
          b.col2
    from      TableA a, TableB b
    where   a.id = b.idThere is a known issue in apex 4.0 that is causing the "When No Data Found" message to work incorrectly so that this is returned:
    report error:
    ORA-01403: no data found
    Is there a way to return a message in a SQL statement? If not, any suggestions on how I can convert this in the existing report to PL/SQL would be appreciated.
    Thanks!
    Matt

    I would like to do something similar to this (below) but the only option that is given other than "SQL Query" is “PL/SQL function body returning a SQL query”
    I'm not sure how to do this as a funciton.
    declare
    vComplete Varchar2;
    vCol1        Varchar2;
    vCol2        Varchar2;
    vCol3        Varchar2;
    vCol4        Varchar2;
    vColB2      Varchar2;
    Begin
    select
             null as "Complete",
             a.col1,
             a.col2,
             a.col3,
             a.col4,
             b.col2
    into vComplete,vCol1,vCol2,vCol3,vCol4,vColB2
    from   TableA a, TableB b
    where   a.id = b.id
    Dbms_output.put_line(vComplete,vCol1,vCol2,vCol3,vCol4,vColB2);
    Exception
          When no_data_found
                Dbms_output.put_line(vComplete,vCol1,vCol2,vCol3,vCol4,vColB2);
          When others
                Dbms_output.put_line(‘exception handling message’);
    End;

  • No data found in csv output

    I have a classic (non-interactive) report that shows some strange behaviour.
    It's a simple page with a report region.
    On the report attributes page under 'report export' the value for 'Enable CSV output' is set to 'Yes' and 'Link label' has a meaningful discription.
    In the development database it works as expected:
    When I run the page the data is displayed and when I click the link for csv output I can either save or open the file. In both cases I find the data I expect in the csv file.
    In production, however, when I run the page the data is displayed, but when I click the link for csv output the resulting csv file just shows "No Data Found"
    I can imagine the report not returning any data, but in that case I shouldn't see any data on screen either.
    And it's extra weird that in development it all works fine.
    Anybody that can offer any help?
    Thanks in advance.

    Hi Eric
    I would never dream of telling anyone not to argue with me :D I've been wrong before and will be again, no doubt!
    For the DIV problem, I was more concerned with &lt; appearing in the output rather than the SQL statement itself - generally problems such as this happen when something on the page is incorrectly formed. When you get a chance, in FireFox, install the Web Developer add-on. When this is installed, on the right-hand end of its toolbar, you will see three buttons - the last two tell you about css and javascript errors. For HTML errors, if you have a text editor that has syntax highlighting, do a View Source on the loaded page, take a copy of the source and paste it in to a new document in the text editor. Save this with an HTML file extension. This should colour-highlight everything. It should become obvious what is wrong as you tend to end up with way too much in the same colour. Finally, on the loaded page, right-click on the DIV text and select Inspect Element - this switches you to a heirarchical view of the HTML on the page in the FireBug pane. Follow the tree up from the DIV and have a look at the structue - at some point, something will look wrong.
    Andy

Maybe you are looking for