Below is for a search interface I'm working on.
A single word into the query works fine.
I've a function that cleans the input, removes common words, and builds
a list. The list is getting built properly.
If I input bob,ted I get an vague syntax error (shared hosting - robut
reporting is
the double quotes?
like '%bob%' or '%ted%'
On Wed, May 4, 2011 at 7:04 PM, Les Mizzell lesm...@bellsouth.net wrote:
Below is for a search interface I'm working on.
A single word into the query works fine.
I've a function that cleans the input, removes common words, and builds
a list. The
On 5/4/2011 8:15 PM, Greg Morphis wrote:
the double quotes?
like '%bob%' or '%ted%'
That's just in the outputted version.
I've rewritten it again though. Output is now:
WHERE section 'news'
AND ( headline LIKE '%barnett%'
OR content LIKE '%barnett%' OR headline LIKE '%shale%'
OR content
Take your query and wrap it in a cfoutput tag instead of cfquery.
Remove the cfqueryparams and just have the variables.
This should output exactly what is being passed to your DB.
Can you post this query or maybe you'd even see what's wrong.
Plus if you run that query against your DB it should
On 5/4/2011 9:11 PM, Greg Morphis wrote:
Take your query and wrap it in a cfoutput tag instead of cfquery.
Remove the cfqueryparams and just have the variables.
That's this:
WHERE section 'news'
AND ( headline LIKE '%bob%'
or content LIKE '%bob%' OR headline LIKE '%robert%'
or content LIKE
This did the trick:
WHERE section 'news'
cfif ListLen('#myLIST#') gt 1
AND (
cfloop list=#mylist# index=i
cfset #thisROW# = #thisROW# + 1 /
headline LIKE cfqueryparam value=%#i#%
cfsqltype=cf_sql_varchar
or content LIKE cfqueryparam value=%#i#%
Do you not have access to a SQL editor you could put that outputted SQL into?
Should point out where the syntax issue is..
Do this
cfoutput
SELECT
id_page,
headline,
content,
section
FROM pages
WHERE section 'news'
cfif ListLen('#myLIST#') gt 1
AND (
I know it's late and all but what did you do differently?
Here's what you had earlier and looks the same.. lol Like I said.. it's late!
WHERE section 'news'
cfif ListLen('#myLIST#') gt 1
AND (
cfloop list=#mylist# index=i
cfset #thisROW# = #thisROW# + 1 /
Les,
That looks good. Did you try running that directly in your database?
While I was looking at your query, I thought I would toss out how I would have
written it, which removes an extra conditional and an extra variable:
SELECT id_page,headline,content,section
FROM
Howdy,
I have an aggregate query that's kicking my butt. Its purpose is to retrieve
a simple report of donations by donors within a given date range. Most
everything works except for the Count and Sum functions. I'm not sure this
can be done in one query or not. Database is MS Access.
What I'm
les to display at your leisure.
chris olive, cio
cresco technologies
[EMAIL PROTECTED]
http://www.crescotech.com
-Original Message-
From: Chris Montgomery [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 21, 2001 5:53 PM
To: CF-Talk
Subject: A little help with aggregate query, please?
-4692
AIM: astutiaweb; ICQ: 7381282; Firetalk: Ag78
-Original Message-
From: Christopher Olive, CIO [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 21, 2001 5:18 PM
To: CF-Talk
Subject: RE: A little help with aggregate query, please?
your sum is being GROUPed by each individual
12 matches
Mail list logo