good advice..... I just tried it.... if I store a Rowset object, I am able to retrieve it in another applet !!! I can also access the result of query fired from the previous applet !!!!!
But Alas !!!! I can't fire a new query using the same object.... I get an error : [Microsoft][ODBC driver for Oracle][Oracle]ORA-01017: invalid username/password; logon denied But ur advice did introduced me to sun.jdbc.rowset.* Thanks. The second applet need to fire a new query depending on selected values by the user. So while I am in applet 1, I can't anticipate what query to fire. Also, I can't cache all info as it involves a no. of tables and thus will result in caching of a lot of unnecessary data. Any suggestion ? -----Original Message----- From: ^BoyInterrupted^ [mailto:[EMAIL PROTECTED]] Sent: 14 May 2002 12:29 To: [EMAIL PROTECTED] Subject: Re: persistent objects : a bit off topic One of the reasons behind the creation of the RowSets specification was this very feature of Connection objects , viz. that they cant be serialized. And it does make some sense , since a connection is a logical binding between two specific entities. I am sure that you could always design a workaround to your problem with a lil' RowSet help. Pramod ----- Original Message ----- From: "Michael Weller" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, May 14, 2002 4:48 PM Subject: Re: persistent objects : a bit off topic > hi! > This won't work for sure: java.sql.Connection is an interface, so a class > can't extend it :) > A concrete implementation of Connection comes with your jdbc-driver (just > like HttpSession is an interface which is implemented by the author of your > servlet-container). > Anyway: Where would you save the serializable Connection object so that > another applet can use it? Can't you connect your applet to a servlet that > passes serialized objects back to it after request or let your servlet talk > XML with your applet. This way your servlet can keep a ConnectionPool to > recycle Connection objects/create fewer connection objects, and your servlet > can cache the data so that your database only needs to be accessed if the > data changed. > > -mw > > ----- Original Message ----- > From: "Dmitrij Trunikov" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Tuesday, May 14, 2002 12:23 PM > Subject: Re: persistent objects : a bit off topic > > > > Kumar Sameer wrote: > > > > > I want to save the Connection object so that another applet can use it. > I > > > > .................... > > > > > And if yes.... well can u advise me of any other > > > method to achieve my objective. > > > > For connection serialization try somwthing like this: > > > > public class SerConnection extends Connection implements Serializable { > > } > > > > But I doubt that deserialized connection will be valid. > > Instead you can serealize parameters (url,login,passwd etc.) for reopen > > connection in other applet. > > > > > ___________________________________________________________________________ > > 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
