Subject | ibo_cursor |
---|---|
Author | comesailing@btinternet.com |
Post date | 2001-09-06T22:31:03Z |
Simple question from a simple mind.
What is the absolute fastest way of determining whether a big table
has a particular record ?
Suppose we have table with columns A,B,C, and D of which A is primary
key.
Can do, "select Count(A) from mytable where B=5 and C=6 and D=7" say
and if count is 0 we have no such record.
Or can do "select A from mytable where B=5 and C=6 and D=7" and if A
is null we have no such record.
Or Locate ... ??
Having to do many of these within a loop it is desirable to fnd the
fastest.
Any Advice Please.
Dave
What is the absolute fastest way of determining whether a big table
has a particular record ?
Suppose we have table with columns A,B,C, and D of which A is primary
key.
Can do, "select Count(A) from mytable where B=5 and C=6 and D=7" say
and if count is 0 we have no such record.
Or can do "select A from mytable where B=5 and C=6 and D=7" and if A
is null we have no such record.
Or Locate ... ??
Having to do many of these within a loop it is desirable to fnd the
fastest.
Any Advice Please.
Dave