Hi 

I am done with the entity bean deployment with a little hack.  The minor
problem that I have now is the type-mapping of varbinary datatype in the
database.  I am listing down the database data types and the corresponding
java types below.  I am using Sybase as the database.
--------------------------------------------------------------------
Database Column Bean's variables
--------------------------------------------------------------------
Login (varchar)         myLogin (String)
ClientId (varchar)      myClientId (String)       
Language (char)         myLanguage (String)       
RefCurrency (char)      myCurrency (String)    
BranchCode (char)       myBranchCode (String)     
SessionId (varchar)     mySessionId (String)      
SessionCounter (int)    mySessionCounter (int) 
LastUserData (varchar)  myLastUserData (String)   
StateHandle (varbinary) myStateHandle (byte[])    

Now the problem that I have is the type-mapping of the varbinary datatype.
If I map this to Object, then I am not able to create the bean with null
value for this field.  
When I do that, I get the following error.
Exception in thread "main" javax.ejb.CreateException: Could not create
entity:java.sql.SQLException: JZ0SE: Invalid object type (or null object)
specified for setObject()
Now what I have done is, put some dummy data in this data type (just to
ensure that it is not null).
Could u please tell me what is the exact java data type mapping for this
varbinary sql datatype??

Thanks and Regards
Sumeeth





> -----Original Message-----
> From: Fred Loney [SMTP:[EMAIL PROTECTED]]
> Sent: Thursday, June 21, 2001 12:25 AM
> To:   [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject:      Re: [JBoss-user] entity bean deployment
> 
> Make the following change to the mbean entry in jboss.jcml in your jboss
> config directory (conf/default by default, conf/myapp if started with
> jboss myapp):
> 
> <mbean code="org.jboss.jdbc.JdbcProvider"
> name="DefaultDomain:service=JdbcProvider">
>           <attribute
> name="Drivers">com.sybase.jdbc2.jdbc.SybDriver</attribute>
> </mbean>
> <mbean code="org.jboss.jdbc.XADataSourceLoader"
> name="DefaultDomain:service=XADataSource,name=SybasePool">
>           <attribute name="PoolName">SybasePool</attribute>
>           <attribute
> name="DataSourceClass">org.jboss.pool.jdbc.xa.wrapper.XADataSourceImpl</at
> tribute>
>           <attribute
> name="URL">jdbc:sybase:Tds:db1.hyd.wilco-int.com:1400/STB2LocalData</attri
> bute>
>           <attribute name="JDBCUser">username</attribute>
>           <attribute name="Password">password</attribute>
>           <attribute name="MinSize">5</attribute>
>           <attribute name="MaxSize">15</attribute>
>           <attribute name="GCEnabled">false</attribute>
>           <attribute name="GCMinIdleTime">1200000</attribute>
>           <attribute name="GCInterval">120000</attribute>
>           <attribute name="InvalidateOnError">false</attribute>
>           <attribute name="TimestampUsed">false</attribute>
>           <attribute name="Blocking">true</attribute>
>           <attribute name="LoggingEnabled">false</attribute>
>           <attribute name="IdleTimeoutEnabled">false</attribute>
>           <attribute name="IdleTimeout">1800000</attribute>
>           <attribute name="MaxIdleTimeoutPercent">1.0</attribute>
> </mbean>
> 
> Sumeeth Chinni wrote:
> 
> > Hi
> >
> > I am currently working in a webbased project where we are trying to give
> a
> > web front-end for a integrated banking system application running in a
> > mainframe system.  We are using JSP for the presentation-tier and EJB
> for
> > user authentication, session management, and routing the requests from
> > presentation-tier to the mainframe application.  We have successfully
> > deployed the whole setup (JSP and EJB) in weblogic 5.1 and 6.0, but due
> to
> > jboss's simplicity, we are trying to move the setup from weblogic to
> JBoss.
> > We have success configuring the sessionbeans in JBoss.  But struck up
> while
> > configuring the entity bean.  Could anyone please guide us the exact
> > procedure for configuring the datasource,connection pool for the
> database
> > connections and configuring this for the entity bean.  Due to time
> > constraints, I am not at the liberty to go through the doucmentation and
> > examples.
> > The database details are as follows.
> >          DB
> URL=jdbc:sybase:Tds:db1.hyd.wilco-int.com:1400/STB2LocalData,
> >          DRIVER=com.sybase.jdbc2.jdbc.SybDriver,
> >          initialCapacity=5,
> >          maxCapacity=15,
> >          capacityIncrement=3,
> >          props=user=<username>;password=<password>
> >
> > Any immediate help in this regard is strongly appreciated.
> 
> --
> Fred Loney
> Spirited Software, Inc.
> [EMAIL PROTECTED]
> 

_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to