Using '(' and less than operator in an xsql page sql query

Dear All,
I tried to use left parenthesis '(' and less than operator in an sql query through an xsql page, it doesn't let to use them.
Do you know how to use those in an xsql page?
Thanks for your help.
Mustafa

Following is the xsql page that I tried to run:
<?xml version="1.0"?>
<xsql:query xmlns:xsql="urn:oracle-xsql" connection = "bib" rowset-element="bib" row-element="book">
(SELECT year,title,last,first,' ' as affiliation,publisher,price
FROM book,author
WHERE year=2001 and bookid=parentid
UNION
SELECT year,title,last,first,affiliation,publisher,price
FROM book,editor
WHERE year=2001 and bookid=parentid)
INTERSECT
(SELECT year,title,last,first,' ' as affiliation,publisher,price
FROM book,author
WHERE publisher='Publisher1' and bookid=parentid
UNION
SELECT year,title,last,first,affiliation,publisher,price
FROM book,editor
WHERE publisher='Publisher1' and bookid=parentid)
</xsql:query>
This is the error message generated after running:
<ERROR>java.sql.SQLException: ORA-01009: missing mandatory parameter</ERROR>
When I remove the parentheses it works but this results in a different result set.
Can anybody tell me the reason?
Thanks,
Mustafa
null

