what is the difference between x=substr(name,1,2);
and substr(name,1,2)='x';
Answer Posted / oanhntt
x=substr(name,1,2) means you assign x value equal to the
first 2 characters of variable "name" while
substr(name,1,2)='x' just compare these fist 2 characters to
value 'x', so this seem useless without condition syntax
(correct one should be: if substr(name,1,2)='x' then /*do
some thing*/;).
| Is This Answer Correct ? | 4 Yes | 16 No |
Post New Answer View All Answers
Of all your work, where have you been the most successful?
What do you know about sas data set?
What is the role of unrestrictive users? : sas-grid-administration
What is the basic structure of the SAS base program?
How would you code a merge that will write the matches of both to one data set, the non-matches from the left-most data?
To what type of programms have you used scratch macros?
If money were no object, what would you like to do?
Explain substr function?
why is sas considered self-documenting? : Sas programming
Mention the difference between ceil and floor functions in sas?
how can you put a "trace" in your program? : Sas programming
What is PDV?
How will you use the WHO Drug Dictionary for Reporting Clinical Trials?
what is sas database server? : Sas-di
What is the role of administrative users? : sas-grid-administration