Re: dbunit-user Digest, Vol 37, Issue 16

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: dbunit-user Digest, Vol 37, Issue 16

Rakesh Gupta-4
Thanks!
 
I looked at org.dbunit.ext.oracle but I do not see any class which has the implementation for the Oracle Object Type support.  An example of an Oracle Type would be:
 

CREATE OR REPLACE TYPE Chapter_T AS OBJECT

( c_no NUMBER,

c_title VARCHAR2(20),

c_page_no NUMBER );
 
 
From what I know, the way the oracle types are handled in Java are by creating a POJO for the Oracle Type and registering it with connection using oracle.sql.STRUCT.
 
Are there any APIs in dbunit to hide the complexity of STRUCT and wrting the unit test for the procedures which has Oracle Types as input or output.
 
Thanks,
Rakesh


 
143 Newman Court
Pennington, NJ - 08534
Ph: 609-730-0651(H) 
      609-356-4333(Cell)
      609-734-5401(W)


--- On Thu, 5/28/09, [hidden email] <[hidden email]> wrote:

From: [hidden email] <[hidden email]>
Subject: dbunit-user Digest, Vol 37, Issue 16
To: [hidden email]
Date: Thursday, May 28, 2009, 8:05 AM

Send dbunit-user mailing list submissions to
    dbunit-user@...

To subscribe or unsubscribe via the World Wide Web, visit
    https://lists.sourceforge.net/lists/listinfo/dbunit-user
or, via email, send a message with subject or body 'help' to
    dbunit-user-request@...

You can reach the person managing the list at
    dbunit-user-owner@...

When replying, please edit your Subject line so it is more specific
than "Re: Contents of dbunit-user digest..."


Today's Topics:

   1. dbunit Question! (Rakesh Gupta)
   2. Re: dbunit Question! (Matthias Gommeringer)


----------------------------------------------------------------------

Message: 1
Date: Wed, 27 May 2009 05:10:50 -0700 (PDT)
From: Rakesh Gupta <rakeshgupta_7@...>
Subject: [dbunit-user] dbunit Question!
To: dbunit-user@...
Message-ID: <763077.1784.qm@...>
Content-Type: text/plain; charset="iso-8859-1"

Hi,
?
I have a very basic question. How does dbunit handles the Oracle Object Types (user defined oracle Types)?in java layer? Can you point me to some sample code?
?
Thanks,
Rakesh


     
-------------- next part --------------
An HTML attachment was scrubbed...

------------------------------

Message: 2
Date: Wed, 27 May 2009 21:35:07 +0200
From: Matthias Gommeringer <Matthias.Gommeringer@...>
Subject: Re: [dbunit-user] dbunit Question!
To: dbunit-user@...
Message-ID: <745866267@...>
Content-Type: text/plain; charset=iso-8859-15

Hi Rakesh,

you can browse the sources at http://dbunit.sourceforge.net/xref/index.html - there have a look at the package "org.dbunit.ext.oracle" which contains all Oracle specific implementation classes.

Regards,
matthias

> -----Urspr?ngliche Nachricht-----
> Von: "Rakesh Gupta" <rakeshgupta_7@...>
> Gesendet: 27.05.09 14:11:34
> An: dbunit-user@...
> Betreff: [dbunit-user] dbunit Question!


> Hi,
>
> I have a very basic question. How does dbunit handles the Oracle
> Object Types (user defined oracle Types) in java layer? Can you point
> me to some sample code?
>
> Thanks,
> Rakesh
> ----------------------------------------------------------------------
> -------- Register Now for Creativity and Technology (CaT), June 3rd,
> NYC. CaT is a gathering of tech-side developers & brand creativity
> professionals. Meet the minds behind Google Creative Lab, Visual
> Complexity, Processing, & iPhoneDevCamp as they present alongside
> digital heavyweights like Barbarian Group, R/GA, & Big Spaceship.
> http://p.sf.net/sfu/creativitycat-com ________________________________
> _______________ dbunit-user mailing list dbunit-user@....
>
> net https://lists.sourceforge.net/lists/listinfo/dbunit-user


____________________________________________________________
Text: GRATIS f?r alle WEB.DE-Nutzer: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://produkte.web.de/go/04/




------------------------------