Similar Messages

  • (BUG): using less than operator in javascript

    I am using Jdeveloper 11.1.1.5.0, ADF BC, ADF Faces.
    I am trying to add some java script validation in my page, just want to check if the length of an input field is less than three or not.
    here is the function I used
    function filterForNumbers(evt){
    var inputField = evt.getSource();
    var oldValue  = inputField.getValue();
    var myField   = inputField.findComponent("it2");
    var len = oldValue.length;
    if (len < 3)      
       alert ("the length is <  3" );
       myField.setValue("");
    }when I use the less then operator (<) in this part
    if (len < 3)ADF frame work considers the < as an open tag and when I run the page, it shows this error message in the log
    Error(16,16):  Illegal token.
    and the page does not run.
    workaround*
    using this syntax instead
    if (3 > len)

    Thank again Sireesha,
    I tried your suggestion with and without space. What I get is that the there is no thing on the page (only blank page is shown).
    here is my page source
    <?xml version='1.0' encoding='UTF-8'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
              xmlns:f="http://java.sun.com/jsf/core"
              xmlns:h="http://java.sun.com/jsf/html"
              xmlns:af="http://xmlns.oracle.com/adf/faces/rich">
      <jsp:directive.page contentType="text/html;charset=UTF-8"/>
      <f:view>
        <af:document id="d1" partialTriggers="it2">
          <af:resource type="javascript">
           function filterForNumbers(evt){
           var inputField = evt.getSource();
           var oldValue = inputField.getValue();
           var myField = inputField.findComponent("it2");
           var len = oldValue.length;
           if (len &lt 3)      
             alert ("the length is <  3" );
             myField.setValue("");
          </af:resource>
          <af:messages id="m1"/>
          <af:form id="f1">
            <af:panelFormLayout id="pfl1">
              <af:inputText value="#{bindings.Id.inputValue}"
                            label="#{bindings.Id.hints.label}"
                            required="#{bindings.Id.hints.mandatory}"
                            columns="#{bindings.Id.hints.displayWidth}"
                            maximumLength="#{bindings.Id.hints.precision}"
                            shortDesc="#{bindings.Id.hints.tooltip}" id="it1">
                <f:validator binding="#{bindings.Id.validator}"/>
                <af:convertNumber groupingUsed="false"
                                  pattern="#{bindings.Id.format}"/>
              </af:inputText>
              <af:inputText value="#{bindings.Description.inputValue}"
                            label="#{bindings.Description.hints.label}"
                            columns="#{bindings.Description.hints.displayWidth}"
                            maximumLength="#{bindings.Description.hints.precision}"
                            shortDesc="#{bindings.Description.hints.tooltip}"
                            id="it2" required="true">
                <f:validator binding="#{bindings.Description.validator}"/>
                <af:clientListener method="filterForNumbers" type="valueChange"/>
              </af:inputText>
              <af:inputText value="#{bindings.Flag.inputValue}"
                            label="#{bindings.Flag.hints.label}"
                            required="#{bindings.Flag.hints.mandatory}"
                            columns="#{bindings.Flag.hints.displayWidth}"
                            maximumLength="#{bindings.Flag.hints.precision}"
                            shortDesc="#{bindings.Flag.hints.tooltip}" id="it3">
                <f:validator binding="#{bindings.Flag.validator}"/>
              </af:inputText>
              <f:facet name="footer">
                <af:panelGroupLayout layout="vertical" id="pgl2">
                  <af:panelGroupLayout layout="horizontal" id="pgl1">
                    <af:commandButton actionListener="#{bindings.First.execute}"
                                      text="First"
                                      disabled="#{!bindings.First.enabled}"
                                      partialSubmit="true" id="cb3"/>
                    <af:commandButton actionListener="#{bindings.Previous.execute}"
                                      text="Previous"
                                      disabled="#{!bindings.Previous.enabled}"
                                      partialSubmit="true" id="cb4"/>
                    <af:commandButton actionListener="#{bindings.Next.execute}"
                                      text="Next"
                                      disabled="#{!bindings.Next.enabled}"
                                      partialSubmit="true" id="cb5"/>
                    <af:commandButton actionListener="#{bindings.Last.execute}"
                                      text="Last"
                                      disabled="#{!bindings.Last.enabled}"
                                      partialSubmit="true" id="cb1"/>
                  </af:panelGroupLayout>
                  <af:commandButton text="Submit" id="cb2"/>
                </af:panelGroupLayout>
              </f:facet>
            </af:panelFormLayout>
          </af:form>
        </af:document>
      </f:view>
    </jsp:root>

  • Problem with the operator less than or equal to in a weby query

    Hi all.
    The universe is a OLAP Universe
    When i created a query in webi and put the month in the filter area with the operator less than or equal to like this.
    Month (less than or equal to) 2010.01 for example. The all result brings also the all values like 2010.02, 2010.03, etc
    What is the problem and how can fix that ?
    Thanks

    Looks like you are using a less than or equal to with a Sting data type.
    I think you should change to your filter to Year <= 2010 And Month <= 1. Hope you have a month and year object in you BeX.
    Anil

  • I tunes says capacity used is less than I pod classic states

    I tunes says capacity used is less than I pod classic states i have a 120gb classic but itunes state capacity is 111gb

    The difference is explained by the complicated way that memory is counted and the fact that some space is used up by the operating system which makes the iPod work. My 160GB Classic has about 148GB that I can actually use.
    So your iPod is reporting the amount of space that you can use - 111GB

  • Greater than AND less than

    i want to say 'if the root current frame is greater than 40
    and less than 50...
    if (_root._currentframe= ?)
    sorry, i'm kinda crap at this! please help!...

    You need to have a double || to get the logical or, otherwise
    you get the bitwise or.
    NSurveyor, I always put brackets, simply for readability. 25
    years ago I have been programming in APL, probably the "shortest"
    programming language ever. It looked like swearing in cartoons,
    with lots of stars, bombs and knives :-) I knew very few people
    that could read and understand those programs once they were
    written, not even the authors themselves. That taught me to
    introduce
    redundancy

  • Can anyone confirm if you can in fact shoot/edit (perhaps using a less than best video setting) on a Canon XA20 or Sony HXR-NX30U with iMovie 10 (Mavericks)? I do not want to convert files. Thx.

    Can anyone confirm if you can in fact shoot/edit (perhaps using a less than best video setting) on a Canon XA20 or Sony HXR-NX30U with iMovie 10 (Mavericks)? I do not want to convert files. Thx.

    Hi road.north,
    Welcome to the Support Communities!
    The article below will help you determine which cameras are supported for iMovie '10
    Apple - iLife Help - iMovie Supported Cameras
    http://help.apple.com/imovie/10/cameras/en/index.html?lang=en_US
    Cheers,
    - Judy

  • LIKE operator is not working in SQL Query in XML file

    Hi Gurus,
    LIKE operator is not working in SQL query in XML template.
    I am creating a PDF report in ADF using Jdeveloper10g. The XML template is as follows
    <?xml version="1.0" encoding="WINDOWS-1252" ?>
    <dataTemplate name="catalogDataTemplate" description="Magazine
    Catalog" defaultPackage="" Version="1.0">
    <parameters>
    <parameter name="id" dataType="number" />
    <parameter name="ename" dataType="character" />
    </parameters>
    <dataQuery>
    <sqlStatement name="Q1">
    <![CDATA[
       SELECT ename, empno, job, mgr from EMP where deptno=:id and ename LIKE :ename || '%']]>
    </sqlStatement>
    </dataQuery>
    <dataStructure>
    <group name="EmployeeInfo" source="Q1">
    <element name="EmployeeName" value="ename" />
    <element name="EMPNO" value="empno" />
    <element name="JOB" value="job"/>
    <element name="MANAGER" value="mgr" />
    </group>
    </dataStructure>
    </dataTemplate>
    if i pass the parameter value of :ename from UI, it doesn't filter. But if I give ename = :ename it retrieves the data. Can anyone help me why LIKE operator doesn't work here?
    Appreciate your help,
    Shyamal
    email: [email protected]

    Hi
    Well for a start, you are doing some very strange conversions there. For example...
    and to_char(a.msd, 'MM/DD/YYYY') != '11/11/2030'
    and to_char(a.msd, 'MM/DD/YYYY') != '10/10/2030'If a.msd is a date then you should e converting on the other side ie.
    and a.msd != TO_DATE('11/11/2030', 'MM/DD/YYYY')
    and a.msd != TO_DATE('10/10/2030', 'MM/DD/YYYY')Also, you may want to take into consideration nothing being input in :P2_ITEM_NUMBER like this...
    AND INSTR(a.item_number,NVL(:P2_ITEM_NUMBER,a.item_number)) > 0Is item number actually a number or char field? If it's a number, you want to explicitly convert it to a string for using INSTR like this...
    AND INSTR(TO_CHAR(a.item_number),NVL(TO_CHAR(:P2_ITEM_NUMBER),TO_CHAR(a.item_number))) > 0?
    Cheers
    Ben

  • Design Question: Can I use Rest-CsPoolRegisterState command in order start Front End Service when Quorum is lost and less than 85% of FES are available?

    Hi, 
    Assuming below setup for Enterprise edition Lync 2013
    Single Pool Stretched architecture with 4 FES servers
    Site A Data Center
    Site B Data Center
    FES
    2
    2
    SQL
    1 Primary
    1 Mirror
    Fact: In a situation when we lose network connectivity to Site A DC, and due to less than 50% FES servers, Quorum will be lost and as a result Front End Service will stop after 5 minutes. 
    The question is, would I be able to do a manual intervention by using this command
    Reset-CsPoolRegistrarState –PoolFqdn <pool name fqdn> –ResetType QuorumLossRecovery , and start FES with just 2 FES servers in Site B DC and 1 SQL
    Server?
    The reason I am asking this question is because it is mentioned in one of the Lync manuals that at least 85% of the servers must be available to recover once the Quorum has lost. The same manual also mentions to use above
    mentioned command in order to recover from Quorum Loss despite the fact that the lost FES servers are still not available.
    Thanks in Advance

    Hi,
    In Lync server 2013 Stretched pools are not supported for the Front End, Edge, Mediation, and Director server roles. It need two Lync pools.
    If one pool fail to connect, An administrator can declare an emergency and fail over the pool to the backup pool.  That is done by using the:
    Invoke-CsPoolFailover –PoolFQDN <Pool fqdn> –DisasterMode –Verbose
    More details:
    http://blog.avtex.com/2012/07/26/understanding-lync-2013-server-failover/
    Note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information
    found there. Please make sure that you completely understand the risk before retrieving any suggestions from the above link.
    Best Regards,
    Eason Huang
    Eason Huang
    TechNet Community Support

  • Reporting - using the less than function or the filter.

    Hi,
    I am trying to make a report about the opportunities and their values. I decided to add 3 times the same revenue colomn because I wanted the first colomn to show me the revenus under 10000, the seconde one, the revenues between 10000 and 100000 and the third one, the revenues greater than 100000.
    In order to do that, I selected the function button in the creation of my rapport and I tried it 2 different ways.
    1° I choose the filter button (in the function pop up), select the field on my left panel and choose for the first colomn for example "less than" 100000.
    The formula that appears in this one:
    FILTER("- Revenue Custom Metrics".S_CUR_0+"- Revenue Custom Metrics".S_CUR_0 USING ("- Revenue Custom Metrics".S_CUR_0 < 100000))
    When I try to execute, I get this error message:
    [nQSError: 10058] A general error has occurred. [nQSError: 22034] Aggregate is not allowed within USING clause of a FILTER operator. (HY000)
    SQL Issued: SELECT "- Account Custom Attributes".PICK_3, "- Opportunity Custom Attributes".TEXT_30, "- Revenue Custom Metrics".S_CUR_0, FILTER("- Revenue Custom Metrics".S_CUR_0+"- Revenue Custom Metrics".S_CUR_0 USING ("- Revenue Custom Metrics".S_CUR_0 < 100000)), Opportunity."Current Sales Stage" FROM "Opportunity Analysis"
    2° I try to use the "<" sign without using the filter. So I click on the appropriate colomn and add < 100000, so it becomes:
    "- Revenue Custom Metrics".S_CUR_0+"- Revenue Custom Metrics".S_CUR_0 < 100000
    I receive the following error message:
    [nQSError: 10058] A general error has occurred. [nQSError: 27002] Near <<>: Syntax error [nQSError: 26012] . (HY000)
    SQL Issued: SELECT "- Account Custom Attributes".PICK_3, "- Opportunity Custom Attributes".TEXT_30, "- Revenue Custom Metrics".S_CUR_0, "- Revenue Custom Metrics".S_CUR_0+"- Revenue Custom Metrics".S_CUR_0 < 100000, Opportunity."Current Sales Stage" FROM "Opportunity Analysis"
    Can someone tell me what I did wrong ?
    Thanks a lot

    firstly, didn't understand why you are adding the metric to itself in the Fx.
    secondly, you could have used case when statements, something like CASE WHEN metric <10000 THEN metric ELSE NULL END and so forth

  • Does Less Than ( ) operator works in the data template SQL within CDATA ??

    All,
    I am trying to use <= operator (<= sysdate) in the data template sql query and it's throwing Java exceptions.
    I have CDATA around my sql and XML parser should ignore '<' symbol. Query works fine if I use 'ampersandlt;=' operator. Here is my query
    <sqlStatement name="Q_1" dataSourceRef="">
    <![CDATA[select * from table where date_column <= sysdate]]>
    </sqlStatement>
    Just want to know if this is a bug.
    Thanks
    Problem was solved. Use 'ampersandlt;' where ampersand is '&' for less than

    Try this..
    select * from table where date_column <= sysdate

  • How do I reduce a picture to less than 50kb and less than 500 by 500 ratio?

    I'm trying to upload pictures to a Web site that requires the size of the picture to be no larger than 50kb, as well as less than 500 by
    500.
    I've tried cropping and exporting. I can get the aspect to less than
    500 by 500, but then the kb size gets larger.
    Thanks,
    Paul

    Paul,
    iPhoto won't downsize your photos, since your original would lose much quality if you could do that. Just crop to best suit the aesthetics of the photo. Then to resize for the website, do File > Export > File Export to a Desktop folder. Instead of "full size" select "scale photos no larger than" and type 500 pixels in one of the dimension boxes. (Choose the larger dimension - width for landscape photos, or height for portrait.) iPhoto will automatically constrain the proportions and enter the second amount. Only the exported copies will be resized. Upload those from the Desktop to the website, then trash when finished.
    Regards.

  • How to use not less than or equal to in condition

    I written a querry based on the below condition in sql querry
    b.key <= a.key
    Based on this it will return records.
    I need remaining records that not satisfy the above condition.
    That means not less than or equal to records...

    937506 wrote:
    I written a querry based on the below condition in sql querry
    b.key <= a.key
    Based on this it will return records.
    I need remaining records that not satisfy the above condition.
    That means not less than or equal to records...you mean
    b.key > a.key?

  • Can we use session variables in BI publisher's Data Model SQL Query?

    Hi Experts,
    We need to implement Data level security in BI Publisher 11g.
    In OBIEE we do so by using session variables, so just wanted to ask if we can use the same session variables in BI Publisher as well
    ie can we include the where clause in the Data Models SQL Query like
    Where ORG_ID = @{biServer.variables['NQ_SESSION.INV_ORG']}
    Let me know your views on this.
    PS: We are implementing EBS r12 security in BI Publisher.
    Thanks

    Read this -> OBIEE 11g: Error: "[nQSError: 23006] The session variable, NQ_SESSION.LAN_INT, has no value definition." when Creating a SQL Query using the session variable NQ_SESSION.LAN_INT in BI Publisher [ID 1511676.1]
    Follow the ER - BUG:13607750 - NEED TO BE ABLE TO SET A SESSION VARIABLE IN OBIEE AND USE IT IN BI PUBLISHER
    HTH,
    SVS

  • Why field length is shorter than the actual one in a SQL query based grid?

    Hi,
    I have a grid based on a SQL query on a UDO table, but I found when I retrieve the data from a SQL query some column show only part of data. For example, in SQL server the query should return one column data like "ABCD", but in the grid it only shows "A" or "AB". I think the SQL query should be good because when copy the same query executing in SQL server side, it returns me all complete data. But when it is executed in add-on inside a grid, then some column only returns me partial data. In most case it only return the first one or two characters. I don't see any special in the query. Basically it is normal SELECT query, the only possible special is it is using "UNION".
    The SQL query looks like below:
    SELECT fieldA, fieldB FROM table1
    UNION ALL
    SELECT fieldA, fieldB FROM table2
    When it is executed in SQL side, everything looks good, but when i run it in a grid in add-on then fieldB column only display partial data.
    Any idea?
    Thanks,
    Lan
    Edited by: ZHANGLAN on Oct 4, 2011 11:55 PM

    Hi All,
    Thanks for all your replies, I agree that the issue is caused by the UNION in SQL query. Because when i create a view in SQL based on that query and the grid is based on that SQL view then everything is fine now. I think Petr's solution should work in this case.
    Thank you again!
    Lan

  • Bought my 1st iPhone today (4S)  Just started using for less than 5 minutes and it has a voice command that talks on Everything and the pages wont scroll up and down and cant change screens from the page it boots on.  Wrong apps open when I open an app...

    So I bought my wife our 1st iPhone 4S today w/ Verizon.  I booted it up and it started having a voice repeat every command, and function (no, its not Siri).
    BTW...  Siri doesn't work, I can't scroll in the settings, when I open an app it actually opens the wrong app, and I can't find a way do fix any of it.  I tried a hard boot by holding down the power button and the button on the lower midddle of the phone.  When it rebooted, it got worse.  Now what?
    Not too excited about switching phones if this has already begun...  Any advice would be appreciated.

    iPhone User Guide
    Voice Over Fix
    Settings > General > Accessibility > Voice Over > Off
    Or
    Press the Home Button 3 Times
    iPhone: Configuring accessibility features (including VoiceOver and Zoom)

