BookmarkSubscribeRSS Feed
Ronein
Meteorite | Level 14

Hello

What is the reason and meaning of using @ symbol?

I see that:

date1 is in location1-6 

date2 is i location8-15

date3 is i location17-26

Why do we use @6 @13 @22?

DATA inputdates1;
     INPUT @6 date1 mmddyy6. @13 date2 mmddyy8. @22 date3 mmddyy10.;
	 FORMAT date1 date9. date2 date9. date3 date9.;
	 DATALINES;
     042708 04-27-08 04 27 2008
	 ;
RUN;
2 REPLIES 2
SASKiwi
PROC Star

Read up on formatted input with the INPUT statement: https://documentation.sas.com/?cdcId=pgmsascdc&cdcVersion=9.4_3.3&docsetId=lestmtsref&docsetTarget=p...

 

Bookmark: https://documentation.sas.com and start exploring for yourself. You will find answers faster that way.

Kurt_Bremser
Super User

@Ronein wrote:

Hello

What is the reason and meaning of using @ symbol?

I see that:

date1 is in location1-6 


Wrong. Position the cursor under the beginning of date1, and the status line of the Enhanced Editor will tell you that you are in column 6.

Datalines ALWAYS start at position 1, not at the indentation deliberately selected by the programmer.

Hint: NEVER indent datalines.

SAS Innovate 2025: Call for Content

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!

Submit your idea!

How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 469 views
  • 0 likes
  • 3 in conversation