Create DTS and output to a SAS data format

  • Hi,

    I am new to SAS and I have a SAS 9.1.3XP_PRO platform installed. I need to create a DTS with SAS format. The questions I have are how do I connect SAS to SQL 2000 in the DTS and output to a SAS format ? Which I icon do I use to call the SAS? Any examples is apprecicated. Please advise. Thanks.

  • Hi,

    I've never used SAS but can you set up a System DSN pointing to the SAS source on your Sql Server machine? If so you should be able to use the "Other Connection" (the last one on the connections list) to connect through the DSN.

    * Edit *

    You can download ODBC drivers for SAS from http://www.sas.com/apps/demosdownloads/setupcat.jsp;jsessionid=06AA4C460FDCB834A8E83BEF348ACB18.tomcat4?cat=ODBC+Drivers to set up the DSN.



    Ade

    A Freudian Slip is when you say one thing and mean your mother.
    For detail-enriched answers, ask detail-enriched questions...[/url]

  • Is there a way to invoke the SAS to pick up the .csv file and convert to SAS .xpt format from the DTS? Anybody?

  • Theres an article on creating a SAS program to read a csv file here:

    http://www.ts.vcu.edu/faq/stats/sasexcel.html

    Once set up you might be able to execute that using the SAS command line. If that is possible then you can use the Execute Process Task within DTS.



    Ade

    A Freudian Slip is when you say one thing and mean your mother.
    For detail-enriched answers, ask detail-enriched questions...[/url]

  • Hi Adrian,

    That import wizard helps a lot but it did not show me how to execute the SAS command line. any dieas? Thanks.

  • I think it's something like:

    dimport  "filename.csv" targetDataset

    As far as I am aware, the csv file needs to be tab delimited though.



    Ade

    A Freudian Slip is when you say one thing and mean your mother.
    For detail-enriched answers, ask detail-enriched questions...[/url]

  • Hi Adrian,

    Any ideas after importing the csv file through import wizard and modified the formats dataset, is there a way to generate the create script from the SAS? Please advise. Thanks.

     

  • I don't know TBH. As I said I've never used SAS just read a book or two .

    I'll see if I can find out.



    Ade

    A Freudian Slip is when you say one thing and mean your mother.
    For detail-enriched answers, ask detail-enriched questions...[/url]

  • Thanks. Let me know if you find out the answer to generate the create script. By the way if you do not know SAS how did you know the command line to invoke SAS? Just curious.

  • Just reading books... Maybe I should get out more!



    Ade

    A Freudian Slip is when you say one thing and mean your mother.
    For detail-enriched answers, ask detail-enriched questions...[/url]

Viewing 10 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic. Login to reply