Maybe you are looking for

  • Reporting.... Cost savings, open purchase orders

    I am new to SAP and I have so many questions and ZERO answers.   I would like to be able to find all my open orders (and find ones overdue) so I can follow up with the suppler.   My second report is tracking cost savings on min/max items.  Is there a

  • Jdbc url

    Hello - I am new into ODI development and trying to create a data server for an xml file which is in my unix directory. When i try to test the connection it shows me the following error. Could you please help me overcome this. java.lang.Exception: ja

  • I upgraded my ipad to iOS 5.1.  However, my Youtube favorites are missing.  These are favorites saved on the iPad, not on the youtube account.

    I upgraded my iPad to iOS 5.1.  Afterwards, my Youtube favorites are missing.  These are favorites saved on the iPad and not linked to a Youtube account. I have tried restarting the iPad several times to no avail.  The favorites seems to be still on

  • Sales order & Billing document  ( VBAK & VBRK )

    Hello All, What is the link between table VBAK and VBRK? I have requirement where I need to find out the sales document number from the billing document number. I can see the relation in the relationship browser but I couldn't find the columns which

  • Horizontal pics going black when double clicked

    We have a Mac OS X version 10.6.8 We are using iPhoto and have been for about 2 years.  Are current version is iPhoto 09 version 8.1.2 (424). My husband and I have 2 different accounts set up on our iMAC.  It has always been set up this way.  In the