If you already know how to use prepared statements then you should be able
to save it as a string, or multiple strings, and then dynamically add the
variables and add them to the string when necessary.  That way you can just
call the statement when you need.

        There is a very good example of prepared statements, although not with
dynamic use, in the Sun JDBC API Tutorial and Reference 2nd Ed.  I recommend
this book for any Java JDBC user.  It is excellent!

        Matt

-----Original Message-----
From: A mailing list for discussion about Sun Microsystem's JavaServlet API
Technology. [mailto:[EMAIL PROTECTED]]On Behalf Of J. Babu
Sent: Tuesday, October 10, 2000 8:51 PM
To: [EMAIL PROTECTED]
Subject: Re: mulitple inserts

 Hello,
    i want to use prepared statement, any idea?
my values are going to be dynamic

Regards,
Babu

-----Original Message-----
From: jdbc
To: [EMAIL PROTECTED]
Sent: 10/10/99 7:44 PM
Subject: Re: mulitple inserts

Yes,

you cabn use the following query

inset into abc values(1,2),(2,3),(3,4)

and execute this query. Using this query I i'm  inserting about 100
recrods
at a time.

Regards Deepak
http://www.roseindia.net


----- Original Message -----
From: J. Babu <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, October 10, 2000 11:17 PM
Subject: mulitple inserts


> Hi All,
>         Is it possible to write array of objects, directly into the
> Database, rather than executing each prepare statement?
>
> Thanks,
> Babu
>
>
________________________________________________________________________
___
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources:
http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
>

________________________________________________________________________
___
To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to