BookmarkSubscribeRSS Feed
ASHISH2525
Quartz | Level 8

Hi all,

 

i want to build a logic for getting attached output.

 

I have some specific rows in a column where i want to assign them a flag in a particular pattern. Please refer attached screenshot for desired output. Overall detailed & overall procurement are the keys rows. from overall detailed all the above values should be flag 1 and from overall procurement all the above values should be flag 2

 

Here comes the interesting part, Flag should be dynamic so that when ever a new value is being insert automatically flag generate.

 

 

Regards,

Ashish

3 REPLIES 3
Onizuka
Pyrite | Level 9

Hello,

 

If you want people answer to your request :

 

- You should not put attach files because some people can't open it

- You have also to create a dataset representative of your datas (what you HAVE) and a picture for example of what you WANT

 

Onizuka

ballardw
Super User

What does your starting data set look like?

Do the values of "group" shown cover all the possible values of group that will ever be encountered?

What are the rules for assigning the value of Flag? i.e. What is the rule for determining the pattern? This is very important if the answer to the above question about group values is "no".

 

What do you mean by "dynamic" in this sense? Dynamic usually refers to code that changes based on the data or some routine. So what would change? How would we know that it changed?

ASHISH2525
Quartz | Level 8

Hi ballardw,

 

Thanks for your valuable inputs. However i have resolved the issue. 

 

 

 

Regards,

Ashish

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

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
  • 3 replies
  • 447 views
  • 0 likes
  • 3 in conversation