Type mapping in JBoss for Oracle9i

Discussion in 'Java' started by derHarri, Apr 19, 2007.

  1. derHarri

    derHarri Guest

    Hello,

    i am using Jboss 4.0.4 with EJB2.1 and a Oracle Database.
    In my database there are tables containing CLOB fields.
    The EJB accessing these tables use a "special" jbosscmp-jdbc.xml in
    which i explicitely define the CLOB type for the relevant fields.

    Code:
    <cmp-field>
    <field-name>lsData</field-name>
    <column-name>LSDATA</column-name>
    <jdbc-type>CLOB</jdbc-type>
    <sql-type>CLOB</sql-type>
    </cmp-field>


    That works fine but makes me have to use different jbosscmp-jdbc.xml
    files for different databases (e.g SQLServer).
    Maybe i misunderstood something but i think normaly such type-mapping
    has do be done in standardjbosscmp-jdbc.xml in the conf directory of
    my used server implementation.
    But when i define the CLOB mapping in that file it does not work.

    Code:
    <mapping>
    <java-type>java.lang.String</java-type>
    <jdbc-type>CLOB</jdbc-type>
    <sql-type>CLOB</sql-type>
    </mapping>


    JBoss does not throw neither an exception nor error or warning.
    The accessing method in the bean just returns null such as if the db
    field contains null. I draw the conclusion, that JBoss just has
    problems reading the db data of the CLOB field.

    Can someone explain why my the "global" mapping does not work?
    Maybe i just forgot something else?

    Thanks for your help


    Harri E.
     
    derHarri, Apr 19, 2007
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. dev_cool

    Problems with IIS 5.1 & Oracle9i

    dev_cool, Dec 11, 2005, in forum: ASP .Net
    Replies:
    4
    Views:
    614
    dev_cool
    Dec 14, 2005
  2. news.amnet.net.au
    Replies:
    2
    Views:
    2,106
    Stian
    Oct 3, 2003
  3. Kelly Carrigan

    Connecting Python to Oracle9i on AIX 5.1

    Kelly Carrigan, Oct 20, 2003, in forum: Python
    Replies:
    0
    Views:
    386
    Kelly Carrigan
    Oct 20, 2003
  4. Replies:
    4
    Views:
    331
  5. Jack

    connect asp.net with oracle9i

    Jack, Sep 22, 2006, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    729
Loading...

Share This Page