BookmarkSubscribeRSS Feed
Pandu
Fluorite | Level 6

Hi,

I have a dataset as below:

Pandu_0-1646296328400.png

i want to write a query when calander_week is same and repli_flag 1, 0 then i want to pick Repli_flag 0 values and need to drop repli_flag 1.

 

Thanks in advance

2 REPLIES 2
Kurt_Bremser
Super User

Please post example data in usable form, which means a data step with datalines. Pictures are useless, as we cannot reliably determine data types, lengths, formats and raw values.

On top of that, we would have to type everything in by hand for testing code suggestions; we are not your typists.

ballardw
Super User

@Pandu wrote:

Hi,

I have a dataset as below:

Pandu_0-1646296328400.png

i want to write a query when calander_week is same and repli_flag 1, 0 then i want to pick Repli_flag 0 values and need to drop repli_flag 1.

 

Thanks in advance


When calander_week is same as what? Same as today? Same as the last time I got a haircut? You have to indicate what values are compared.

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