Kindly assist in resolving the warning issue
WARNING: The variable CTR1N exists on an input data set and is also set by an I/O statement option. The variable will not be included on any output data set and unexpected results can occur.
Show us the ENTIRE log for this DATA step or PROC.
Advice: never show error messages detached from the code that created them. That's why we want to see the entire log for the DATA step or PROC.
Hi @Tejaswini3,
Performing a web search for the first sentence of the message looks like it gives the scenario under which this occurs:
http://support.sas.com/kb/33/112.html
If this does not cover your scenario then please provide details as advised by @PaigeMiller.
Kind regards,
Amir.
The question is do you want the variable in your output data set?
This warning says the variable already exists in the data set. I assume the data set is on a SET (merge, update or modify) statement and you have used a dataset option creating a temporary variable of the same name such as with the IN= option. Temporary variables are not written to the output and since you have reused a variable name that also means the existing values of the variable have been overwritten by the option.
So, what do you expect? If you expect the variable to be in the output data set then use a different temporary variable for the option.
Large economy sized hint: Include entire procedure or data step code along with all the messages, notes, warnings. Copy from the log all of the related text then on the forum open a text box using the </> and paste all of it.
In this case I would then be able to point to exactly which usage is causing the warning.
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
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.
Ready to level-up your skills? Choose your own adventure.