Buyingid Customerid purchasedate City numunits numorderlines
1232 121211 12OCT09 Farifield 45 1
1233 353412 15OCT09 Newyork 1 1
1234 343121 30NOV12 Japan 2 1
Question: Display only the customerid and firstname.
You should filter the buying dataset using the buyingid variable prior to the inner join. Take a look at the "where" clause for sql.
Your code seems incorrect.
You would first filter your table 2 based on purchase and then get the corresponding names from table 1.
Given your question and data, I'm not sure how you'd filter as there isn't an item code that I can see.
Is there a reason you're not doing this entirely within SQL?
Thanks.
You should filter the buying dataset using the buyingid variable prior to the inner join. Take a look at the "where" clause for sql.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.