Re: Quick SQL question...maybe.

2004-07-20 Thread Deanna Schneider
SELECT SUM(CASE WHEN maepos = 1 THEN 1 ELSE 0) AS pos1Count, SUM(CASE WHEN maepos = 2 THEN 1 ELSE 0) AS pos2Count, SUM(CASE WHEN maepos = 3 THEN 1 ELSE 0) AS pos3Count, SUM(CASE WHEN maepos = 4 THEN 1 ELSE 0) AS pos1Count FROM mae - Original Message - From: Che Vilnonis Is there an

Re: Quick SQL question...maybe.

2004-07-20 Thread S . Isaac Dealey
select (select count(meepos) from mae where maepos = 1) as pos1count, (select count(maepos) from mae where maepos = 2) as pos2count ... or better yet, select maepos, count(maepos) as poscount from mae group by maepos order by maepos This will return 2 columns and multiple rows - the first

RE: Quick SQL question...maybe.

2004-07-20 Thread Che Vilnonis
THEN 1 ELSE 0 END) AS pos4Count FROM MAE WHERE ACTIVE = 1 -Original Message- From: Deanna Schneider [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 20, 2004 4:36 PM To: CF-Talk Subject: Re: Quick SQL question...maybe. SELECT SUM(CASE WHEN maepos = 1 THEN 1 ELSE 0) AS pos1Count, SUM(CASE WHEN

Re: Quick SQL question...maybe.

2004-07-20 Thread Deanna Schneider
Oh yah, typing too fast and then cutting and pasting will do that to ya. Sorry. :) - Original Message - From: Che Vilnonis [EMAIL PROTECTED] To: CF-Talk [EMAIL PROTECTED] Sent: Tuesday, July 20, 2004 3:44 PM Subject: RE: Quick SQL question...maybe. Thanks Deanna...I got an error

RE: Quick SQL Question...

2004-03-15 Thread Bill Grover
__ -Original Message- From: Mark A. Kruger - CFG [mailto:[EMAIL PROTECTED] Sent: Sunday, March 14, 2004 2:39 PM To: CF-Talk Subject: RE: Quick SQL Question... That's a neat trick- saves a lot of typing. Thanks! -Original Message- From

RE: Quick SQL Question...

2004-03-14 Thread Mark A. Kruger - CFG
That's a neat trick- saves a lot of typing. Thanks! -Original Message- From: Che Vilnonis [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 2:35 PM To: CF-Talk Subject: RE: Quick SQL Question... thank you! -Original Message- From: DURETTE, STEVEN J (AIT) [mailto:[EMAIL

RE: Quick SQL Question...

2004-03-12 Thread Burcham, Steve
Try dropping the second Group By Variable. Thank you. Steve Burcham Webmaster RDO Equipment Co. Phone (701) 526-9838 Fax (701) 526-9839 mailto:[EMAIL PROTECTED] [EMAIL PROTECTED] _ From: Che Vilnonis [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 1:28 PM To: CF-Talk Subject:

RE: Quick SQL Question...

2004-03-12 Thread Eric Creese
becasue all the dates are different. does a psuedo DISTINCT -Original Message- From: Che Vilnonis [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 1:28 PM To: CF-Talk Subject: Quick SQL Question... This SQL Code works: SELECT COUNT(creationdate) AS TotalRefsPerDay FROM Referer

RE: Quick SQL Question...

2004-03-12 Thread Che Vilnonis
then i get the 'not contained in aggregate function or group by error'. any other ideas? -Original Message- From: Burcham, Steve [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 2:32 PM To: CF-Talk Subject: RE: Quick SQL Question... Try dropping the second Group By Variable. Thank

RE: Quick SQL Question...

2004-03-12 Thread Mark A. Kruger - CFG
The 2 are mutually exclusive.One is the group of all the stuff on this day, but the other (the actual date) is not merely a date - but a - by nature a very unique item - down to the second. So you are actually getting the grouping you are asking for.If 2 referals occured at the exact instant (say

RE: Quick SQL Question...

2004-03-12 Thread Che Vilnonis
-Talk Subject: RE: Quick SQL Question... becasue all the dates are different. does a psuedo DISTINCT -Original Message- From: Che Vilnonis [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 1:28 PM To: CF-Talk Subject: Quick SQL Question... This SQL Code works: SELECT COUNT

RE: Quick SQL Question...

2004-03-12 Thread Che Vilnonis
mark, i see where you are coming from...alas, i still am having no luck. -Original Message- From: Mark A. Kruger - CFG [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 2:51 PM To: CF-Talk Subject: RE: Quick SQL Question... The 2 are mutually exclusive.One is the group of all

RE: Quick SQL Question...

2004-03-12 Thread Eric Creese
do not use it, I was explaining why you are getting the results you are getting. sorry if that was confusing. -Original Message- From: Che Vilnonis [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 1:44 PM To: CF-Talk Subject: RE: Quick SQL Question... distinct does not seem to work

RE: Quick SQL Question...

2004-03-12 Thread DURETTE, STEVEN J (AIT)
: Friday, March 12, 2004 2:52 PM To: CF-Talk Subject: RE: Quick SQL Question... mark, i see where you are coming from...alas, i still am having no luck. -Original Message- From: Mark A. Kruger - CFG [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 2:51 PM To: CF-Talk Subject: RE: Quick SQL

RE: Quick SQL Question...

2004-03-12 Thread Che Vilnonis
WOW! WOW! WOW! Thanks so much. I knew this was possible. what is the significanse of the 101 -Original Message- From: DURETTE, STEVEN J (AIT) [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 3:03 PM To: CF-Talk Subject: RE: Quick SQL Question... Che, If you are on MSSql 2K

RE: Quick SQL Question...

2004-03-12 Thread DURETTE, STEVEN J (AIT)
:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 3:18 PM To: CF-Talk Subject: RE: Quick SQL Question... WOW! WOW! WOW! Thanks so much. I knew this was possible. what is the significanse of the 101 -Original Message- From: DURETTE, STEVEN J (AIT) [mailto:[EMAIL PROTECTED] Sent: Friday, March 12

RE: Quick SQL Question...

2004-03-12 Thread Che Vilnonis
thank you! -Original Message- From: DURETTE, STEVEN J (AIT) [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 3:31 PM To: CF-Talk Subject: RE: Quick SQL Question... The numbers in the 3rd position of the convert are qualifiers for how it will convert.In this case 101 = USA = MM/DD/YY

Re: quick SQL question for my add/edit page

2002-03-07 Thread Hatton Humphrey
Amanda, Sounds more like you want to do a hidden input field with value=#left(programcode, 1)# in it. HTH Hatton Amanda Stern wrote: Hello, I need to add a new hidden field to my add/edit page that will update the table when a new record it added or updated..not sure how to write the

Re: quick SQL question for my add/edit page

2002-03-07 Thread Brian Scandale
cfset hiddenField = left(trim(UserInputString),1) this should move the first non-blank entry into the variable hiddenField At 01:05 PM 3/7/02 -0800, you wrote: Hello, I need to add a new hidden field to my add/edit page that will update the table when a new record it added or updated..not