Query:Field 'fieldname' not found 
Author Message
 Query:Field 'fieldname' not found

Rogerio,

It's not advisable to use names like Number and Value for fields -
treat them as reserved words.
However, it should work if you do this:

    Select count(distinct T."Number") from <TableName> T

    Stephen
--
Stephen Brown
+44 (0)171 704 0702


Quote:
>I'm trying to use a TQuery to select the number of records in a
Paradox 4
>table which has 4 fields:  NUMBER  N  ITEM  A 6  QUANT N  VALUE  $
The key
>is NUMBER+ITEM. The SQL used is "select count (distinct numero) from
<table
>name> where item <> '999997'". The Query runs ok, but when I try to
open a
>report with its result, an exception is raised, with the message
>"...EDatabaseError ... <query name>:Field 'number' not found ..."
Does
>anybody have an idea of what I'm doing wrong? Thanks, Rogerio



Wed, 18 Jun 1902 08:00:00 GMT  
 Query:Field 'fieldname' not found

Quote:

> I'm trying to use a TQuery to select the number of records in a Paradox 4
> table which has 4 fields:  NUMBER  N  ITEM  A 6  QUANT  N  VALUE  $ The key
> is NUMBER+ITEM. The SQL used is "select count (distinct numero) from <table
> name> where item <> '999997'". The Query runs ok, but when I try to open a
> report with its result, an exception is raised, with the message
> "...EDatabaseError ... <query name>:Field 'number' not found ..." Does
> anybody have an idea of what I'm doing wrong? Thanks, Rogerio

Number field will not be in the result set, there will (probably) be field
COUNT. You can use: SELECT COUNT( fieldname ) AS anewfieldname, to get a
different name to refer to in the report.

--
Kari Heinonen / Veikko Heinonen Oy

http://personal.inet.fi/koti/veikko.heinonen/



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Field 'PHYSICALTYPE' not found

2. Creating RunTime Fields: EDataBaseError 'Field 'Fieldname' is not of the expected type'

3. BDE 'Could not find object'

4. Field 'xxxxx' not fount

5. Query Problem EdatabaseError Field not Found

6. 'Could not find PRIMARY KEY...

7. Server's TProvider not found by client dataset

8. type field ''money''

9. Can't find fields

10. A simple error like: can't find index for fieldnames "X", and i don't understand, Help

11. 'Circular data links' hard to find

12. IS Express can't find BDE's DATAPUMP.EXE

 

 
Powered by phpBB® Forum Software