------------------------------------------------------------------------------
Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
is a gathering of tech-side developers & brand creativity professionals. Meet
the minds behind Google Creative Lab, Visual Complexity, Processing, &
iPhoneDevCamp as they present alongside digital heavyweights like Barbarian
Group, R/GA, & Big Spaceship. http://p.sf.net/sfu/creativitycat-com

------------------------------

_______________________________________________
dbunit-user mailing list
dbunit-user@...
https://lists.sourceforge.net/lists/listinfo/dbunit-user


End of dbunit-user Digest, Vol 37, Issue 16
*******************************************


------------------------------------------------------------------------------
Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
is a gathering of tech-side developers & brand creativity professionals. Meet
the minds behind Google Creative Lab, Visual Complexity, Processing, &
iPhoneDevCamp as they present alongside digital heavyweights like Barbarian
Group, R/GA, & Big Spaceship. http://p.sf.net/sfu/creativitycat-com 
_______________________________________________
dbunit-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/dbunit-user
Reply | Threaded
Open this post in threaded view
|

Re: dbunit-user Digest, Vol 37, Issue 16

Roberto Lo Giacco-4
Hi Rakesh,

I had a short experience with Oracle Object Type and DbUnit and we used
the following approach: load datas into the database with dbunit simply
using inserts, perform operations on Oracle, compare the dataset on the
database with the expected one...

But we didn't use the STRUCT construct, we considered them plain tables.

Take in consideration the Oracle Object Type is something similar to an
ORM tool... if you wish to use dbunit with an ORM tool you simply check
the database status against an expected status.... which is what dbunit
does.... :)

Rakesh Gupta wrote:

