Have you tried simply assuming varchar in all cases. I know that in SQL server for instance, you can update/insert/whatever fields by wrapping single quotes around them whether they are varchar, text or integer (etc.) The same may apply for selects with QoQs. Just a thought. Steve
> -----Original Message----- > From: Justin MacCarthy [mailto:[EMAIL PROTECTED] > Sent: 03 April 2003 15:00 > To: [EMAIL PROTECTED] > Subject: Re: [ cf-dev ] QoQ question > > > I don't think that will work > > field > ------------------------------- > fname justin varchar > lname 1 varchar > age 10 int > > isnumeric(fname) no > isnumeric(lname) yes > isnumeric(age) yes > > I think.... > > Justin > > > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] > Sent: 03 April 2003 14:43 > To: [EMAIL PROTECTED] > Subject: [notspam] Re: [ cf-dev ] QoQ question > > > > <cfif IsNumeric(fieldname1)> > WHERE fieldname1 = 1 > <cfelse> > WHERE fieldname1 = 'abc' > </cfif> > > > Duncan Cumming > IT Manager > > http://www.alienationdesign.co.uk > mailto:[EMAIL PROTECTED] > Tel: 0141 575 9700 > Fax: 0141 575 9600 > > Creative solutions in a technical world > > ---------------------------------------------------------------------- > Get your domain names online from: > http://www.alienationdomains.co.uk > Reseller options available! > ---------------------------------------------------------------------- > ---------------------------------------------------------------------- > > > > "Justin > MacCarthy" To: "Cfuk" > <[EMAIL PROTECTED]> > <[EMAIL PROTECTED] cc: > .ie> Subject: [ cf-dev ] QoQ > question > > 03/04/2003 > 14:40 > Please > respond to > dev > > > > > > I have a generic tag that will do a QoQ. > > <cfquery name ="SubQuery" dbtype = "query"> > SELECT * > FROM MyQuery > WHERE fieldname1 = 'abc' [or WHERE > fieldname1 = 1 ] > > I want to do > > fieldname1 = 'abc' if the fieldname is a string/varchar/char etc.. > or > fieldname1 = 1 if the fieldname is a INT/number > > How can I test if the SQL type in the Query is INT or VARCHAR??? > > Thanks ~J > > -- > ** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/ > > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > For human help, e-mail: [EMAIL PROTECTED] > > > > > > > -- > ** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/ > > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > For human help, e-mail: [EMAIL PROTECTED] > > > > > > -- > ** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/ > > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > For human help, e-mail: [EMAIL PROTECTED] > > -- ** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] For human help, e-mail: [EMAIL PROTECTED]
