Dave,
My _Thanks_ to all experienced people for help!
In fact, real query is a little bit intricate. :)))
Dave> Also, I noticed in your signature that you're a:
>> Certified Cold Fusion 4.1 Programmer.
Dave> I didn't even know there was a 4.1 version! Just kidding.
A
I think "fred" is a reserved word.
On Wed, 19 Apr 2000 <[EMAIL PROTECTED]> writes:
> select count(*) as fred
YOU'RE PAYING TOO MUCH FOR THE INTERNET!
Juno now offers FREE Internet Access!
Try it today - there's no risk! For your F
You need to use an alias:
select count(*) as numCusts
and then output #numCusts#
-cf-talk
On Wed, 19 Apr 2000 Alex Puriche <[EMAIL PROTECTED]> writes:
> cf-talk,
>
>
> select count(*)
> from customer
> where CustomerName='My_Name'
>
>
>
>
> #What I need to put here???#
>
>
-Original Message-
From: Alex Puriche [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 19, 2000 8:54 AM
To: [EMAIL PROTECTED]
Subject: SQL.COUNT question
cf-talk,
select count(*)
from customer
where CustomerName='My_Name'
#asdfgh.recordcount#
-
From: Alex Puriche [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 19, 2000 11:54 AM
To: [EMAIL PROTECTED]
Subject: SQL.COUNT question
cf-talk,
select count(*)
from customer
where CustomerName='My_Name'
#What I need to put here???#
--
Regards,
Alex
>
> select count(*)
> from customer
> where CustomerName='My_Name'
>
>
>
>
> #What I need to put here???#
>
>
You'll need to alias your aggregate function:
SELECT COUNT(*) AS SomeVariableNameOfYourChoice ...
then reference that in your CFOUTPUT:
#myquery.SomeVariableName
Try this,
select count(*) as myvar
from customer
where CustomerName='My_Name'
#myvar#
>
>
> --
> Regards,
> Alex mailto:[EMAIL PROTECTED]
>
> Certified HTML Programmer,
> Java Script Programmer and
> High IT Aptitude Specialist.
> http://ww
you need to alias the field.
select count(*) as fred
from customer
where CustomerName='My_Name'
#fred#
-Original Message-
From: Alex Puriche [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 19, 2000 11:54 AM
To: [EMAIL PROTECTED]
Subject: SQL.COUNT que
erm? to achieve what?
- Original Message -
From: Alex Puriche <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, April 19, 2000 4:54 PM
Subject: SQL.COUNT question
> cf-talk,
>
>
> select count(*)
> from customer
> where CustomerName=
cf-talk,
select count(*)
from customer
where CustomerName='My_Name'
#What I need to put here???#
--
Regards,
Alex mailto:[EMAIL PROTECTED]
Certified HTML Programmer,
Java Script Programmer and
High IT Aptitude Specialist.
http://www.brainbe
10 matches
Mail list logo