Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.
-
mate of the state #1
SQL generates 'access violation or syntax' error whencompiled into string var ahead of time
I have stumbled across something perplexing and frustrating, and I'm hoping
somebody can shed some light here.
I have a site with some listings. I would like to give the users the ability
to filter out items from those listings based on certain criteria. They may
select all, none or some of the filters. As such, I would like to create the
query programmatically based upon which filters they're applying.
See the attached code for some insight into what I'm talking about.
Without any filters supplied, the query should be very simple:
SELECT * FROM auctions WHERE auctions.end > #createODBCDateTime(now())#
This should simply return all auctions that have no yet closed, and it DOES as
long as I put that text as the body of a <CFquery /> but NOT when I put it into
a variable first, and then use that within' <CFquery />
What's at play here? Surely ColdFusion is not so unfairly maligned as to now
allow programmatic construction of queries as I've discussed here!
mate of the state Guest
-
Syntax error when trying to update date/time field
I am getting a MS Access ODBC Syntax error (missing operator) in query expression '2006-01-05 09:17:01.0' when I try to execute an update query. On... -
Setting up the date ahead of time
Hi all, I have a web site that surveys employees to see if they want to work the weekend. One of the problems I'm having is that I don't want to go... -
Access Violation error
Hi Hope you can help. I am trying to run a basic weather script on my homepage .... it is at http://www.phoenixfm.com/phpweather-1.62/test.php... -
Planning Your Movie Ahead of Time...(Devil's Advocate anyone?)
Here's the setup. Awards show. Format is below: Pre-Opening - (a 30 minute or so "screensaver" show that's linear, playing before everyone... -
Access Violation Error Using MIAW's
Hello all, Here's my problem. I am getting an application exception error as shown below when running my application. Below is the message from... -
OldCFer #2
Re: SQL generates 'access violation or syntax' errorwhen compiled into string var ahead of time
Use:
<CFquery name="auctions" datasource="#request.dsn#">#PreserveSingleQuotes(a q)#</CFquery>
OldCFer Guest
-
mate of the state #3
Re: SQL generates 'access violation or syntax' errorwhen compiled into string var ahead of time
Ah! Beautiful! Thanks! :)
mate of the state Guest



Reply With Quote

