|
But you are referencing the DOB field within the query:
"Talent.DOB"
Are you sure all of the selected fields within the query do indeed exist in the table?
There is a spelling error in Talent.Clothssize - is this how you have spelt it in the table?
As the error suggests, one of the fields you are referencing either doesn't exist in the table or is misspelt.
Double double check em :/
Sarah Atkinson
-----Original
Message-----
Hi this is the exact code. and current error message.
My thinking is its the dob field is not being reference in the query.
all i want to do is get all records between the age of say 2 years old and 4 years old based on the value in the database DOB which is the date of birth eg 18/03/2000 this record would be selected as well as anyother that fell in betwenn the minus 2 years from today and 4 years from today
between 18/03/2001 and 18/03/1999
the value i send to the querry is AGE lets say 3
May be i should be doing a now() - 2 and now()-4 as the between values..
HMMMMM is that more like it????? any pointers will be most appresiated
[Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1. 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. SQL = "SELECT Talent.talentID , Talent.Name , Talent.Gender , Talent.DOB , Talent.Hair , Talent.Eye , Talent.Height , Talent.Clothssize , Talent.shoesize , Talent.hobbies , Talent.BIO , Talent.Compcard , Talent.ID FROM Talent WHERE Talent.gender = 'male' AND dob BETWEEN DateAdd(Year,7,dob) AND DateAdd(Year,3,dob)"
<cfset Form.age =5>
<CFQUERY
name="getRecord" dataSource="interact">
<!---
Check for age ---> <!---
If we want all people younger than an age ---> <!---
If we want all people older than an age --->
</CFQUERY>
thanks --- You are currently subscribed to cfaussie as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED] MX Downunder AsiaPac DevCon - http://mxdu.com/ --- You are currently subscribed to cfaussie as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED] MX Downunder AsiaPac DevCon - http://mxdu.com/
|
<<attachment: image001.jpg>>
