Re: Correct Syntax for this piece of SQL ??

2003-03-01 Thread Dina Hess
t; > OR UPPER(commapproval) LIKE UPPER( value="%#form.commapproval#%">) > > > > > > > - Original Message ----- > From: "Pascal Peters" <[EMAIL PROTECTED]> > To: "CF-Talk" <[EMAIL PROTECTED]> > Sent: Wednesday, Februar

Re: Correct Syntax for this piece of SQL ??

2003-02-26 Thread Ian Vaughan
) LIKE UPPER() OR UPPER(funding) LIKE UPPER() OR UPPER(commapproval) LIKE UPPER() - Original Message - From: "Pascal Peters" <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent: Wednesday, February 26, 2003 2:49 PM Subject: RE: Correct Syntax

RE: Correct Syntax for this piece of SQL ??

2003-02-26 Thread Pascal Peters
#orgname# #funding# #commapproval# - Original Message - From: "Pascal Peters" <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent:

Re: Correct Syntax for this piece of SQL ??

2003-02-26 Thread Ian Vaughan
uot; <[EMAIL PROTECTED]> Sent: Wednesday, February 26, 2003 11:34 AM Subject: RE: Correct Syntax for this piece of SQL ?? > This should work on ORACLE8/CF4.5.1 (I'm developping for that platform right now) > I can't make much of your error. Can you post your entire cfquery. &g

RE: Correct Syntax for this piece of SQL ??

2003-02-26 Thread Pascal Peters
Aan: CF-Talk CC: Onderwerp: Re: Correct Syntax for this piece of SQL ?? Pascal Thanks for your solution but it does not work, I am using CF 4.5 and Oracle 8. I am getting the following error when using your code,

Re: Correct Syntax for this piece of SQL ??

2003-02-26 Thread Ian Vaughan
2 AM Subject: RE: Correct Syntax for this piece of SQL ?? > If one of your form variables is empty, it will always return all the records because you match '%%' (which means anything). If you want to match one of the criteria you entered, this should work: > > SELECT * > FROM fundi

RE: Correct Syntax for this piece of SQL ??

2003-02-26 Thread Pascal Peters
ughan [mailto:[EMAIL PROTECTED] Verzonden: wo 26/02/2003 10:20 Aan: CF-Talk CC: Onderwerp: Re: Correct Syntax for this piece of SQL ?? Hi I have just tried the following query select * from f

Re: Correct Syntax for this piece of SQL ??

2003-02-26 Thread Ian Vaughan
returns all results ??? All 3 criteria do no have to be met, Any ideas why the above sql is returning all results ?? Ian - Original Message - From: "Jann VanOver" <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent: Wednesday, February 26, 2003 5:48 AM Su

Re: Correct Syntax for this piece of SQL ??

2003-02-25 Thread Jann VanOver
I think Lee said it too, you've got a basic logic flaw. Your query says all three criteria must be met. Did you mean to say: select * from funding Where ( orgname LIKE '%#Form.orgname#%' ) OR( funding LIKE '%#Form.funding#%' ) OR( commapproval LIKE '%#Form.commapproval#%' ) ORDER BY

Correct Syntax for this piece of SQL ??

2003-02-25 Thread lee
There is a basic flaw to the SQL that may be giving you fits: You are doing an "AND" search, not an "OR". In and "AND" search, all three conditions (in your case) have to return "true" (with a match) for results. In an "OR" search, only one of the three conditions (again, your example) have to

RE: Correct Syntax for this piece of SQL ??

2003-02-25 Thread Pascal Peters
for this piece of SQL ?? Try this: select * from funding Where orgname LIKE UPPER('%#Form.orgname#%') ANDWHERE funding LIKE UPPER('%#Form.funding#%') ANDWHERE commapproval LIKE UPPER('%#Form.commapproval#%') ORDER BY recordid This will generate a query

RE: Correct Syntax for this piece of SQL ??

2003-02-25 Thread Larry Juncker
lk Subject: Correct Syntax for this piece of SQL ?? Hi I have the following form which is being used to search against my database table. When I search using the 'orgname' field and there are matches then results are returned. However if I search in the other two fields then it displa

RE: Correct Syntax for this piece of SQL ??

2003-02-25 Thread Andre Mohamed
R(funding) LIKE '%#UCase(Form.funding)#%' etc. Thanks, André -Original Message- From: Ian Vaughan [mailto:[EMAIL PROTECTED] Sent: 25 February 2003 14:49 To: CF-Talk Subject: Correct Syntax for this piece of SQL ?? Hi I have the following form which is being used to search

Correct Syntax for this piece of SQL ??

2003-02-25 Thread Ian Vaughan
Hi I have the following form which is being used to search against my database table. When I search using the 'orgname' field and there are matches then results are returned. However if I search in the other two fields then it displays no results found when it should bring back results ? Is thi