Click on the Comments to view the Answers

Wednesday, January 27, 2010

Q27

The following SAS DATA step is submitted:

data work.accounting;
set work.department;
length jobcode $ 12;
run;

The WORK.DEPARTMENT SAS data set contains a character variable named JOBCODE with a length of 5. Which one of the following is the length of the variable JOBCODE in the output data set?

A. 5
B. 8
C. 12
D. The length cannot be determined as the program fails to execute due to errors.

16 comments:

SASGuru said...

Answer: A

Since SAS sees the jobcode to be 5 chars before it reads in the length statement…
If the length statement were before the set statement…then this would have set the length to 12 chars.
Try this…
data department;
jobcode='ABCDE';
run;

data work.accounting;
set work.department;
length jobcode $ 12;
run;

jaya said...

correct i agree with sasguru

Arunima Rana said...

A

Rujuta........ said...

answer is A

siva said...

Answer is D.Its fail to execute.

Unknown said...

ANS: is A

Ryan Lo said...

It has warning message as following:
WARNING: Length of character variable jobcode has already been set. Use the LENGTH statement as the very first statement in the DATA STEP to declare the length of a character variable.

But it is continue running. Length of variable Jobcode remains 5 bytes. Therefore the answer is A.

sujan kumar said...

A

Gaurav Verma said...

A

Stevina Rumao said...

Ans A

H. C. said...

A

H. C. said...
This comment has been removed by the author.
Vidya Bhushan said...

A

Harsh Mohan said...

For latest and updated SAS certification dumps in PDF format contact us at completeexamcollection@gmail.com.
Refer our blog for more details
http://completeexamcollection.blogspot.in/2015/12/sas-certification-dumps.html

Tek Classes said...

Answer: A
Very informative blog and content thank you for sharing with us keep postingsas training,sas online training,learn sas online,sas online course,sas training in bangalore

Harsh Mohan said...

For latest and updated SAS certification dumps in PDF format contact us at completeexamcollection@gmail.com.
Refer our blog for more details
http://completeexamcollection.blogspot.in/2015/12/sas-certification-dumps.html

Post a Comment



Technology Top Blogs On our way to 1,000,000 rss feeds - millionrss.com Hihera.com Blog Directory - OnToplist.com blogarama - the blog directory Blog Directory
Disclaimer

SAS and all other SAS Institute Inc. product or service names are registered trademarks or trademarks of SAS Institute Inc. in the USA and other countries. ® indicates USA registration.

Other brand and product names are trademarks of their respective companies.

This blog is not responsible for any kind of copyright violation. This blog just collects the links hosted or posted by other servers/people/search engines.The creator of this page or the ISP(s) hosting any content on this site take no responsibility for the way you use the information provided on this site.If anybody has any copyright claim on it and doesn’t wish the information provided to be shown on our site, please do respond to this email. We shall remove them off immediately. Any inconvenience is regretted. Please do mention your exact grievance/problems with respect to certain third party links. We assure you that appropriate action will be taken off. Thank you