Re: CFIF Confusion

2001-07-30 Thread Ken Monroe
messing up the statement. I had been outputting the variable and it was showing up fine. Thx - Original Message - From: "C. Hatton Humphrey" <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent: Monday, July 30, 2001 10:17 AM Subject: RE: CFIF Confusi

RE: CFIF Confusion

2001-07-30 Thread Steve Martin
eh-oh: SELECT * FROM Wherever WHERE somefield IS NULL > That's because IS is not a valid SQL keyword... ~~ Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm FAQ: http://www.thenetprof

RE: CFIF Confusion

2001-07-30 Thread Kwang Suh
That's because IS is not a valid SQL keyword... I've also notice that in SQL, if I do a: SELECT * FROM TableName WHERE (FIELD1 LIKE 'yes') it works, but SELECT * FROM TableName WHERE (Field1 IS 'yes') does not work... ~~~

RE: CFIF Confusion

2001-07-30 Thread Mark Warrick
I'm not certain why the SQL statements you noted below would work the way they do, but it's possible that the fields are padded with extra spaces around the "yes" which is causing a problem. Converting the field type from varchar to integer will solve the problem. ---mark ==

Re: CFIF Confusion

2001-07-30 Thread G
> > I've also notice that in SQL, if I do a: > SELECT * > FROM TableName > WHERE (FIELD1 LIKE 'yes') > it works, but > SELECT * > FROM TableName > WHERE (Field1 IS 'yes') > does not work... > > ??? > Thx Thats because the correct syntax for SQL would be: WHERE F

Re: CFIF Confusion

2001-07-30 Thread Stephen Hait
You could check the value of the variable to see if it's really 'Yes' or not: FIELD1='#FIELD1#' Note single quotes surrounding variable output. Check to see if there might be trailing spaces - this might be the problem. HTH, Stephen > Hello! > > I'm working with SQL Server 2000 and I have

RE: CFIF Confusion

2001-07-30 Thread Bill Killillay
If you can change the data type of the Field1 you would be better to make it a bit field and then use 1 for yes and 0 for no, then your CF logic and your SQL will probably make more sense. Right now your trying to do String Comparisons when what you really want to be doing by what you have put do

RE: CFIF Confusion

2001-07-30 Thread C. Hatton Humphrey
When in doubt, use Trim() and UCase() functions to make sure, so instead of try See if that helps. Hatton Humphrey > -Original Message- > From: Ken Monroe [mailto:[EMAIL PROTECTED]] > Sent: Monday, July 30, 2001 10:07 AM > To: CF-Talk > Subject: CFIF Confusion > > > Hello! > > I

RE: CFIF Confusion

2001-07-30 Thread Tangorre, Mike
I would use type 'bit' for the field instead of varchar. Where 1 is yes and 0 is no, then in your if check if it is EQ 1 or EQ 0. Mike Michael T. Tangorre Web Applications Developer Office Phone: 703-558-4746 Cellular Phone: 607-426-9277 AIM: CrazyF