Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Count distinct ignore nulls in Pivot

Status
Not open for further replies.

sravala

IS-IT--Management
Jan 28, 2004
1
US
Hi,

In a Pivot fact column I need to count(distinct) of a column, but I want to ignore the null values, how can I do that.

Thank you in adavance.
Syamala.
 
Here's something to try:

if (CountNull (Column_name) > 0)
{CountDistinct (Column_name) - 1 }
else
{CountDistinct(Column_name) }
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top