Problem evaluating boolean in XSLT

Hi,
I am running into a wierd problem. I have a small BPEL process with input schema as shown below.
<element name="testIssuesProcessRequest">
<complexType>
<sequence>
<element name="boolValue" type="boolean"/>
<element name="dateValue" type="date"/>
<element name="timeValue" type="time"/>
</sequence>
</complexType>
</element>
In my BPEL process I have a switch statement which checks the value of boolValue and takes the appropriate path. The problem is this variable is always evaluating to true(I tried using true, false, 0, 1). The function I am using is
bpws:getVariableData('inputVariable','payload','/client:testIssuesProcessRequest/client:boolValue')
I tried the similar approach in XSLT and it is the problem
/ns1:testIssuesProcessRequest/ns1:boolValue = true()
I am not sure what I am missing. Is there a different way to treat boolean values
in xslt? Any pointers will be of great help.
Thanks
Raj

Use < instead of < symbol, if your javascript doesnt need to be generated from some template from some XML value you also could insert it into a CDATA section.
I hope it can help you.

Similar Messages

  • "Problem evaluating a condition" at Receiver Determination

    Hi,
    I've created a complex mail to rfc interface, in which, message is being send as mail attachment  and service inbound interface has multiple operations (each for corresponding rfc).
    at Receiver Determination, rule was created with multiple conditions, in order to determine correct "Communication Component" (multiple receiver agreement and  interface determination were created to supported this "multi interfaces" scenario).
    If no receiver was found message is ignored.
    once in a while, bad non-xml messages (e.g., "asdfasdfasdfffdfdsasdf") are being send,  is this case, while PI is trying to determining the receiver (i.e., evaluate Receiver Determination conditions) exception is being thrown, message is therefor has system error status* (at sxmb_moni) and it can not be ignored (as i wanted it to be).
    how can i workaround this problematic scenario?
    Regards
    Uri
    *Error message (sxmb_moni)
      <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Receiver Determination
      -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
      <SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="RCVR_DETERMINATION">CX_RD_PLSRV</SAP:Code>
      <SAP:P1>Problem evaluating a condition: An exception has occurred.</SAP:P1>
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText />
      <SAP:Stack>Error when determining the receiver: Problem evaluating a condition: An exception has occurred. Problem evaluating a condition: An exception has occurred. An exception has occurred. An exception has occurred. An exception has occurred. An exception has occurred. An exception has occurred. Problem extracting values from the Payload: Check line 2 column 1 of the XML document</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>

    Abhishek,
    10x for your replay, but as far as i understand this is exactly the case here.
    conditions are:
    cond1: (/rfc: RFC1 ~ *)
    cond2: (/rfc: RFC2 ~ *)
    this works as expected in cases of xml messages (in case no cond is satisfied) message is ignored. but, in case of non-xml message exception is being thrown while cond is assessed.
    Regards
    Uri

  • Problem evaluating a condition: Exception CX_SWF_RLS_RULE occurred

    Hi all,
    I have a scenario MAIL TO PROXY, and i would like to receive incorrect xml files and send an answer telling this error.
    My problem is in the receiver determination, an error is produced as "Problem evaluating a condition: Exception CX_SWF_RLS_RULE occurred".
    Is there any way to solve this and send an email as an answer?

    Hi,
    Can you provide the whole error message ?
    Check out this thread : Re: Error in Receiver Determination
    Thanks,
    Pooja Pandey

  • Problem with Booleans and events

    I have an event structure inside a while loop. I have several buttons each of which triggers one event. Now no matter what latch action I try with these at any point of time only one of the events run. So if I want to run another event I have to stop the main vi run it again and then go to the next event. I guess what this means is that the events are not being terminated by value change. But I have tried to reset the value of the boolean as well in order to terminate but event this doesnt seem to work.There is some fundamental problem somewhere but I am unable to figure it out. Can somebody please help me.
    I am attaching a sample vi and sub vis that demonstrate this problem. In this case I need to have the booleans h
    ave the switch when released action. i.e as long as the button is pressed the camera i control moves left and as soon as I release it it shud stop.
    Attachments:
    CamInte.vi ‏108 KB
    Left.vi ‏190 KB
    Right.vi ‏190 KB

    You need to decide whether you want things controlled by events, or by loop polling.
    Some things to consider:
    Inside each event you have a loop where you read the booleans the events react to. That means the events will be fired over and over again inside the loop, and you'll have a stack of old events to be fired when the while loop has exited...events you don't really want to do anything about (use events for all the button clicks, or loops - not a mix).
    Events are still flow controlled so when the left event fires and it enters the while loop it won't handle any other events until that while loop has finished.
    When an event fires the button value if read at the same time is not the value the event fired on. So when you have an event that fires when
    you press the button, if you wire the button value to something inside that even it won't be true, it will be false. Use the new value output of the event case to read the value you really want.
    MTO

  • Problem in formatting with XSLT

    Hi -
    I am using xslt to format my xml file. Below is teh code that i worte. The structure and teh xslt file are both shown below. The airport has an attribute called name. The problem is while displaying the text in the record element, I should also display the airport name. Can you please let me know how to do this? The code that I used in my xslt which is <xsl:value-of select="root/state/city/airport/@apt_ident" />
    prints the same value for all the records.
    <root>
         <state>
              <city>
                   <airport>
                        <record/>
                        <record/>
                        <record/>
                   <airport/>
                   <airport>
                        <record/>
                        <record/>
                        <record/>
                   <airport/>
              </city>
              <city>
                   <airport/>
                        <record/>
                        <record/>
                        <record/>
                   <airport/>
                   <airport>
                        <record/>
                        <record/>
                        <record/>
                   <airport/>
              </city>
         </state>
         <state>
         </state>
         <state>
         </state>
    </root>
    // The xslt file
    <xsl:template match="/">
      <html>
      <body>
      <table border="1" bordercolor="white" cellspacing="0" width="100%" style="font-family: Tahoma; font-size: 8pt;" >
      <th align="Left">Airport ID</th>
      <th align="Left">Title1</th>
      <th align="Left">Title 2</th>
         <xsl:for-each select="root/state_code">
         <xsl:for-each select="./city_name">
         <xsl:for-each select="./airport_name">
         <xsl:for-each select="./record">
    <tr>          <td><xsl:value-of select="root/state/city/airport/@apt_ident" /></td>
              <td><xsl:value-of select="chart" /></td>
              <td><xsl:value-of select="flight" /></td>
    </tr>
         </xsl:for-each>
         </xsl:for-each>
         </xsl:for-each>
         </xsl:for-each>
         </table>
         </body>
         </html>
    </xsl:template>

    Ok...I think you have a little bit bigger issue...I am not sure (cause I didn't test it), but I do not think you need to do the nested loops..Once you loop over state you have a elements of "state" available for you to manipulate.
    try this (and I apologize if it is wrong)
    <xsl:template match="/"> 
    <html> 
    <body> 
    <table border="1" bordercolor="white" cellspacing="0" width="100%" style="font-family: Tahoma; font-size: 8pt;" > 
    <th align="Left">Airport ID</th> 
    <th align="Left">Title1</th> 
    <th align="Left">Title 2</th>     
    <xsl:for-each select="root/state_code">
    <tr>     
    <td><xsl:value-of select="state/city/airport/@apt_ident" /></td>
    <td><xsl:value-of select="chart" /></td>
    <td><xsl:value-of select="flight" /></td></tr>
    </xsl:for-each>
    </table>
    </body>
    </html>
    </xsl:template>

  • Problem in XSD and XSLT

    Actually I have a problem relating to Oracle 10g XML DB. I’ll explain the scenario.
    1.     First an xml file needs to be loaded into the database( after registering the schema)
    2.     Later maybe after inserting suppose 10 xml files into the table, I need to add an element in the xml.
    3. And the new xml's which are later loaded will have that additional field coming in. so how should I go about from here.
    What I’ve thought is:
    1.     Generate a new XSD schema (don’t know how to generate this automatically), implementing the additional field change.(can u help me in this)
    2.     Create a new XSL depending on the new XSD schema (don’t know how to generate this automatically). (can u help me in this)
    3.     apply the new xsl to the original xml to get the new xml.
    4.     in the meantime, keep the old xml in a temporary tables, and later, update those xml corresponding to the new schema (can u help me in this)
    I don’t know if this a correct procedure, if in case, there is a different and an easy method to do it, please let me know.
    regards,
    athar

    Does the following help
    SQL> set long 10000 pages 50
    SQL> --
    SQL> declare
      2    res boolean;
      3    xmlschema xmltype := xmltype(
      4  '<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://x
      5     <xsd:complexType name="T_person" xdb:SQLType="PERSON_T">
      6       <xsd:all>
      7         <xsd:element name="first_name" type="xsd:string" />
      8         <xsd:element name="last_name" type="xsd:string" />
      9         <xsd:element name="birth_day" type="xsd:date" />
    10       </xsd:all>
    11       <xsd:attribute name="employee_id" type="xsd:positiveInteger" />
    12     </xsd:complexType>
    13     <xsd:element name="person" type="T_person" xdb:defaultTable="XML_LOAD"/>
    14  </xsd:schema>');
    15  begin
    16    if (dbms_xdb.existsResource('/public/testcase.xsd')) then
    17      dbms_xdb.deleteResource('/public/testcase.xsd');
    18    end if;
    19    res := dbms_xdb.createResource('/public/testcase.xsd',xmlschema);
    20  end;
    21  /
    PL/SQL procedure successfully completed.
    SQL> call dbms_xmlschema.deleteSchema('www.WMDurl.com',4)
      2  /
    Call completed.
    SQL> begin
      2    dbms_xmlschema.registerSchema ('www.WMDurl.com',xdburitype('/public/testcas
      3  end;
      4  /
    PL/SQL procedure successfully completed.
    SQL> desc XML_LOAD
    Name                                      Null?    Type
    TABLE of SYS.XMLTYPE(XMLSchema "www.WMDurl.com" Element "person") STORAGE Object-r
    SQL> --
    SQL> desc PERSON_T
    PERSON_T is NOT FINAL
    Name                                      Null?    Type
    SYS_XDBPD$                                         XDB.XDB$RAW_LIST_T
    employee_id                                        NUMBER(38)
    first_name                                         VARCHAR2(4000 CHAR)
    last_name                                          VARCHAR2(4000 CHAR)
    birth_day                                          DATE
    SQL> --
    SQL> insert into xml_load values (xmltype(
      2  '<person employee_id="1">
      3     <first_name>mark</first_name>
      4     <last_name>drake</last_name>
      5     <birth_day>2006-01-31</birth_day>
      6   </person>'
      7  ))
      8  /
    1 row created.
    SQL> commit
      2  /
    Commit complete.
    SQL> set long 10000
    SQL> --
    SQL> select * from xml_load
      2  /
    SYS_NC_ROWINFO$
    <person employee_id="1">
      <first_name>mark</first_name>
      <last_name>drake</last_name>
      <birth_day>2006-01-31</birth_day>
    </person>
    SQL> insert into xml_load values (xmltype(
      2  '<person employee_id="1">
      3     <first_name>barney</first_name>
      4     <last_name>rubble</last_name>
      5     <birth_day>2006-01-31</birth_day>
      6     <address>Bedrock</address>
      7   </person>'
      8  ))
      9  /
    insert into xml_load values (xmltype(
    ERROR at line 1:
    ORA-30937: No schema definition for 'address' (namespace '##local') in parent
    '/person'
    SQL> commit
      2  /
    Commit complete.
    SQL> set long 10000
    SQL> --
    SQL> select * from xml_load
      2  /
    SYS_NC_ROWINFO$
    <person employee_id="1">
      <first_name>mark</first_name>
      <last_name>drake</last_name>
      <birth_day>2006-01-31</birth_day>
    </person>
    SQL> select xdbUriType('/public/testcase.xsd').getXML()
      2    from dual
      3  /
    XDBURITYPE('/PUBLIC/TESTCASE.XSD').GETXML()
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://xmlns
    .oracle.com/xdb">
      <xsd:complexType name="T_person" xdb:SQLType="PERSON_T">
        <xsd:all>
          <xsd:element name="first_name" type="xsd:string"/>
          <xsd:element name="last_name" type="xsd:string"/>
          <xsd:element name="birth_day" type="xsd:date"/>
        </xsd:all>
        <xsd:attribute name="employee_id" type="xsd:positiveInteger"/>
      </xsd:complexType>
      <xsd:element name="person" type="T_person" xdb:defaultTable="XML_LOAD"/>
    </xsd:schema>
    SQL> declare
      2    xmlschema xmltype := xdburitype('/public/testcase.xsd').getXML();
      3    res boolean;
      4  begin
      5    select insertChildXML
      6           (
      7             xmlschema,
      8             '/xsd:schema/xsd:complexType[@name="T_person"]/xsd:all',
      9             'xsd:element',
    10             xmltype('<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    11             'xmlns:xsd="http://www.w3.org/2001/XMLSchema"'
    12           )
    13      into xmlSchema
    14      from dual;
    15    if (dbms_xdb.existsResource('/public/newTestcase.xsd')) then
    16      dbms_xdb.deleteResource('/public/newTestcase.xsd');
    17    end if;
    18    res := dbms_xdb.createResource('/public/newTestcase.xsd',xmlschema);
    19  end;
    20  /
    PL/SQL procedure successfully completed.
    SQL> select xdbUriType('/public/newTestcase.xsd').getXML()
      2    from dual
      3  /
    XDBURITYPE('/PUBLIC/NEWTESTCASE.XSD').GETXML()
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://xmlns
    .oracle.com/xdb">
      <xsd:complexType name="T_person" xdb:SQLType="PERSON_T">
        <xsd:all>
          <xsd:element name="first_name" type="xsd:string"/>
          <xsd:element name="last_name" type="xsd:string"/>
          <xsd:element name="birth_day" type="xsd:date"/>
          <xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="address" t
    ype="xsd:string"/>
        </xsd:all>
        <xsd:attribute name="employee_id" type="xsd:positiveInteger"/>
      </xsd:complexType>
      <xsd:element name="person" type="T_person" xdb:defaultTable="XML_LOAD"/>
    </xsd:schema>
    SQL> begin
      2    dbms_xmlschema.CopyEvolve
      3    (
      4       xdb$string_list_t('www.WMDurl.com'),
      5       XMLSequenceType(xdburitype('/public/newTestcase.xsd').getXML()),
      6       null
      7    );
      8  end;
      9  /
    PL/SQL procedure successfully completed.
    SQL> desc XML_LOAD
    Name                                      Null?    Type
    TABLE of SYS.XMLTYPE(XMLSchema "www.WMDurl.com" Element "person") STORAGE Object-r
    SQL> --
    SQL> desc PERSON_T
    PERSON_T is NOT FINAL
    Name                                      Null?    Type
    SYS_XDBPD$                                         XDB.XDB$RAW_LIST_T
    employee_id                                        NUMBER(38)
    first_name                                         VARCHAR2(4000 CHAR)
    last_name                                          VARCHAR2(4000 CHAR)
    birth_day                                          DATE
    address                                            VARCHAR2(4000 CHAR)
    SQL> --
    SQL> insert into xml_load values (xmltype(
      2  '<person employee_id="2">
      3     <first_name>barney</first_name>
      4     <last_name>rubble</last_name>
      5     <birth_day>2006-01-31</birth_day>
      6     <address>Bedrock</address>
      7   </person>'
      8  ))
      9  /
    1 row created.
    SQL> commit
      2  /
    Commit complete.
    SQL> set long 10000
    SQL> --
    SQL> select * from xml_load
      2  /
    SYS_NC_ROWINFO$
    <person employee_id="1">
      <first_name>mark</first_name>
      <last_name>drake</last_name>
      <birth_day>2006-01-31</birth_day>
    </person>
    <person employee_id="2">
      <first_name>barney</first_name>
      <last_name>rubble</last_name>
      <birth_day>2006-01-31</birth_day>
      <address>Bedrock</address>
    </person>
    SQL> update XML_LOAD
      2     set object_value = insertChildXML
      3                        (
      4                          object_value,
      5                          '/person',
      6                          'address',
      7                          xmltype('<address/>')
      8                        )
      9   where existsNode(object_value,'/person/address') = 0
    10  /
    1 row updated.
    SQL> commit
      2  /
    Commit complete.
    SQL> select * from xml_load
      2  /
    SYS_NC_ROWINFO$
    <person employee_id="1">
      <first_name>mark</first_name>
      <last_name>drake</last_name>
      <birth_day>2006-01-31</birth_day>
      <address/>
    </person>
    <person employee_id="2">
      <first_name>barney</first_name>
      <last_name>rubble</last_name>
      <birth_day>2006-01-31</birth_day>
      <address>Bedrock</address>
    </person>

  • Problem with boolean attribute of JSP tag

    Hi,
    I've being trying to use a custom JSP tag, which has a boolean attribute, declared in the TLD as follows:
    <attribute>
    <name>checked</name>
    <required>false</required>
    <rtexprvalue>true</rtexprvalue>
    <type>boolean</type>
    </attribute>
    The JSP code snippet is:
    <ui:check checked="<%= myBean.isChecked() %>"/>
    where myBean.isChecked() returns a boolean value (primitive type).
    It works fine on some web containers, but it causes a JSP compilation error on Oracle9iAS 9.0.3 Java Edition, which looks like the following:
    Method toBoolean(boolean) not found in class test. _jsp_taghandler_57.setChecked( OracleJspRuntime.toBooleanObject( toBoolean( myBean.isChecked())));
    After decompiling the container's JSP parser, I found what I think it's a bug. The java class generated by the JSP parser does not define a toBoolean method, and neither do its superclasses. The method is defined on the OracleJspRuntime class! I think the correct code would have to be something like:
    OracleJspRuntime.toBooleanObject(OracleJspRuntime.toBoolean(...))
    If I'm correct, then the "convertExpression" method of the "oracle.jsp.parse.JspUtils" class must be changed, because it outputs such wrong code for not just boolean types, but for all the primitive types.
    So, has anyone ever faced this problem before? Does it have a workaround, or a patch? Is it included on the bug fixes for the 9.0.4 release?
    Thanks!

    Instead of:
    out.println("<body onload ="+strAlert+">");
    Try this:
    out.println("<body onload =\""+strAlert+\"">");
    Add two \" around the alert call.

  • Problem with portlets with XSLT generating dynamic portal compatible links

    Hi,
    We're using XSLT to transform XML data to HTML in a portlet. The problem is that
    the XML contains headlines and we need to create links to the complete article,
    which has to be displayed in the same portlet. How do I create a portal comaptible
    link with XSLT? In the JSP you can use the netui tag library like:
    <netui:anchor action="..">
    link
    <netui:parameter name="id" value="{id}"/>
    </netui:anchor>
    but how can I achieve this with XSLT? We tried generating the xsl with a jsp,
    but this doesn't work since the data entered in the value attribute of the netui:parameter
    tag will be encoded causing the XSL transformer to fail.
    Is there an easy solution to this? Or can XSLT only be used with very simple content?
    Ard

    We're trying to display some news headlines, clicking a headline has to invoke
    an action to display the complete article in the same portlet (using pageflow).
    When displaying the articles we use XSLT like (this is a JSP generating XSLT):
    <?xml version="1.0"?>
    <%@ page contentType="text/x-xslt"%>
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
    <xsl:output method="html"/>
    <xsl:template match="items">
    <xsl:apply-templates select="item"/>
    </xsl:template>
    <xsl:template match="item">
    <nobr>
    <%-- ###### Here we need an action link, with the title as a request parameter
    ###### --%>
    <xsl:value-of select="@title"/>
    </nobr>
    </xsl:template>
    </xsl:stylesheet>
    The XML is like:
    <items>
    <item title="some title"/>
    <item title="some other title"/>
    </items>
    We need to generate a portal compatible link which invokes an action (show_details)
    with the title of the article as a request parameter.
    I know how to do this in a JSP, but since the data is in XML we like to do this
    with XSLT.
    Can you help?
    Subbu Allamaraju <subbuATBeaDOTCom> wrote:
    Could you elaborate (perhaps with some xsl snippet generated by jsp)
    the
    failures you were getting with xslt?
    Subbu
    Ard van der Scheer wrote:
    Hi,
    We're using XSLT to transform XML data to HTML in a portlet. The problemis that
    the XML contains headlines and we need to create links to the completearticle,
    which has to be displayed in the same portlet. How do I create a portalcomaptible
    link with XSLT? In the JSP you can use the netui tag library like:
    <netui:anchor action="..">
    link
    <netui:parameter name="id" value="{id}"/>
    </netui:anchor>
    but how can I achieve this with XSLT? We tried generating the xsl witha jsp,
    but this doesn't work since the data entered in the value attributeof the netui:parameter
    tag will be encoded causing the XSL transformer to fail.
    Is there an easy solution to this? Or can XSLT only be used with verysimple content?
    Ard

  • Problems with XMLP's XSLT engine

    Hi,
    To work around the limitations of the XMLP's builtin
    crosstab support, I have included a XSL file
    like <?import: file:///C:MakeTheTable.xsl?>
    and used <xsl:call-template name="myTable">
    to invoke the template and generate the XSL-FO
    directly. Now the problem is that XMLP's XSLT
    engine gives in some table cells wrong values
    (compared to XML-Spy's XSLT engine and Microsoft
    MSXML 4.0). Is there a way to assign XMLP's XSLT
    engine as "external XSL transformation program" in
    XML Spy?
    I am using the "Preview - PDF" menu in WORD.
    Is there a way to get the generated XSL-FO?
    Thank you,
    Heinz

    Hi,
    I used XMLP's Java API to write a little application that I can use as "external XSL transformation program" for XML Spy. My findings so far:
    - XMLP's FO engine gives correct results, the problem is caused by XMLP's XSLT engine, that creates a bad FO-file.
    - I tried a workaround, replaced a for-each loop with some XPath statements by an for-each-group, group-by, current-group(). I got a different result, but not the correct one :-(
    Our motivation to look at XML Publisher was, that the cross-tab (matrix) support of
    Oracle Reports was not very good, for that what we needed. I am beginning to get the
    impression, that the cross-tab support of XML Publisher is even worse. Of course are
    any positive, optimistic comments appreciated.
    Heinz

  • Problems evaluating cell value when cell refers to different sheet

    Hi,
    I'v read a lot of posts regarding excel parsing, however, none of it
    helped me.
    I'm using POI API to parse my worksheets. The excel files that I need to parse contain references to other excel files or different sheets in the same file.
    Following is the error trace that I'm getting :
    java.lang.IndexOutOfBoundsException: Index: 27, Size: 7
         at java.util.ArrayList.RangeCheck(Unknown Source)
         at java.util.ArrayList.get(Unknown Source)
         at org.apache.poi.hssf.usermodel.HSSFWorkbook.getSheetAt(HSSFWorkbook.java:562)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.internalEvaluate(HSSFFormulaEvaluator.java:374)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.pushRef2DEval(HSSFFormulaEvaluator.java:530)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.internalEvaluate(HSSFFormulaEvaluator.java:339)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.getEvalForCell(HSSFFormulaEvaluator.java:494)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.internalEvaluate(HSSFFormulaEvaluator.java:362)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.pushRef2DEval(HSSFFormulaEvaluator.java:530)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.internalEvaluate(HSSFFormulaEvaluator.java:339)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.pushRef2DEval(HSSFFormulaEvaluator.java:530)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.internalEvaluate(HSSFFormulaEvaluator.java:339)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.pushRef2DEval(HSSFFormulaEvaluator.java:530)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.internalEvaluate(HSSFFormulaEvaluator.java:339)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.pushRef2DEval(HSSFFormulaEvaluator.java:530)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.internalEvaluate(HSSFFormulaEvaluator.java:339)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.pushRef3DEval(HSSFFormulaEvaluator.java:567)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.internalEvaluate(HSSFFormulaEvaluator.java:349)
         at org.apache.poi.hssf.usermodel.HSSFFormulaEvaluator.evaluate(HSSFFormulaEvaluator.java:192)
         at com.qval.parser.ExcelParser.main(ExcelParser.java:54)
    Since I had put the whole source code in my classpath, I was able to debug the code.
    I would like to explain the situation :
    A Workbook object had following attributes as :
    boundsheets (ArrayList) : size 7;
    and
    externSheet (ExternSheetRecord object)
    has 'field_1_number_of_REF_sturcutres' = 67
    and a couple of values in 'field_2_REF_structures' are [  ...,  supbookindex =2
    1stsbindex =2
    lastsbindex =2
    , supbookindex =2
    *1stsbindex* =27
    lastsbindex =27, ...]
    Error comes when while evaluation, sheets at index 27 (using, 1stsbindex =26 ) is retreived. Since size of boundsheets is only 7, we get an IndexOutOfBoundsException.
    I wanted to ask, is it the problem with the Excel that I'm using?
    And, Is there any workaround of parsing using the same Excel file?
    Thanks,
    igitz

    use getDateCellValue() to get the java Date value and format it yourself.

  • Problem With Booleans and Threads

    Since using the .stop() and .resume() properties of a thread are dangerous, I resorted to using Booleans....
    I can get it to stop just fine by setting "keepGoing" to false. That works...
    But when I set the boolean to true... nothing happens. I think the while loop is broken when I set it to false and can't be fixed when the boolean is set back to true.
    There's some deep process I'm not getting with while loops and/or threads.
    Thanks for any help. The first segment of code is what's wrong. Post if it would help to see the rest.
    class startUpdatingThread extends Thread {
          public void run() {
              System.out.println("THREAD STARTING TO RUN!");
            while (keepGoing == true) {
                if (keepGoing == true) {
                Long nextGoAbout = imgTime + 5000;//five seconds more
                if ( ((nextGoAbout - connection.getDate()) < 10000) ) {
                    getnewPicture();
                    imgCanvas.repaint();
    }

    Still a missing }, and you'll still fall out the end of the thread. Something like this:
    class StartUpdatingThread extends Thread
         private volatile boolean     keepGoing = true;
         public void run()
              System.out.println("THREAD STARTING TO RUN!");
              for (;;)
                   synchronized (this)
                        while (!keepGoing)
                             try
                                  this.wait();
                             catch (InterruptedException exc)
                   Long nextGoAbout = imgTime + 5000;//five seconds more
                   if ( ( (nextGoAbout - connection.getDate()) < 10000) )
                        getnewPicture();
                        imgCanvas.repaint();
         public void pause()
              this.keepGoing = false;
         public synchronized void unpause()
              this.keepGoing = true;
              notifyAll();
    }//<--end of StartUpdatingThread()

  • Problem in Call transformation - xslt program

    Hi Experts,
    For the below XML file i have declared the XSLT Program  as described.
    i am not able to get the data into Internal table.
    Could you pls help me in where am i going wrong?
    Is it XSLT declaration or what?
    Data declarations
    TYPES: BEGIN OF TY_BH,
            RECORDTYPE(02), " Record Type
            DOCTYPE(02),      " Document type
            REFERENCE(16),      " Reference Document Number
            DOCUMENTDATE(08),      " Document Date in Document
            POSTINGDATE(08),      " Posting Date in the Document
            COMPANYCODE(04),      " Company Code
            CURRENCY(03),      " Currency Key
            EXCHANGERATE(08),      " Exchange rate
            PARK(01),  " Park document
            ITEMNUMBER(03), " Number of line item
           END OF TY_BH,
           BEGIN OF TY_HH,
             RECORDTYPE(02), " Record Type
             SOURCE(04),
             DESTINATION(04),
             TIMESTAMP(14),
           END OF TY_HH,
           BEGIN OF TY_TT,
             RECORDTYPE(02),
             TOTALRECORDS(10) TYPE N,
             TOTALVALUE(16),
           END OF TY_TT.
    TYPES: BEGIN OF TY_BL,
             RECORDTYPE(02),
             REFERENCE(16),
             REFLINEITEM(03),
             ACCTTYPE(01),
             DRCRINDICATOR(01),
             ACCOUNT(10),
             AMOUNT(13),
             VENDORNAME1(40),
             VENDORNAME2(40),
             VENDORNAME3(40),
             VENDORNAME4(40),
             STREET(40),
             CITY(40),
             POSTALCODE(10),
             COUNTRY(02),
             CONTACTPERSON(10),
             ALTERNATEPAYEECODE(10),
             ALTERNATEPAYEENAME1(40),
             ALTERNATEPAYEENAME2(40),
             ALTERNATEPAYEENAME3(40),
             PAYMENTTERMS(04),
             BASELINEDATE(08),
             PAYMENTMETHODS(01),
             ALLOCATION(18),
             LINEITEMTEXT(50),
             TAXCODE(02),
             TAXAMOUNT(13),
             WHTAXCODE(02),
             WHTAXBASE(13),
             FUND(10),
             FUNDCENTER(16),
             COSTCENTER(10),
             INTERNALORDER(12),
             TAXAUTOMATICALLY(01),
             SPECIALGLINDICATOR(01),
           END OF TY_BL.
    DATA: GT_BH     TYPE STANDARD TABLE OF TY_BH,
          GS_BH     TYPE TY_BH,
          GT_BL     TYPE STANDARD TABLE OF TY_BL,
          GS_BL     TYPE TY_BL,
          GT_HH     TYPE STANDARD TABLE OF TY_HH,
          GS_HH     TYPE TY_HH,
          GT_TT     TYPE STANDARD TABLE OF TY_TT,
          GS_TT     TYPE TY_TT.
    DATA: GT_RESULT_XML5 TYPE ABAP_TRANS_RESBIND_TAB,
          GS_RESULT_XML5 TYPE ABAP_TRANS_RESBIND.
    DATA: GS_RIF_EX     TYPE REF TO CX_ROOT,
          GS_VAR_TEXT   TYPE STRING.
    DATA: BEGIN OF GT_XML,
             HH TYPE TY_HH,
             BH LIKE TABLE OF GT_BH,
             BL LIKE TABLE OF GT_BL,
             TT TYPE TY_TT,
           END OF GT_XML.
    DATA: GT_ITAB       TYPE STANDARD TABLE OF CHAR2048,
          GS_ITAB TYPE CHAR2048.
    I have the below file read into internal table GT_ITAB.
    XML File
    <?xml version="1.0" encoding="utf-8"?>
    <ABCInbound xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="C:\XYZSchema\ABCInbound.xsd">
    <HH>
    <RecordType>HH</RecordType>
    <Source>ABC</Source>
    <Destination>XYZ</Destination>
    <TimeStamp>20050909220546</TimeStamp>
    </HH>
    <BH>
    <RecordType>BH</RecordType>
    <DocType>AB</DocType>
    <Reference>2205516125</Reference>
    <DocumentDate>20080909</DocumentDate>
    <PostingDate></PostingDate>
    <CompanyCode>ABC</CompanyCode>
    <Currency>INR</Currency>
    <ExchangeRate>1.0000</ExchangeRate>
    <Park></Park>
    <ItemNumber>2</ItemNumber>
    </BH>
    <BL>
    <RecordType>BL</RecordType>
    <Reference>2205516125</Reference>
    <RefLineItem>1</RefLineItem>
    <AcctType>K</AcctType>
    <DrCrIndicator>H</DrCrIndicator>
    <Account>01000003</Account>
    <Amount>364.00</Amount>
    <VendorName-1>TOM &amp; JERRY IS MY</VendorName-1>
    <VendorName-2> NAME TO BE PAID</VendorName-2>
    <VendorName-3>1987566Z</VendorName-3>
    <VendorName-4>22</VendorName-4>
    <Street>UCX STREET</Street>
    <City>ROAD 4</City>
    <PostalCode>515004</PostalCode>
    <Country>IND</Country>
    <ContactPerson></ContactPerson>
    <AlternatePayeeCode></AlternatePayeeCode>
    <AlternatePayeeName-1></AlternatePayeeName-1>
    <AlternatePayeeName-2></AlternatePayeeName-2>
    <AlternatePayeeName-3></AlternatePayeeName-3>
    <PaymentTerms></PaymentTerms>
    <BaselineDate></BaselineDate>
    <PaymentMethods></PaymentMethods>
    <Allocation></Allocation>
    <LineItemText>item text</LineItemText>
    <TaxCode></TaxCode>
    <TaxAmount>0.00</TaxAmount>
    <WHTaxCode></WHTaxCode>
    <WHTaxbase>0.00</WHTaxbase>
    <Fund></Fund>
    <FundCenter></FundCenter>
    <CostCenter></CostCenter>
    <InternalOrder></InternalOrder>
    <TaxAutomatically></TaxAutomatically>
    <SpecialGLIndicator></SpecialGLIndicator>
    </BL>
    <TT>
    <RecordType>TT</RecordType>
    <TotalRecords>1</TotalRecords>
    <TotalValue>222</TotalValue>
    </TT>
    </ABCInbound>
    Call transformation as below
    GET REFERENCE OF GT_XML INTO GS_RESULT_XML5-VALUE.
    GS_RESULT_XML5-NAME = 'IABC'.
    APPEND GS_RESULT_XML5 TO GT_RESULT_XML5.
    TRY.
        CALL TRANSFORMATION Z_XML_TO_ABAP5
        SOURCE XML GT_ITAB
        RESULT (GT_RESULT_XML5).
      CATCH CX_ROOT INTO GS_RIF_EX.
        GS_VAR_TEXT = GS_RIF_EX->GET_TEXT( ).
        MESSAGE GS_VAR_TEXT TYPE 'E'.
    ENDTRY.
    WHEN I CHECK GT_XML its initial.
    XSLT Program Z_XML_TO_ABAP5 is like below.
    Pls let me know if my xslt declaration is wrong.
    <xsl:transform xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
      <xsl:output encoding="iso-8859-1" indent="yes" method="xml" version="1.0"/>
      <xsl:strip-space elements="*"/>
      <xsl:template match="/">
        <asx:abap xmlns:asx="http://www.sap.com/abapxml" version="1.0">
          <asx:values>
            <IABC>
              <xsl:apply-templates select="//ABCInbound"/>
            </IABC>
          </asx:values>
        </asx:abap>
      </xsl:template>
      <xsl:template match="ABCINBOUND">
        <item>
          <RECORDTYPE>
            <xsl:value-of select="RecordType"/>
          </RECORDTYPE>
          <SOURCE>
            <xsl:value-of select="Source"/>
          </SOURCE>
          <DESTINATION>
            <xsl:value-of select="Destination"/>
          </DESTINATION>
          <TIMESTAMP>
            <xsl:value-of select="TimeStamp"/>
          </TIMESTAMP>
          <RECORDTYPE>
            <xsl:value-of select="RecordType"/>
          </RECORDTYPE>
          <DOCTYPE>
            <xsl:value-of select="DocType"/>
          </DOCTYPE>
          <REFERENCE>
            <xsl:value-of select="Reference"/>
          </REFERENCE>
          <DOCUMENTDATE>
            <xsl:value-of select="DocumentDate"/>
          </DOCUMENTDATE>
          <POSTINGDATE>
            <xsl:value-of select="PostingDate"/>
          </POSTINGDATE>
          <COMPANYCODE>
            <xsl:value-of select="CompanyCode"/>
          </COMPANYCODE>
          <CURRENCY>
            <xsl:value-of select="Currency"/>
          </CURRENCY>
          <EXCHANGERATE>
            <xsl:value-of select="ExchangeRate"/>
          </EXCHANGERATE>
          <PARK>
            <xsl:value-of select="Park"/>
          </PARK>
          <ITEMNUMBER>
            <xsl:value-of select="ItemNumber"/>
          </ITEMNUMBER>
          <RECORDTYPE>
            <xsl:value-of select="RecordType"/>
          </RECORDTYPE>
          <REFERENCE>
            <xsl:value-of select="Reference"/>
          </REFERENCE>
          <REFLINEITEM>
            <xsl:value-of select="RefLineItem"/>
          </REFLINEITEM>
          <ACCTTYPE>
            <xsl:value-of select="AcctType"/>
          </ACCTTYPE>
          <DRCRINDICATOR>
            <xsl:value-of select="DrCrIndicator"/>
          </DRCRINDICATOR>
          <ACCOUNT>
            <xsl:value-of select="Account"/>
          </ACCOUNT>
          <AMOUNT>
            <xsl:value-of select="Amount"/>
          </AMOUNT>
          <VENDORNAME1>
            <xsl:value-of select="VendorName-1"/>
          </VENDORNAME1>
          <VENDORNAME2>
            <xsl:value-of select="VendorName-2"/>
          </VENDORNAME2>
          <VENDORNAME3>
            <xsl:value-of select="VendorName-3"/>
          </VENDORNAME3>
          <VENDORNAME4>
            <xsl:value-of select="VendorName-4"/>
          </VENDORNAME4>
          <STREET>
            <xsl:value-of select="Street"/>
          </STREET>
          <CITY>
            <xsl:value-of select="City"/>
          </CITY>
          <POSTALCODE>
            <xsl:value-of select="PostalCode"/>
          </POSTALCODE>
          <COUNTRY>
            <xsl:value-of select="Country"/>
          </COUNTRY>
          <CONTACTPERSON>
            <xsl:value-of select="ContactPerson"/>
          </CONTACTPERSON>
          <ALTERNATEPAYEECODE>
            <xsl:value-of select="AlternatePayeeCode"/>
          </ALTERNATEPAYEECODE>
          <ALTERNATEPAYEENAME1>
            <xsl:value-of select="AlternatePayeeName1"/>
          </ALTERNATEPAYEENAME1>
          <ALTERNATEPAYEENAME2>
            <xsl:value-of select="AlternatePayeeName2"/>
          </ALTERNATEPAYEENAME2>
          <ALTERNATEPAYEENAME3>
            <xsl:value-of select="AlternatePayeeName3"/>
          </ALTERNATEPAYEENAME3>
          <PAYMENTTERMS>
            <xsl:value-of select="PaymentTerms"/>
          </PAYMENTTERMS>
          <BASELINEDATE>
            <xsl:value-of select="BaselineDate"/>
          </BASELINEDATE>
          <PAYMENTMETHODS>
            <xsl:value-of select="PaymentMethods"/>
          </PAYMENTMETHODS>
          <ALLOCATION>
            <xsl:value-of select="Allocation"/>
          </ALLOCATION>
          <LINEITEMTEXT>
            <xsl:value-of select="LineItemText"/>
          </LINEITEMTEXT>
          <TAXCODE>
            <xsl:value-of select="TaxCode"/>
          </TAXCODE>
          <TAXAMOUNT>
            <xsl:value-of select="TaxAmount"/>
          </TAXAMOUNT>
          <WHTAXCODE>
            <xsl:value-of select="WHTaxCode"/>
          </WHTAXCODE>
          <WHTAXBASE>
            <xsl:value-of select="WHTaxbase"/>
          </WHTAXBASE>
          <FUND>
            <xsl:value-of select="Fund"/>
          </FUND>
          <FUNDCENTER>
            <xsl:value-of select="FundCenter"/>
          </FUNDCENTER>
          <COSTCENTER>
            <xsl:value-of select="CostCenter"/>
          </COSTCENTER>
          <INTERNALORDER>
            <xsl:value-of select="InternalOrder"/>
          </INTERNALORDER>
          <TAXAUTOMATICALLY>
            <xsl:value-of select="TaxAutomatically"/>
          </TAXAUTOMATICALLY>
          <SPECIALGLINDICATOR>
            <xsl:value-of select="SpecialGLIndicator"/>
          </SPECIALGLINDICATOR>
          <RECORDTYPE>
            <xsl:value-of select="RecordType"/>
          </RECORDTYPE>
          <TOTALRECORDS>
            <xsl:value-of select="TotalRecords"/>
          </TOTALRECORDS>
          <TOTALVALUE>
            <xsl:value-of select="TotalValue"/>
          </TOTALVALUE>
        </item>
      </xsl:template>
    </xsl:transform>
    I able to get if declare only for BL and BH in separate xslt transformations.
    Regards,
    Simha

    Hello Mithun,
    when you use the call transformation statement you have to specifiy the xslt transformation used. As a first step you usually use the transformation with the name ID. This is a special transformation for making the asXML representation of abap data. Unfortunately if you look into this transformation you find the following:
    <xsl:transform version="1.0"
      xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    >
    <xsl:strip-space elements="*"/>
    <xsl:template match="/">
      <xsl:copy-of select="."/>
    </xsl:template>
    </xsl:transform>
    If I remember correctly when you use another transformation this will first call the ID transformation and after this the specified one. So it should not be possible to just copy ID transformation and remove the line. I'll have to think again how to avoid the behaviour.
    Best Regards
    Roman

  • Problem with XML and XSLT, help...

    Okay, I have this XML doc (called stocks.xml):
    <?xml:stylesheet type="text/xsl" href="stocks.xsl" version="1.0" encoding="UTF-8"?>
    <portfolio>
    <stock>
    <symbol> SUNW </symbol>
    <name> Sun Microsystem </name>
    <price> 12.95 </price>
    </stock>
    <stock>
    <symbol> HPW </symbol>
    <name> Hewlet Packard </name>
    <price> 53.50 </price>
    </portfolio>
    And I have this XSLT doc (called stocks.xls):
    ?xml version="1.0"?>
    <xsl:stylesheet version="1.0" xmlns:xls="http://www.w3.org/TR/WD-xsl">
    <xsl:template match="/">
    <html>
    <head>
    <title> Stocks </title>
    <body bgcolor="#ffffcc">
    <xsl:apply-template />
    </body>
    </head>
    </html>
    </xsl template>
    <xsl:template match="portfolio">
    <table border="2">
    <tr>
    <th> Stock Symbol </th><th> Company Name </th><th> Price </th>
    </tr>
    <xsl:for-each select="stock">
    <tr>
    <td>
    <i><xsl:value-of select="symbol" /></i>
    </td>
    <td>
    <xsl:value-of select="price" />
    </td>
    </tr>
    </xsl:for-each>
    </table>
    </xsl template>
    </stylesheet>
    When I try to retrieve the stocks.xml document with
    IE, the browser said, there is an error on line 2, can not
    recognize xsl:
    The XML page cannot be displayed
    Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.
    Reference to undeclared namespace prefix: 'xsl'. Error processing resource 'http://localhost:8080/examples/jsp/stocks/stocks.xsl'. Line 2, Position 71
    <xsl:stylesheet version="1.0" xmlns:xls="http://www.w3.org/TR/WD-xsl">
    I just follow this from an example of XML tutorial.
    Please help, what is it that I miss? Seems everything
    I have is okay....??
    Thanks,
    Ted.

    Thanks you all!
    You have spotted that mistyped.
    However, turns out Internet Browser that I have does not permit the use of XSL. After I fixed the file, I got this
    message:
    The XML page cannot be displayed
    Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.
    Keyword xsl:apply-template may not be used here.
    Oh well...
    Anybody knows, if IE can or can not be used to view the
    XML that reference XSL??
    Thanks,
    Ted.

  • Problem in working with xslt filter

    Hi All,
    I have created some XSLT filters to display the XML file as the HTML. It was working fine before. but suddenly there's an error.
    After applying the XSLT filter to the content. When i clicked on the content to see the output it is throwing " 500 INTERNAL SERVER ERROR -- Contact System Administrator ".
    I tried to find the error in the log : Below is the log for the same::
    Error##Plain###Cannot instantiate user <anonymous>#
    #1.5#0011254E4B6500460000001F00001C0800044066D387C4F6#1196710286640#com.sapportals.wcm.WcmException#sap.com/irj#com.sapportals.wcm.WcmException.WcmException(118)#IntranetApprover#35##idbportst_TST_3777850#IntranetApprover#01477b00a1d511dc8c660011254e4b65#SAPEngine_Application_Threadimpl:3_11##0#0#Error##Plain###Error downloading from URL: wcm://etc/filter/idbfilters/author.xsl, No user in context com.sapportals.wcm.util.urlcontentaccess.URLContentAccessException: Error downloading from URL: wcm://etc/filter/idbfilters/author.xsl, No user in context
    at com.sapportals.wcm.util.urlcontentaccess.URLContentAccess.readContent(URLContentAccess.java:263)
    at com.sapportals.wcm.util.urlcontentaccess.URLContentAccess.readContent(URLContentAccess.java:281)
    at com.sapportals.wcm.service.pipeline.producer.ProducerFromUrl.getData(ProducerFromUrl.java:54)
    at com.sapportals.wcm.service.pipeline.processor.XSLTProcessor.process(XSLTProcessor.java:141)
    at com.sapportals.wcm.service.pipeline.Pipeline.handle(Pipeline.java:269)
    at com.sapportals.wcm.service.pipeline.XSLTPipeline.handle(XSLTPipeline.java:118)
    at com.sapportals.wcm.service.pipeline.XSLTPipeline.handle(XSLTPipeline.java:134)
    at com.sapportals.wcm.repository.filter.xslt.XsltFilter.getContent(XsltFilter.java:150)
    at com.sapportals.wcm.repository.filter.xslt.XsltFilter.getInputStream(XsltFilter.java:90)
    at com.sapportals.wcm.repository.runtime.CmFilterHandler$VaryingContentWrapper1.getInputStream(CmFilterHandler.java:1050)
    at com.sapportals.wcm.repository.ContentImpl.getInputStream(ContentImpl.java:113)
    at com.sapportals.wcm.repository.ContentImpl.getInputStream(ContentImpl.java:132)
    at com.sapportals.wcm.protocol.webdav.server.WDGetHandler.internalHandle(WDGetHandler.java:364)
    at com.sapportals.wcm.protocol.webdav.server.WDGetHandler.handle(WDGetHandler.java:253)
    at com.sapportals.wcm.protocol.webdav.server.WDServlet.doGet(WDServlet.java:777)
    at com.sapportals.wcm.protocol.webdav.server.WDServlet.service(WDServlet.java:458)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.sapportals.wcm.portal.proxy.PCProxyServlet.service(PCProxyServlet.java:331)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at
    can anyone please help me in this regard, it is very urgent.
    Thanks in advance,
    Kavitha.

    unaswered

  • Problem with boolean type in Informix via ODBC

    Hello,
    I'm connecting to an Informix database from an Oracle database via the ODBC Gateway. The connection works fine.
    However, when I select a boolean type column from a table in the Informix database, nothing is returned and I get the following error:
    SQL> select "stat" from bt@informix;
    ERROR:
    ORA-28500: connection from ORACLE to a non-Oracle system returned this message:
    [Informix][Informix ODBC Driver]Restricted data type attribute violation.
    {07006,NativeErr = -11013}
    ORA-02063: preceding 2 lines from INFORMIX
    no rows selected
    Selecting a boolean type column with isql works fine. Other column types work from Oracle.
    Can anyone help me resolve this issue? Please find configuration details and traces below.
    Software stack:
    Informix Database: Enterprise Edition 12.10 for Linux x86_64
    Informix ODBC driver: Informix Client SDK Developer Edition 4.10 for Linux 64-bit
    Oracle Database: Enterprise Edition 11.2.0.1.0 64-bit (Oracle Linux 6.6 64-bit)
    UnixODBC: 2.3.2 x86_64
    odbcinst.ini:
    [Informix]
    Driver=/opt/IBM/informix/lib/cli/libifcli.so
    Setup=/opt/IBM/informix/lib/cli/libifcli.so
    APILevel=1
    ConnectFunctions=YYY
    DriverODBCVer=03.51
    FileUsage=0
    SQLLevel=1
    smProcessPerConnect=Y
    [ODBC]
    TraceFile=/tmp/odbc.log
    Trace = Yes
    odbc.ini:
    [ol_informix1210]
    Driver=Informix
    Description=Test connection
    Database=sysutils
    LogonID=informix
    pwd=informix
    Servername=ol_informix1210
    CursorBehavior=0
    DB_LOCALE=en_us.8859-1
    TRANSLATIONDLL=/opt/IBM/informix/lib/esql/igo4a304.so
    [ODBC]
    UNICODE=UCS-2
    ; Trace file Section
    Trace=1
    TraceFile=/tmp/odbctrace.out
    InstallDir=/opt/IBM/informix
    TRACEDLL=idmrs09a.so
    Oracle Gateway init.ora:
    HS_FDS_CONNECT_INFO=ol_informix1210
    HS_FDS_SHAREABLE_NAME=/usr/local/lib/libodbc.so
    HS_FDS_TRACE_LEVEL=debug
    HS_LANGUAGE=AMERICAN_AMERICA.WE8ISO8859P1
    Oracle Gateway trace:
    Entered hgoftch, cursor id 1 at 2015/04/14-12:22:03
    hgoftch, line 130: Printing hoada @ 0x2007fe0
    MAX:1, ACTUAL:1, BRC:100, WHT=5 (SELECT_LIST)
    hoadaMOD bit-values found (0x20:NEGATIVE_HOADADTY)
    DTY     NULL-OK  LEN  MAXBUFLEN   PR/SC  CST IND MOD NAME
    -7 BIT Y          1          1   0/  0    0   0  20 stat
    Performing delayed open.
    SQLBindCol: column 1, cdatatype: -28, bflsz: 1
    Entered hgopoer at 2015/04/14-12:22:03
    hgopoer, line 233: got native error -11013 and sqlstate 07006; message follows...
    [Informix][Informix ODBC Driver]Restricted data type attribute violation. {07006,NativeErr = -11013}
    Exiting hgopoer, rc=0 at 2015/04/14-12:22:03
    hgoftch, line 730: calling SQLFetch got sqlstate 07006
    0 rows fetched
    Exiting hgoftch, rc=28500 at 2015/04/14-12:22:03 with error ptr FILE:hgoftch.c LINE:730 FUNCTION:hgoftch() ID:Fetch resultset data
    ODBC trace:
    [ODBC][11041][1429005970.973443][SQLPrepare.c][196]
                    Entry:
                            Statement = 0x276ecb0
                            SQL = [SELECT A1. stat  FROM  BT  A1][length = 29]
    [ODBC][11041][1429005970.973914][SQLPrepare.c][371]
                    Exit:[SQL_SUCCESS]
    [ODBC][11041][1429005970.973940][SQLNumResultCols.c][156]
                    Entry:
                            Statement = 0x276ecb0
                            Column Count = 0x26f5868
    [ODBC][11041][1429005970.973970][SQLNumResultCols.c][248]
                    Exit:[SQL_SUCCESS]
                            Count = 0x26f5868 -> 1
    [ODBC][11041][1429005970.974097][SQLDescribeCol.c][247]
                    Entry:
                            Statement = 0x276ecb0
                            Column Number = 1
                            Column Name = 0x7fffc3ff2d90
                            Buffer Length = 31
                            Name Length = 0x7fffc3ff2ed4
                            Data Type = 0x7fffc3ff2ed8
                            Column Size = 0x7fffc3ff2e70
                            Decimal Digits = 0x7fffc3ff2edc
                            Nullable = 0x7fffc3ff2ee0
    [ODBC][11041][1429005970.974140][SQLDescribeCol.c][501]
                   Exit:[SQL_SUCCESS]               
                            Column Name = [stat]               
                            Data Type = 0x7fffc3ff2ed8 -> -7               
                            Column Size = 0x7fffc3ff2e70 -> 1               
                            Decimal Digits = 0x7fffc3ff2edc -> 0               
                            Nullable = 0x7fffc3ff2ee0 -> 1
    [ODBC][11041][1429005970.974192][SQLSetStmtAttr.c][265]
                    Entry:
                            Statement = 0x276ecb0
                            Attribute = SQL_ATTR_ROW_ARRAY_SIZE
                            Value = 0x64
                            StrLen = 0
    [ODBC][11041][1429005970.974218][SQLSetStmtAttr.c][925]
                    Exit:[SQL_SUCCESS]
    [ODBC][11041][1429005970.974230][SQLSetStmtAttr.c][265]
                    Entry:
                            Statement = 0x276ecb0
                            Attribute = SQL_ATTR_ROW_BIND_TYPE
                            Value = (nil)
                            StrLen = -5
    [ODBC][11041][1429005970.974249][SQLSetStmtAttr.c][925]
                    Exit:[SQL_SUCCESS]
    [ODBC][11041][1429005970.974837][SQLExecute.c][187]
                    Entry:
                            Statement = 0x276ecb0
    [ODBC][11041][1429005970.975231][SQLExecute.c][348]
                    Exit:[SQL_SUCCESS]
    [ODBC][11041][1429005970.975255][SQLSetStmtAttr.c][265]
                    Entry:
                            Statement = 0x276ecb0
                            Attribute = SQL_ATTR_ROW_STATUS_PTR
                            Value = 0x27f5b78
                            StrLen = -4
    [ODBC][11041][1429005970.975280][SQLSetStmtAttr.c][925]
                    Exit:[SQL_SUCCESS]
    [ODBC][11041][1429005970.975291][SQLSetStmtAttr.c][265]
                    Entry:
                            Statement = 0x276ecb0
                            Attribute = SQL_ATTR_ROWS_FETCHED_PTR
                            Value = 0x26f5850
                            StrLen = -4
    [ODBC][11041][1429005970.975311][SQLSetStmtAttr.c][925]
                    Exit:[SQL_SUCCESS]
    [ODBC][11041][1429005970.975326][SQLBindCol.c][236]
                    Entry:
                            Statement = 0x276ecb0
                            Column Number = 1
                            Target Type = -28 SQL_C_UTINYINT
                            Target Value = 0x27f5af8
                            Buffer Length = 1
                            StrLen Or Ind = 0x27f5eb8
    [ODBC][11041][1429005970.975349][SQLBindCol.c][341]
                    Exit:[SQL_SUCCESS]
    [ODBC][11041][1429005970.975367][SQLFetch.c][162]
                    Entry:
                            Statement = 0x276ecb0
    [ODBC][11041][1429005970.975455][SQLFetch.c][348]
                    Exit:[SQL_ERROR]
                    DIAG [07006] [Informix][Informix ODBC Driver]Restricted data type attribute violation.
    [ODBC][11041][1429005970.975574][SQLGetDiagRec.c][758]
                   Entry:
                            Statement = 0x276ecb0
                            Rec Number = 1
                            SQLState = 0x7fffc3ff2e20
                            Native = 0x7fffc3ff2c14
                            Message Text = 0x7fffc3ff2c20
                            Buffer Length = 510
                            Text Len Ptr = 0x7fffc3ff2e70
    [ODBC][11041][1429005970.975615][SQLGetDiagRec.c][795]
                    Exit:[SQL_SUCCESS]
                            SQLState = 07006
                            Native = 0x7fffc3ff2c14 -> -11013
                            Message Text = [[Informix][Informix ODBC Driver]Restricted data type attribute violation.]
    [ODBC][11041][1429005970.975642][SQLGetDiagRec.c][758]
                    Entry:
                            Statement = 0x276ecb0
                            Rec Number = 2
                            SQLState = 0x7fffc3ff2e20
                            Native = 0x7fffc3ff2c14
                            Message Text = 0x7fffc3ff2c20
                         Message Text = 0x7fffc3ff2c20
                            Buffer Length = 510
                            Text Len Ptr = 0x7fffc3ff2e70
    [ODBC][11041][1429005970.975667][SQLGetDiagRec.c][795]
                    Exit:[SQL_NO_DATA]

    Here are my findings after consulting the unixODBC mailing list and the IBM documentation.
    There are several levels of data types at play here: native Informix SQL types, Informix ODBC driver SQL types and Informix ODBC driver C types (as well as standard C types).
    According to the Informix documentation (http://www-01.ibm.com/support/knowledgecenter/SSGU8G_11.70.0/com.ibm.odbc.doc/ids_odbc_108.htm), the ODBC driver SQL type for the native boolean type is SQL_BIT.
    The traces show that the ODBC SQL type is SQL_BIT (type code -7) and that this should be converted into the SQL_C_UTINYINT ODBC C type (type code -28).
    Oracle ODBC Gateway trace:
    DTY    NULL-OK  LEN  MAXBUFLEN  PR/SC  CST IND MOD NAME
    -7 BIT Y          1          1  0/  0    0  0  20 stat
    Performing delayed open.
    SQLBindCol: column 1, cdatatype: -28, bflsz: 1
    unixODBC trace:
    ODBC][11041][1429005970.975326][SQLBindCol.c][236]
                    Entry:
                            Statement = 0x276ecb0
                            Column Number = 1
                           Target Type = -28 SQL_C_UTINYINT
                            Target Value = 0x27f5af8
                            Buffer Length = 1
                            StrLen Or Ind = 0x27f5eb8
    [ODBC][11041][1429005970.975349][SQLBindCol.c][341]
    Oracle tries to bind the SQL_BIT type column to a buffer of SQL_C_UTINYINT type, which requires a conversion from SQL_BIT to SQL_C_UTINYINT  that is apparently not supported by the Informix ODBC Driver.
    According to the documentation (http://www-01.ibm.com/support/knowledgecenter/SSGU8G_11.70.0/com.ibm.odbc.doc/ids_odbc_108.htm) the Informix ODBC driver can only convert the SQL_BIT ODBC SQL type into SQL_C_BINARY, SQL_C_BIT and SQL_C_CHAR ODBC C types. (The ODBC C types are in turn converted into standard C types, for example the SQL_C_BIT type is converted into UCHAR which is a typedef for the standard C type unsigned char.)
    A possible workaround could be to tell Informix to present boolean as a different ODBC SQL type, for example SQL_CHAR (as it would be possible with PostgreSQL by setting BoolAsCharater=1 in odbc.ini), but Informix only seems to supports the SQL_BIT ODBC SQL type.
    A cumbersome workaround is to use the Gateway's pass-through feature that allows a query to be passed to Informix as is, which in turn allows us to cast the boolean field into a character field:
    SQL> set serveroutput on
    SQL> r
      1  DECLARE
      2    val  VARCHAR2(1);
      3    c    INTEGER;
      4    nr  INTEGER;
      5  BEGIN
      6    c := DBMS_HS_PASSTHROUGH.OPEN_CURSOR@informix;
      7    DBMS_HS_PASSTHROUGH.PARSE@informix(c,'select cast (stat as character) from bt');
      8    LOOP
      9    nr := DBMS_HS_PASSTHROUGH.FETCH_ROW@informix(c);
    10    EXIT WHEN nr = 0;
    11    DBMS_HS_PASSTHROUGH.GET_VALUE@informix(c, 1, val);
    12    DBMS_OUTPUT.PUT_LINE(val);
    13    END LOOP;
    14    DBMS_HS_PASSTHROUGH.CLOSE_CURSOR@informix(c);
    15  END;
    16*
    t
    f
    PL/SQL procedure successfully completed
    Easier solutions are still welcome.

Maybe you are looking for

  • HT204053 Can iTunes Match be associated with another Apple ID?

    I have to Apple ID accounts (although I'm not sure how that happened). I've purchased iTunes Match with one account. Now I'd like to put everything under another existing account to make my life easier. When I try to turn on iTunes Match from that ac

  • The disk can not be read or written to!

    So this is the setup: Latest version of iTunes running on the wifes PowerBook under 10.4.X I'm using a new 4th Gen iPod Nano and I'm trying to sync the iPod to the library. Its gets about 400meg in and then comes up with error 'The disk can not be re

  • IMac 2009 Keeps Crashing

    I have an iMac running Yosemite for some time now.  Just today, it crashed. I have rebooted the computer, and it opens everything, but after about 2 minutes or so once booted up, I get the spinning wheel on all my applications.  I can still drag my w

  • How to Count a Characteristic Occurence?

    Morning, I have Assembly(Material) being displayed as a Row item in my query. My need is to count the number of rows for Assembly in the query. I referred to "How to Count" doc, but that counts every occurence of assembly. Whereas, I need to count an

  • CS5 Crashes on Quit

    Has anyone else seen this and found a solution? Installed CS5 Standard, OS 10.6.3, MacBook Pro 4,1 When first installed, I could not change prefs - as discussed in thread: http://forums.adobe.com/thread/628368?tstart=0 I manually changed permissions.