Welcome to WebmasterWorld Guest from 54.205.75.60

Forum Moderators: ocean10000

Message Too Old, No Replies

create query to bracket years in database field

   
8:07 pm on Feb 12, 2005 (gmt 0)



I am a newbie to Dreamweaver and am trying to figure out if it (or I) can create a bibliography search engine. I have managed to create a basic page with a form that searches author and keyword but am having trouble adding a search for years. I found a description on the Macromedia support page that provides an example but it doesn't seem to be working for me. Below is the SQL query I have in my Recordset dialog box. Any suggestions? The error statement is: [Microsoft][ODBC Microsoft Access Driver] Syntax error in date in query expression.

SELECT AuthorNames, Keywords, Citation
FROM literature
WHERE Keywords LIKE '%listKeywords%' And AuthorNames LIKE '%listAuthor%' AND Year BETWEEN #listStartYr# AND #listEndYr#

11:04 am on Feb 13, 2005 (gmt 0)

10+ Year Member



Remove the #'s if the field Year is a numeric field.
2:49 am on Feb 14, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Are those ASP variables you are trying to use in your query?

(listKeywords, listAuthor, listStartYr, listEndYr)