Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the purpose of the trailing and How would you use them?

Answer Posted / sandhya

The trailing @ or more technically, line hold specifiers
are used to hold the pointer in the same record for
multiple iterations. The two tyoes of line hold specifiers
are single trailing(@) and double trailing(@@).

The single trailing hold the record until it encounters
either another input statement or end of the datastep.
They are used for the records such as

001F38 H
002 F 40 G

To read these values to the datastep

Data example;
input @10 type $ @;
if type='H' then
input @1 id 3. @4 gender $1. @5 age2.;
else if type='G' then
input @1 id3. @5 gender $1. @7 age 2.;
end;
cards;
001F38 H
002 F 40 G
;
run;

The double trailing holds the until the end of the record.

Data example2;
input id age @@;
cards;
001 23 002 43 003 65 004 32 005 54
;
run;

Is This Answer Correct ?    19 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what do the sas log messages "numeric values have been converted to character" mean? : Sas programming

1030


How might you use MOD and INT on numeric to mimic SUBSTR on character Strings?

1370


What is a method to debug and test your SAS program?

1365


What is the basic syntax style in SAS?

1166


what is the difference between nodup and nodupkey options? : Sas programming

1187


what has been your most common programming mistake? : Sas programming

1105


What is the difference between the proc sql and data step?

1173


Explain the purpose of retain statement.

1052


What is the difference between where and if statement?

1113


what is hierarchy flattening? : Sas-di

1078


Will it bother you if the guy at the next desk times the frequency and duration of your bathroom or coffee breaks on the grounds that ?you are getting paid twice as much as he is??

2612


Give some ways by which you can define the variables to produce the summary report (using proc report)?

1089


What is the role of sas grid administrator? : sas-grid-administration

1285


what are the considerations when picking a SAS/STAT procedure?

3373


How would you include common or reuse to be processed along with your statements?

2368