Bizarre Counts [message #20887] |
Thu, 27 June 2002 08:57 |
cath
Messages: 4 Registered: March 2002
|
Junior Member |
|
|
Hi
I run a query and at the end it says "2100 rows selected". If I replace the selected fields with a count(*) instead, the same query says 2114 rows counted. I cannot understand why the count wouldn't be the same. Anyone ever encounter this? Thanks in advance for your help.
Catherine
Here is my query 1:
SELECT p.product_id,t.title_id
FROM product p , title t
WHERE p.source_id in (1000,1001,1002)
AND p.product_id not in(SELECT pa.product_id
FROM product_attributes pa)
AND p.title_id = t.title_id
AND t.c_text like '%Basic Product Data%'
AND t.deleted = 'N';
Here is query 2:
SELECT count(*)
FROM product p , title t
WHERE p.source_id in (1000,1001,1002)
AND p.product_id not in(SELECT pa.product_id
FROM product_attributes pa)
AND p.title_id = t.title_id
AND t.c_text like '%Basic Product Data%'
AND t.deleted = 'N';
|
|
|
|