In MSSQL , ROWCOUNT is a Setting for Operations Against Remote Tables

Try this:
SELECT serialnumber, count(*) 
FROM inventory 
GROUP BY serialnumber 
HAVING count(*) > 1

-----Original Message-----
From: Orlini, Robert [mailto:[EMAIL PROTECTED] 
Sent: Friday, September 23, 2005 2:54 PM
To: CF-Talk
Subject: RE: find identical records

Using SQL

-----Original Message-----
From: Barney Boisvert [mailto:[EMAIL PROTECTED]
Sent: Friday, September 23, 2005 2:39 PM
To: CF-Talk
Subject: Re: find identical records


What DB are you using?  Perhaps that's a reserved word, and needs to be 
escaped/changed?

cheers,
barneyb

On 9/23/05, Orlini, Robert <[EMAIL PROTECTED]> wrote:
> Thanks Barney.
>
> It says "Incorrect syntax near the keyword rowcount"
>
> -----Original Message-----
> From: Barney Boisvert [mailto:[EMAIL PROTECTED]
> Sent: Friday, September 23, 2005 2:27 PM
> To: CF-Talk
> Subject: Re: find identical records
>
>
> SELECT serialnumber, count(*) AS rowCount FROM inventory GROUP BY 
> serialnumber HAVING rowCount > 1
>
> That should give you a list of serials that exist more than once, 
> along with how many instances there are.  And update your AVG, it says 
> it's out of date.
>
> cheers,
> barneyb
--
Barney Boisvert
[EMAIL PROTECTED]
360.319.6145
http://www.barneyb.com/

Got Gmail? I have 100 invites.





~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:219136
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to