BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hi


Finding distinct count with out using proc sql; and data step methods.

plz help me to resolve this issue.



Thanks and regards
Slone
7 REPLIES 7
deleted_user
Not applicable
Use this logic to identify .....create the new datasets using DUPkey ,NODUP ....option in existing data set ....create out data set which contains elimination of duplicated values....open the dataset DSID ...count no .of observations ..This is the think u need..

Any issues reply me..
Peter_C
Rhodochrosite | Level 12
Slone

thank you for telling us what not to use!

Perhaps you could tell us what languages / features we are allowed to use



along with some reason to (for nothing) when sql appears the natural choice.

PeterC
who is not a teacher.
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Suggestion to Peter.C -- go easy -- clearly, the OP is looking for various options to achieve a specific result (generate a set / count of distinct variable values), although not necessarily within your personal interest area(s). Better to contribute when providing some idea, suggestion, or question (for clarification) -- rather than just being critical.

The SAS language is quite challenging and powerful, as some know and others have heard, so interest on the forum to increase one's arsenal of SAS solution techniques through self-training, formal education and discussion forums, is quite reasonable.


Scott Barry
SBBWorks, Inc.
Peter_C
Rhodochrosite | Level 12
SBB

please feel free to rtfm on behalf of others.

I would like to encourage posters to explain the context for such constraints. Otherwise we appear to be answering and thwarting teachers questions designed to promote learning through the posters' personal effort.

I expect you are right and I should be more gentle.
How, gently, would you encourage the poster of a teachers's question, to do "the rtfm"?

PeterC
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
We are in total agreement that there is a lacking interest by some posters on this forum to learn by first considering the R-T-F(ine)-M approach -- instead some individuals care more to just get the answer. Considering the wealth of "hosted" documentation and technical reference information provided by SAS Institute, as well as SAS System Help resources, one would expect at least a cursory attempt to find an answer or suitable response before generating a post. For some, possibly, and for others, likely not.

Scott Barry
SBBWorks, Inc.
deleted_user
Not applicable
Hi peter.c

thanks for giving response.

i am trying to solve this issue because of the data is 100GB. and 500 variables.
if i run proc sql for distinct count it has taken more time. thats why i am searching for alternate solution. By using proc freq ; i got count with less time than proc sql;

Thanks & Regards
slone
Not a Student
Peter_C
Rhodochrosite | Level 12
Slone

thank you for adding the information describing why you asked for a non-sql and non-datastep solution.

It may have been possible to define an sql query so that it ran as efficiently as proc freq. I expect the same is true of a data step approach. However, without the information about data size (number of observations, total size and key definitions) we cannot provide optimisation.

I'm glad you have found a practical solution.

kind regards

PeterC
( who is sorry he misinterpreted your first question )

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 7 replies
  • 822 views
  • 0 likes
  • 3 in conversation