Quantcast
Channel: SCN : Unanswered Discussions - ABAP Development
Viewing all articles
Browse latest Browse all 8768

How to get the no of distinct values of each colum of a table?

$
0
0

Hello community,

what we are in need of is a Little program being able to derive the number of distinct values in each column of a freely defined table.

 

As I know, the SELECT COUNT (DISTINCT col) statement exactly does that for a specified column.

 

However, we are now in need to dynamically execute this in a loop in order to reach every column.

But, unfortunately, the mentioned SQL statement does not allow a dynamic Operator for specifiying the column :-(.

 

That's why I'm now asking you if anybody got an idea how to manage this or, alternatively, use another Approach (maybe anybody already got a "ready to work" program for that issue?)

 

Thanks & regards,

bivision


Viewing all articles
Browse latest Browse all 8768

Trending Articles