Subject | RE: [ib-support] Record Count |
---|---|
Author | Mike Grover |
Post date | 2001-11-07T21:39:49Z |
This is a read only database.
The user needs to see a record count and some of the fields from a query.
mike
-----Original Message-----
From: Paul Reeves [mailto:paul@...]
Sent: Wednesday, November 07, 2001 3:17 PM
To: ib-support@yahoogroups.com
Subject: Re: [ib-support] Record Count
Woody wrote:
this because the engine cannot tell which records are visible to the current
transaction without actually visiting each of them. It will be quicker than
actually fetching all the records counted, but it might not feel like it. This
is one of the few downsides of the MGA.
That said, why do you need to do a count? What are you counting? The total
rows in the table, or a subset? Do you know in advance what questions you are
going to ask? And how many users are involved in updating the database?
Paul
--
Paul Reeves
http://www.ibphoenix.com
taking InterBase further
To unsubscribe from this group, send an email to:
ib-support-unsubscribe@egroups.com
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
The user needs to see a record count and some of the fields from a query.
mike
-----Original Message-----
From: Paul Reeves [mailto:paul@...]
Sent: Wednesday, November 07, 2001 3:17 PM
To: ib-support@yahoogroups.com
Subject: Re: [ib-support] Record Count
Woody wrote:
>Not necessarily. Count has to literally count all the records. It has to do
> From: "Mike Grover" <mike@...>
> > This is not using IBComponents, ODBC Query, Using a count() means I have
> to query twice :-( , Very time consuming on large queries..
>
> A Count(*) query should not take that long regardless of the number of
> records. It is performed on the server side so it should return quickly.
>
this because the engine cannot tell which records are visible to the current
transaction without actually visiting each of them. It will be quicker than
actually fetching all the records counted, but it might not feel like it. This
is one of the few downsides of the MGA.
That said, why do you need to do a count? What are you counting? The total
rows in the table, or a subset? Do you know in advance what questions you are
going to ask? And how many users are involved in updating the database?
Paul
--
Paul Reeves
http://www.ibphoenix.com
taking InterBase further
To unsubscribe from this group, send an email to:
ib-support-unsubscribe@egroups.com
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/