|
|
Choosing A Webhost: |
AW: Question: JDBC, PreparedStatements: msg#00397db.maxdb
Hello! So that means, that in case of 'n' connections in a pool, I have the first "caching benefit/cachehit" maybe after the (n+1) execution of a connection.preparedStatement("some sql") in worst case? Is this right? Chris -----Ursprüngliche Nachricht----- Von: Schroeder, Alexander [mailto:alexander.schroeder@xxxxxxx] Gesendet: Freitag, 28. November 2003 14:01 An: Christoph Weser; maxdb (E-Mail) Betreff: RE: Question: JDBC, PreparedStatements Hello Christoph, if you specify cache=all, information is cached *per connection*. That means there is not necessarily a need for caching the information by yourself. Alexander Schröder SAP DB, SAP Labs Berlin > -----Original Message----- > From: Christoph Weser [mailto:Christoph.Weser@xxxxxxxxx] > Sent: Friday, November 28, 2003 1:53 PM > To: maxdb (E-Mail) > Subject: Question: JDBC, PrepparedStatements > > > Hello everyone! > > I am using sapdb 7.4 and the newest jdbc driver. For > connection, the URL > "jdbc:sapdb://localhost:7210/DatabaseName?cache=all" will be used. > > While processing requests, the following fragment is quite > often executed: > > pStatement = connection.prepareStatement("Some sql command with ?"); > pStatement.setString(1,"Test"); > pStatement.executeUpdate(); > pStatement.close(); > > The connection 'connection' is from a connection pool and the > connection > will be given back to the pool after every single request. > (Every request is a stateless request for which a own instance of a > requesthandler will be generated. That's why every request > the connection > will be given back.) > > Am I right, that the connection.prepareStatement()-method > will cause the > JDBC-driver to lookup in his own preparedStatement-Cache? > Would it be better to implement a preparedStatement-Cache by my own? > What's best practice? > > Thanx a lot for help to everyone! > > Chris > > -- > MaxDB Discussion Mailing List > For list archives: http://lists.mysql.com/maxdb > To unsubscribe: http://lists.mysql.com/maxdb?unsub=alexander.schroeder@xxxxxxx -- MaxDB Discussion Mailing List For list archives: http://lists.mysql.com/maxdb To unsubscribe: http://lists.mysql.com/maxdb?unsub=gcdm-maxdb@xxxxxxxxxxx
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | RE: Question: JDBC, PreparedStatements, Schroeder, Alexander |
|---|---|
| Next by Date: | RE: Question: JDBC, PreparedStatements, Schroeder, Alexander |
| Previous by Thread: | RE: Question: JDBC, PreparedStatements, Schroeder, Alexander |
| Next by Thread: | AW: Question: JDBC, PreparedStatements, Christoph Weser |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
Free MagazinesCisco NewsReceive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business. subscribe Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field. subscribe The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business. subscribe Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. subscribe Total Telecom Total Telecom is "The Economist of the communications industry". subscribe |