comp.lang.ada
 help / color / mirror / Atom feed
From: "Robert I. Eachus" <rieachus@attbi.com>
Subject: Re: Table read before inserting a record using Recordset update
Date: Thu, 14 Aug 2003 15:21:01 GMT
Date: 2003-08-14T15:21:01+00:00	[thread overview]
Message-ID: <3F3BA8CF.7010709@attbi.com> (raw)
In-Reply-To: b5a71bcf.0308140557.209545e@posting.google.com


> Trying to insert a record using the records section option
> (rs.addNew()). I think it reads the whole table. I'm using the query
> "select * from table where primary key = 1" for opening the record
> set. My DBA is reporting that she is seeing "select * from table"
> query is issued very frequently (where as we never issue this query
> from any where else).
> 
> I'm suspecting that addNew() function reads the whole table before
> inserting the record, but not sure. Any ideas or suggestions?

Sure, post to an appropriate newsgroup, and be sure to say which OS, 
database, and SQL binding you are using.

But more important, if you are using an RDBMS, such questions require 
knowing the schema for the database.  In an RDBMS, you can add data to a 
virtual table, and it may work--but not efficiently.  To get efficient 
updates, you usually have to add a (real) index to a real table.  And 
that question is appropriate to the right RDBMS group, but not here.

> Thanks !

You are welcome.  But please do not post any similar questions here, 
unless they are directly related to Ada or to an Ada binding to a 
particular database.  (You may have thought that this question was Ada 
related, but as you can see from the partial answer, it definitely is not.)

-- 
                                              Robert I. Eachus

"As far as I'm concerned, war always means failure." -- Jacques Chirac, 
President of France
"As far as France is concerned, you're right." -- Rush Limbaugh




      reply	other threads:[~2003-08-14 15:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-08-14 13:57 Table read before inserting a record using Recordset update baskar
2003-08-14 15:21 ` Robert I. Eachus [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox