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...

There is a field containing a date. It needs to be
displayed in the format
"ddmonyy" if it's before 1975,
"dd mon ccyy" if it's after 1985, and
as 'Disco Years' if it's between 1975 and 1985.
How would you accomplish this in data step code? Using
only PROC FORMAT

Answer Posted / vijs

data new ;
input date ddmmyy10. ;
cards;
01/05/1955
01/09/1970
01/12/1975
19/10/1979
25/10/1982
10/10/1988
27/12/1991
;
run;

proc format ;

value dat low-'01jan1975'd=ddmmyy10.
'01jan1975'd-'01JAN1985'd="Disco Years"
'01JAN1985'd-high=date9.;
run;

proc print;
run;

proc print;
format date dat. ;
run;

Is This Answer Correct ?    3 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how you can debug and test your SAS program?

1053


How can you create a macro variable with in data step? : sas-macro

1092


What is the difference between input and infile statement?

1229


What are SAS/ACCESS and SAS/CONNECT?

1194


List out some key concept of SAS

1216


How do you add a number to a macro variable? : sas-macro

1053


What are types of transport files?

8089


What is maximum number of rows and cols can be handled in SAS?

1674


If you were told to create many records from one record, show how you would do this using array and with proc transpose?

1546


What are the features of base sas system?

1113


what are some problems you might encounter in processing missing values? In data steps? Arithmetic? Comparisons? Functions? Classifying data? : Sas programming

1296


What does P-value signify about the statistical data?

1403


What is a pdv and what are its functions?

1221


what versions of sas have you used (on which platforms)? : Sas programming

1134


What is the difference between SAS functions and procedures?

1187