> Thanks!
>  
> I looked at org.dbunit.ext.oracle but I do not see any class which has
> the implementation for the Oracle Object Type support.  An example of
> an Oracle Type would be:
>  
> **
>
> *CREATE OR REPLACE TYPE *Chapter_T *AS OBJECT*
>
> ( c_no NUMBER,
>
> c_title VARCHAR2(20),
>
> c_page_no NUMBER );
>  
>  
> From what I know, the way the oracle types are handled in Java are by
> creating a POJO for the Oracle Type and registering it with connection
> using oracle.sql.STRUCT.
>  
> Are there any APIs in dbunit to hide the complexity of STRUCT and
> wrting the unit test for the procedures which has Oracle Types as
> input or output.
>  
> Thanks,
> Rakesh
>
>
>  
> 143 Newman Court
> Pennington, NJ - 08534
> Ph: 609-730-0651(H)
>       609-356-4333(Cell)
>       609-734-5401(W)
>
>
> --- On *Thu, 5/28/09, [hidden email]
> /<[hidden email]>/* wrote:
>
>
>     From: [hidden email]
>     <[hidden email]>
>     Subject: dbunit-user Digest, Vol 37, Issue 16
>     To: [hidden email]
>     Date: Thursday, May 28, 2009, 8:05 AM
>
>     Send dbunit-user mailing list submissions to
>         [hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=dbunit-user@...>
>
>     To subscribe or unsubscribe via the World Wide Web, visit
>         https://lists.sourceforge.net/lists/listinfo/dbunit-user
>     or, via email, send a message with subject or body 'help' to
>         [hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=dbunit-user-request@...>
>
>     You can reach the person managing the list at
>         [hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=dbunit-user-owner@...>
>
>     When replying, please edit your Subject line so it is more specific
>     than "Re: Contents of dbunit-user digest..."
>
>
>     Today's Topics:
>
>        1. dbunit Question! (Rakesh Gupta)
>        2. Re: dbunit Question! (Matthias Gommeringer)
>
>
>     ----------------------------------------------------------------------
>
>     Message: 1
>     Date: Wed, 27 May 2009 05:10:50 -0700 (PDT)
>     From: Rakesh Gupta <[hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=rakeshgupta_7@...>>
>     Subject: [dbunit-user] dbunit Question!
>     To: [hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=dbunit-user@...>
>     Message-ID: <[hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=763077.1784.qm@...>>
>     Content-Type: text/plain; charset="iso-8859-1"
>
>     Hi,
>     ?
>     I have a very basic question. How does dbunit handles the Oracle
>     Object Types (user defined oracle Types)?in java layer? Can you
>     point me to some sample code?
>     ?
>     Thanks,
>     Rakesh
>
>
>          
>     -------------- next part --------------
>     An HTML attachment was scrubbed...
>
>     ------------------------------
>
>     Message: 2
>     Date: Wed, 27 May 2009 21:35:07 +0200
>     From: Matthias Gommeringer <[hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=Matthias.Gommeringer@...>>
>     Subject: Re: [dbunit-user] dbunit Question!
>     To: [hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=dbunit-user@...>
>     Message-ID: <[hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=745866267@...>>
>     Content-Type: text/plain; charset=iso-8859-15
>
>     Hi Rakesh,
>
>     you can browse the sources at
>     http://dbunit.sourceforge.net/xref/index.html - there have a look
>     at the package "org.dbunit.ext.oracle" which contains all Oracle
>     specific implementation classes.
>
>     Regards,
>     matthias
>
>     > -----Urspr?ngliche Nachricht-----
>     > Von: "Rakesh Gupta" <[hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=rakeshgupta_7@...>>
>     > Gesendet: 27.05.09 14:11:34
>     > An: [hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=dbunit-user@...>
>     > Betreff: [dbunit-user] dbunit Question!
>
>
>     > Hi,
>     >
>     > I have a very basic question. How does dbunit handles the Oracle
>     > Object Types (user defined oracle Types) in java layer? Can you
>     point
>     > me to some sample code?
>     >
>     > Thanks,
>     > Rakesh
>     >
>     ----------------------------------------------------------------------
>     > -------- Register Now for Creativity and Technology (CaT), June
>     3rd,
>     > NYC. CaT is a gathering of tech-side developers & brand creativity
>     > professionals. Meet the minds behind Google Creative Lab, Visual
>     > Complexity, Processing, & iPhoneDevCamp as they present alongside
>     > digital heavyweights like Barbarian Group, R/GA, & Big Spaceship.
>     > http://p.sf.net/sfu/creativitycat-com
>     ________________________________
>     > _______________ dbunit-user mailing list
>     [hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=dbunit-user@...>.
>     >
>     > net https://lists.sourceforge.net/lists/listinfo/dbunit-user
>
>
>     ____________________________________________________________
>     Text: GRATIS f?r alle WEB.DE-Nutzer: Die maxdome Movie-FLAT!
>     Jetzt freischalten unter http://produkte.web.de/go/04/
>
>
>
>
>     ------------------------------
>
>     ------------------------------------------------------------------------------
>     Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
>     is a gathering of tech-side developers & brand creativity
>     professionals. Meet
>     the minds behind Google Creative Lab, Visual Complexity,
>     Processing, &
>     iPhoneDevCamp as they present alongside digital heavyweights like
>     Barbarian
>     Group, R/GA, & Big Spaceship. http://p.sf.net/sfu/creativitycat-com
>
>     ------------------------------
>
>     _______________________________________________
>     dbunit-user mailing list
>     [hidden email]
>     <http://us.mc528.mail.yahoo.com/mc/compose?to=dbunit-user@...>
>     https://lists.sourceforge.net/lists/listinfo/dbunit-user
>
>
>     End of dbunit-user Digest, Vol 37, Issue 16
>     *******************************************
>
>
> ------------------------------------------------------------------------
>
> ------------------------------------------------------------------------------
> Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
> is a gathering of tech-side developers & brand creativity professionals. Meet
> the minds behind Google Creative Lab, Visual Complexity, Processing, &
> iPhoneDevCamp as they present alongside digital heavyweights like Barbarian
> Group, R/GA, & Big Spaceship. http://p.sf.net/sfu/creativitycat-com 
> ------------------------------------------------------------------------
>
> _______________________________________________
> dbunit-user mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/dbunit-user
>  


--

  Roberto Lo Giacco

  Chief Technical Officer
  SmartLab s.r.l.
  via Spagna, snc - 87036 Rende (CS) - Italy

  Mobile: +39 392 8765657
  Email: [hidden email]
  Skype: longisland-75
  Web: http://www.smartlab.it 


------------------------------------------------------------------------------
Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT
is a gathering of tech-side developers & brand creativity professionals. Meet
the minds behind Google Creative Lab, Visual Complexity, Processing, &
iPhoneDevCamp as they present alongside digital heavyweights like Barbarian
Group, R/GA, & Big Spaceship. http://p.sf.net/sfu/creativitycat-com 
_______________________________________________
dbunit-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/dbunit-user