IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

[Solved]count the distinct rows of a particular column.


IBM Mainframe Forums -> DB2
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
mahi

New User


Joined: 04 Apr 2006
Posts: 86
Location: Hyderabad

PostPosted: Wed Apr 05, 2006 4:07 pm
Reply with quote

HI,

I want to count the distinct rows of a particular column.

How can I do that?
Back to top
View user's profile Send private message
priyesh.agrawal

Senior Member


Joined: 28 Mar 2005
Posts: 1448
Location: Chicago, IL

PostPosted: Wed Apr 05, 2006 4:49 pm
Reply with quote

Code:
SELECT COUNT(DISTINCT(COL-NAME)) FROM CREATOR.TAB-NAME;


Regards,
Priyesh.
Back to top
View user's profile Send private message
mahi

New User


Joined: 04 Apr 2006
Posts: 86
Location: Hyderabad

PostPosted: Wed Apr 05, 2006 6:04 pm
Reply with quote

Thank You Priyesh
Back to top
View user's profile Send private message
View previous topic : : View next topic  
Post new topic   Reply to topic All times are GMT + 6 Hours
Forum Index -> DB2

 


Similar Topics
Topic Forum Replies
No new posts count contained values of several col... DB2 5
No new posts DB2 Query to get the count of Unique ... DB2 2
No new posts Extract ISPF table column headings CLIST & REXX 2
No new posts Reflection 3270 screen shows only 23 ... Compuware & Other Tools 6
No new posts CA7 count with DATE variable CA Products 0
Search our Forums:


Back to Top