CORE
mp_ds2cards.sas File Reference

Create a CARDS file from a SAS dataset. More...

Go to the source code of this file.

Detailed Description

Create a CARDS file from a SAS dataset.

Uses dataset attributes to convert all data into datalines. Running the generated file will rebuild the original dataset. usage:

mp_ds2cards(base_ds=sashelp.class , cards_file= "C:\temp\class.sas" , maxobs=5)

stuff to add

  • labelling the dataset
  • explicity setting a unix LF
  • constraints / indexes etc
Parameters
base_ds=Should be two level - eg work.blah. This is the table that is converted to a cards file.
tgt_ds=Table that the generated cards file would create. Optional - if omitted, will be same as BASE_DS.
cards_file=Location in which to write the (.sas) cards file
maxobs=to limit output to the first maxobs observations
Version
9.2
Author
Allan Bowe https://github.com/macropeople/macrocore

Definition in file mp_ds2cards.sas.