Help using Base SAS procedures

Help reading sas code as input for datalines

Reply
Contributor
Posts: 29

Help reading sas code as input for datalines

I need to read a sas code in datalines;

My input goes like this.

%let _v1  = mapping_var1 ; /*  comment about mapping variable */

data old_new;

input string $200;

datalines ;

%let _v1  = mapping_var1 ; /*  comment about mapping variable */

%let _v1  = mapping_var2 ; /*  comment about mapping variable */

;

I need to have output like this

old new

_v1  mapping_var1

_v2  mapping_var2

The problem is i'm not able to create "string" from the above code

Any help on this would be greatly appreciated.   Is it becase sas code, that it cannot recognize as valid string for input?

Contributor
Posts: 29

Help reading sas code as input for datalines

I got it thanks. used datalines4, along with infile options.

Ask a Question
Discussion stats
  • 1 reply
  • 114 views
  • 0 likes
  • 1 in conversation