**********************************************************************
WESTMINSTER CITY COUNCIL
Please refer to the disclaimer beneath this message
**********************************************************************

I have a CSV file that I want to query.  In my CSV file I have added a row
with the column names in it, but when I try to query the file I getan error.
This is my query:

<cfquery name="getAirPollution" datasource="Pollution">
  SELECT  CGNOx,
                    CGNO
  FROM     Pollution.csv
  WHERE  Date = 20723
  AND       Time = 1245 
</cfquery>

And I get this error message.

ODBC Error Code = 07001 (Wrong number of parameters) 

[Microsoft][ODBC Text Driver] Too few parameters. Expected 2. 
Hint: The cause of this error is usually that your query contains a
reference to a field which does not exist. You should verify that the fields
included in your query exist and that you have specified their names
correctly.

Now this is the first time I have tried to use a csv file as a datasource,
the file is verified as a datasource in CF administrator,  but I am having
trouble writing the query.  Any help would be great, thanks.

Stephen


**********************************************************************
Westminster City Council switchboard: 
+44 20 7641 6000
**********************************************************************
This E-Mail may contain information which is 
privileged, confidential and protected from 
disclosure.  If you are not the intended recipient 
of this E-mail or any part of it, please telephone 
Westminster City Council immediately on receipt.
You should not disclose the contents to any other 
person or take copies.
**********************************************************************

______________________________________________________________________
Get the mailserver that powers this list at http://www.coolfusion.com
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to