f



Re: Reading SAS files from other programs #2

Hi Mark,

Have a look at the database converters DBMS/copy (Dataflux) and
StatTransfer.

Regards - Jim.
--
Jim Groeneveld, Netherlands
Statistician, SAS consultant
home.hccnet.nl/jim.groeneveld


On Thu, 27 Apr 2006 12:56:57 -0400, Coleman, Mark
<Mark.Coleman@LIBERTYMUTUAL.COM> wrote:

>Greetings,
>
>I am a regular user of Mathematica from Wolfram Research, and a new user
>of SAS. I'm exploring the feasibility of reading native SAS files
>directly from Mathematica. Are native SAS files based upon SQL, or is
>some other proprietary file structure used? If so, does SAS offer some
>sort of ODBC driver?
>
>Thanks,
>
>Mark
0
jim2stat (828)
4/27/2006 5:46:17 PM
comp.soft-sys.sas 142828 articles. 3 followers. Post Follow

0 Replies
428 Views

Similar Articles

[PageSpeed] 23

Reply:

Similar Artilces:

Re: Running a SAS program within a SAS program #2
Kathleen Based on your subject, my immediate impulse was %inlude() where you put a fileref in the quotes. However, I think you want to do something else. You say that you have individual programs that produce a set for each year. Do you store these sets somewhere or do you run the programs when you want data for a given year. I would suggest that you first get a collection of these yearly sets and run a contents on each one. Then, write a program similar to Data mylib.combined; set mylib.year1(rename = (Dates = Date ....)) mylib.year2(rename= (Sdates=Date....)) ..... ; The idea would be to get rid of the variations in the variable names. You could simply copy in the individual programs into one honking big program and keep running this until you get a uniform combined set but you will use a lot of machine cycles doing this. Assuming that you have to make several passes at the data in order to get things right, I would work from stored data sets where all you are doing is changing the rename statements. Good luck Nat Wooding Environmental Specialist III Dominion, Environmental Biology 4111 Castlewood Rd Richmond, VA 23234 Phone:804-271-5313, Fax: 804-271-2977 Kathleen Santos <flowerpotcat@GMA IL.COM> To Sent by: "SAS(r) SAS-L@LISTSERV.UGA.EDU Discussion" cc <SAS-...

Re: Running SAS programs from within a SAS program #2
Or better when programs are in one directory file code "drive:\your_folder\" ; %inc code ( prog1 prog2 prog3 ... ) ; Then the next step is parameter driven macros in an autocall library. %prog1(parm1=...) %prog2(alpha=...) ..... Ian Whitlock ================= Date: Fri, 18 Nov 2005 22:54:54 -0500 Reply-To: mah-j@statworks.com Sender: "SAS(r) Discussion" From: "mah-j@statworks.com" <msoobader@VERIZON.NET> Subject: Re: Running SAS programs from within a SAS program Comments: To: "Keith W. Larson" <keith_w_larson@YAHOO.COM> In-Reply-To: <20051119033140.88868.qmail@web51405.mail.yahoo.com> Content-type: text/plain; charset=iso-8859-1 Keith, You can use a series of %include statements naming the programs in the order you want to call them in. %include "drive:\your_folder\program name.txt" ; Mah-J M. Soobader, PhD Principal consultant STATWORKS www.statworks.com -----Original Message----- From: SAS(r) Discussion [mailto:SAS-L]On Behalf Of Keith W. Larson Sent: Friday, November 18, 2005 10:32 PM To: SAS-L Subject: Running SAS programs from within a SAS program Dear All, I have several small(ish) SAS programs that convert and format DBF files. Thanks to all who helped solve formatting problems. I would like to create a master SAS program that calls each one in sequence. Any ideas? Cheers, Keith ______________________...

Re: SAS Advanced Programming Exam for SAS 9: SAS Joke of the year. #2
jontugman, Test preparation is akin to following a simple algorithm: 1. Evaluate the test and discover if it is worth taking. 2. If #1 evaluates false then go to exit. 3. Determine if your *test* knowledge of SAS is insufficient. 4. If #3 evaluates true, do the test preparation. 5. Pay the money. 6. Take the test. 7 Exit. From your standpoint, the step of paramount importance is step #1. That is where you mainly failed. From SAS' standpoint, only one step matters: #5. This is the only reason the test was created in the first place. The world would be a better place if all employers understood that as well. However, some recruiters/HRers require the certificate as a CYA backup should they accidentally hire a pure test-passer. Fortunately, I have not seen many occurrences of this nature since the inception of the boondoggle, perhaps because most candidates are almost inevitably interviewed by people qualified in SAS better than HR. And most qualified people saw the program for what it is even before its advent. SAS-L is replete with numerous posts to prove it. Needless to say, it does not imply in any way that any certificate-holder has no more SAS behind the belt than the certificate can cover. Far from that! Many fantastic real-world people have been forced into the thing by their SAS partnership business needs, many have taken it just for the heck of it because their employer would pay for it, etc. My opposition to the thing as a matter of principle is based on t...

Re: Can a SAS program call another SAS program #2
Dave, What you want to do can be done with %include. Bob Abelson HGSI 240 314 4400 x1374 bob_abelson@hgsi.com David Fickbohm <DavidF@HOMEGAIN.COM> Sent by: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU> 10/15/2004 04:05 PM Please respond to David Fickbohm To: SAS-L@LISTSERV.UGA.EDU cc: Subject: Can a SAS program call another SAS program People, I am writing a report that counts the number of widgets produced by partners. I have a small routine that finds the partners id number and name. Obviously I could copy this code into my...

Re: Easiest way to make sure 2 sas programs (2 files) are the same? #2
I think it only copies and only on UNIX. Igor Kurbeko Clinical Programmer Analyst 678 336 4328 ikurbeko@atherogenics.com If you torture data sufficiently, it will confess to almost anything. -----Original Message----- From: Pardee, Roy [mailto:pardee.r@GHC.ORG] Sent: Friday, January 28, 2005 2:45 PM To: SAS-L@LISTSERV.UGA.EDU Subject: Re: Easiest way to make sure 2 sas programs (2 files) are the same? cp myfirstprog.sas mysecondprog.sas LOL--sorry, couldn't resist. -----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Igor Kurbeko Sent: Frida...

Re: Unable to read Unicode file into SAS file
Another possibility is that proc import isn't correctly getting the right formats and informats. If you already know what those formats and informats should be, you can always copy, paste and edit (from the log) the data step that resulted from the proc import run, adjusting any incorrect formats and informats and then just run it as a data step. Also, while I don't think it would make any difference, your proc import contains two "datafile=chr" statements. Art -------- On Tue, 19 Jan 2010 21:06:11 +0530, Cherish K <c4cherish@GMAIL.COM> wrote: >From MS SQL, I ext...

Re: Is there a system option for OpenVMS SAS version 8 where a sas program can create an output file with a file attribute of "Stream_LF" so that these external files c
Charles Patridge <charles_s_patridge@PRODIGY.NET> wrote: > Is there a system option for OpenVMS SAS version 8 where a sas program can > create an output file with a file attribute of "Stream_LF" so that these > external files can be served through an Apache WebServer properly? > > Currently, what happens is when we create a CSV file, the Apache Webserver > wants to load the contents of this CSV file into a single cell for Excel. > That is, all OBS are treated as a SINGLE record and all the contents is > loaded into a single cell within Excel. > > T...

Re: Easiest way to make sure 2 sas programs (2 files) are the same?
cp myfirstprog.sas mysecondprog.sas LOL--sorry, couldn't resist. -----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Igor Kurbeko Sent: Friday, January 28, 2005 11:36 AM To: SAS-L@LISTSERV.UGA.EDU Subject: Easiest way to make sure 2 sas programs (2 files) are the same? Hi, guys. Dose anybody know an easy way to check 2 files (2 SAS programs) for being identical? Thanks Igor Kurbeko Clinical Programmer Analyst 678 336 4328 ikurbeko@atherogenics.com Amateurs hope, professionals work ...

Re: Autoexec.sas file Dm"pgm;zoom;"; doesnot wrk in SAS 9.2 #2
Hi Ace, The PGM is the editor window up through v6.12 but also still exists today. For the Enhanced Editor you can use: dm editor 'zoom' wedit ; Hope this is helpful. Mark Terjeson Investment Business Intelligence Investment Management & Research Russell Investments 253-439-2367 Russell Global Leaders in Multi-Manager Investing -----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Ace Sent: Wednesday, October 14, 2009 5:49 AM To: SAS-L@LISTSERV.UGA.EDU Subject: Re: Autoexec.sas file Dm"pgm;zoom;"; doesnot wrk in SAS...

Re: Easiest way to make sure 2 sas programs (2 files) are the same? #3
On Fri, 28 Jan 2005 14:35:42 -0500, Igor Kurbeko <ikurbeko@ATHEROGENICS.COM> wrote: >Dose anybody know an easy way to check 2 files (2 SAS programs) for >being identical? Hi, Igor, As long as they are text files, use "diff" to compare them. Diff is found on almost all unices and there are number of Windows ports, too. Cheers, Chang ...

Re: how to read this file into sas #2
Read the file in its orginal form and Proc Transpose is one alternative... On Thu, 14 Sep 2006 17:09:52 -0700, liuyuanpku@GMAIL.COM wrote: >Hi, I just got a problem to read a txt file into sas. The structure of >the data in txt file is: > >family member >1 3809 3810 3811 3812 >2 3814 3815 3816 >3 3817 3818 3819 3820 > >When I read it into sas, I want it in the following structure: >family member >1 3809 >1 3810 >1 3811 >1 3812 >2 3814 >2 3815 >2 3816 >3 3817 >3 3818 >3 3819 >3 3820 > >How can I get this sas data? >Thanks a lot! ...

Re: Reading SAS files from other programs
Mark, SAS dataset layout is proprietary and unknown. SAS provides both ODBC and OleDB drivers for reading the datasets. Alan Alan Churchill Savian "Bridging SAS and Microsoft Technologies" www.savian.net -----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Coleman, Mark Sent: Thursday, April 27, 2006 10:57 AM To: SAS-L@LISTSERV.UGA.EDU Subject: Reading SAS files from other programs Greetings, I am a regular user of Mathematica from Wolfram Research, and a new user of SAS. I'm exploring the feasibility of reading native SAS files directly from Mathematica. Are native SAS files based upon SQL, or is some other proprietary file structure used? If so, does SAS offer some sort of ODBC driver? Thanks, Mark ...

Re: Easiest way to make sure 2 sas programs (2 files) are the sam e?
On my MVS ISPF 3.12 is the SuperC Compare Utility. Paul Choate DDS Data Extraction (916) 654-2160 -----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of = Harry Droogendyk Sent: Friday, January 28, 2005 11:57 AM To: SAS-L@LISTSERV.UGA.EDU Subject: Re: Easiest way to make sure 2 sas programs (2 files) are the = same? Use UNIX 'diff', DOS 'comp' or 3.something in MVS. Help text for = 'comp' is below. Compares the contents of two files or sets of files. COMP [data1] [data2] [/D] [/A] [/L] [/N=3Dnumber] [/C] data1 Specif...

Re: Is it possible to read a sas dataset NOT using sas? #2
I think SPSS and DBMSCopy can read SAS datasets. Also for sure WPS. Gerhard On Tue, 18 Mar 2008 06:43:44 -0700, RolandRB <rolandberry@HOTMAIL.COM> wrote: >Is it possible to read a sas dataset NOT using sas and have >observations and variables etc. rather than having meaningless chunks >of text? ...

Re: Opening non SAS files with BASE SAS ? #2
Hi, If, when you check your licensing(i.e. SETINIT) proc setinit; run; in SAS, if you have SAS/ACC-ODBC, then you can easily setup an ODBC entry in your Windows ODBC Wizard to your SQL Server. After doing that you can run the SQL Server query from SAS directly to SQL Server and have the result come right directly back into SAS into a SAS dataset. See the couple archive links below for syntax details. http://listserv.uga.edu/cgi-bin/wa?A2=ind0709C&L=sas-l&P=R12721 http://listserv.uga.edu/cgi-bin/wa?A2=ind0105D&L=sas-l&P=R13103 The X command in SAS can run external commands but the SQL-passthrough is what most of us use. Hope this is helpful. Mark Terjeson Senior Programmer Analyst, IM&R Russell Investments Russell Investments Global Leaders in Multi-Manager Investing -----Original Message----- From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of anderson115@GMAIL.COM Sent: Wednesday, October 10, 2007 12:43 PM To: SAS-L@LISTSERV.UGA.EDU Subject: Opening non SAS files with BASE SAS ? Is there a function that executes a non SAS file? I've written a macro that outputs a file with the extention SQL (EXE would also be helpful). *.SQL files are associated with SQL server on my computer so I'd like to make SAS execute this file so it triggers the SQL server program. Is this possible? Thank You, Aaron ...

Re: run a SAS program before SAS session starts #2
Masoud; That's what autoexec.sas is for. Look it up in the documentation. Ed Edward Heaton, Senior Systems Analyst, Westat (An Employee-Owned Research Corporation), 1650 Research Boulevard, TB-286, Rockville, MD 20850-3195 Voice: (301) 610-4818 Fax: (301) 294-2085 mailto:EdHeaton@Westat.com http://www.Westat.com -----Original Message----- From: owner-sas-l@listserv.uga.edu [mailto:owner-sas-l@listserv.uga.edu] On Behalf Of mpajoh@ODOT.ORG Sent: Tuesday, November 27, 2007 4:17 PM To: SAS-L@LISTSERV.UGA.EDU Subject: run a SAS program before SAS session starts How can I run a SAS program every time before the interactive session starts? Masoud I use SAS 9.1.1.3 on XP. ...

Re: how to read gzip file in SAS #2
Hi, Howard, How to debug gunzip? Install *GNU Tar* and *GNU GZip* for Windows. Added "C:\Program Files\GnuWin32\bin" to my Path System variable by going to Control Panel--> System Properties --> Advanced Tab--> Environment Variables Did I added wrong path? Thanks. Best, Rong On 11/1/07, Howard Schreier <hs AT dc-sug DOT org> <nospam@howles.com> wrote: > > On Thu, 1 Nov 2007 12:21:58 -0400, wraong <wrong.wang@GMAIL.COM> wrote: > > >Hi,all, > > > >I need to read gzipped files. I tried with filname command as bellow: > > > >filename medpar pipe 'gunzip -c E:\seer_med\200501\medpar91.txt.gz'; > >/*reading in a zipped file*/ > > > >In the log file, it said "'gunzip' is not recognized as an internal or > >external command, > >operable program or batch file." > > > >How can I solve the problem? > > > >Thanks for kind help. > > > >Best, > >Rong > > I don't think it's a SAS problem. Debug your GUNZIP invocation from a host > OS command line. > ...

Re: read excel files into SAS #2
A quick way to solve it is to use DDE, which you can specify the first row to be read as data and specify the informat as well. HTH. On 8/8/05, Joan Zhao <jlin104@hotmail.com> wrote: > I found a problem when I read a excel file into SAS. The initial seceral > rows(more than 8 rows) of one of the column in this file are blank and then > follwed by numeric numbers. In this column, most cells are empty. When SAS > read in this file by no matter what approach(SAS/ACCESS--import procedure > or OLEDB), nothing in this column is read in. The generated SAS dataset is > empty. If I change the whole column's datatype to character(text) in excel, > then problem is solved. Or if I fill in a numeric number within first 8 > rows, then the whole column can be read in as well. But if I fill in the > number after 8th row, then nothing is read in. > > Does anybody know what's going on? Why cannot the data be read in if the > data is numeric and with first 8 rows blank? Thank you in advance! > > Joan Zhao > -- WenSui Liu, MS MA Senior Decision Support Analyst Division of Health Policy and Clinical Effectiveness Cincinnati Children Hospital Medical Center ...

Re: Reading SAS files from other programs #3
Hi Mark, In addition to my previous reply I can add, that though the SAS dataset specification is proprietary, not published and officially unknown, other software vendors have succeeded in analyzing it to read SAS datasets directly. The original author of DBMS/copy, Henry Feldman, did so a long time ago already, and his software has been used widely. Now that his company has been bought by SAS that 'problem' has disappeared. Something similar happened to the software package JMP, which already was and is able to read SAS transport files, and as far as I remember also reads SAS datasets directly (but I'm not sure). Furthermore I don't know if e.g. SPSS or S are able to read SAS datasets directly, but it might be worthwhile if they once would. An additional complication while reading the datasets is that you also would need the associated formats. Reading (or converting) SAS format catalogs seems to be more difficult. DBMS/copy handles formats if they are available in source code, I believe. And finally there is a very nice and free solution to read SAS datasets and convert them to anything else. That is using the freely available (from www.sas.com or support.sas.com) SAS viewer (either vs. 8 or vs. 9). It does not support user defined formats, but if formats with long format names are associated to variables in the dataset it nevertheless refuses to load the dataset, a significant bug. But it displays the dataset nicely as a spreadsheet. Then you can mark t...

Re: Reading RTF files with SAS #2
Jake, I've never looked at the macro, but take a look at: www2.sas.com/proceedings/sugi31/066-31.pdf Art -------- On Wed, 18 Mar 2009 18:32:33 -0400, Jake <johbee@GMAIL.COM> wrote: >Does anyone know if SAS can read RTF files? The reason I need >to do this is to get a list of Titles from all the output in a bundled rtf >vs. doing it manually. > >Thanks, for any information (publications, etc) > >Jake ...

Re: Reading PDF Files into SAS #2
Mona You have received several responses that speak of using some external tool to do a pdf to text conversion and then, presumably, you would parse the text with SAS. These responses depend on the PDF having been produced by a pdf writer and not by the file being a scanned image. In the later case, you would need to use an OCR reader to convert the pictures to text. Do you need to do only a few conversions or many and will this be an ongoing task? If you are only going to do an occasional conversion, I would use the Save As Text which is found in Adobe Acrobat Reader 7.0 and maybe earlier. However, if this is a larger project, I would (and have) used an external program to do the conversions. I have a paper from several years ago posted at http://www.vasug.org/Proceedings/2003-02/Presentations/EXTRACTING%20DATA%20FROM%20PDF%20FILES.doc This describes how I used a tool that converted one pdf at a time and controlled this from within the SAS program. Since that time, I have had a similar project and was not able to get the pdf converter that I used earlier to work. However, I found one available on line that converted all of the pdfs in a folder in one pass I was able to eliminate all of the SAS calls that ran the external process. I ran that particular job from home since there are restrictions on using unapproved tools here at work and I do not recall the name of the converter. Good luck. Nat Wooding Environmental Specialist III Dominion, Environmental Biology 4111 Ca...

Re: Reading SAS files from other programs #4
JMP started as a SAS-like Macintosh product at SAS when they had a demand for a product on the Mac platform but apparently did not want to try a full port. The joke around SUGIs was that JMP stood for John's Macintosh Product. The "John" being John Sall who lead the effort at SAS. Nat Wooding Jim Groeneveld <jim2stat@YAHOO.C O.UK> To Sent by: "SAS(r) SAS-L@LISTSERV.UGA.EDU Discussion" cc <SAS-L@LISTSERV.U GA.EDU> Subject Re: Reading SAS files from other programs 04/28/2006 03:40 AM Please respond to Jim Groeneveld <jim2stat@YAHOO.C O.UK> Hi Mark, In addition to my previous reply I can add, that though the SAS dataset specification is proprietary, not published and officially unknown, other software vendors have succeeded in analyzing it to read SAS datasets directly. The original author of DBMS/copy, Henry Feldman, did so a long time ago already, and his software has been used widely. Now that his company has been bought by SAS that 'problem' has disappeared. Something similar happened to the software package JM...

Re: Unix SAS: How to save log file while in SAS session? #2
On Wed, 18 Aug 2004 12:18:03 -0500, Duck-Hye Yang <dyang@CHAPINHALL.ORG> wrote: >Hello, > >I am using SAS Unix Display manager. >I put together single small sas programming files in one giant sas programming file. >I need to save log and output files AFTER each single small programming file. >The problem is that I do not know how to save log and output while in SAS session. > >Below is the outline of what I'd like to do: > > >DM 'clear log'; >DM 'clear output'; >SAS 1 programming start here >end here >x 'file "SAS...

Re: Running a SAS program within a SAS program
%include() On Mon, Apr 21, 2008 at 12:55 PM, Kathleen Santos <flowerpotcat@gmail.com> wrote: > Hello, > > I would like to combine multi years of data into one. Each year has a > particular data set and a particular program to create a SAS dataset. > However, not all programs are the same (e.g. variable names may change > throughout the years). > > What I would like to do is to create one program that would call on the > other programs to create SAS datasets. Then I'll integrate them together and > do whatever I it is I need to do. > > I hope someone can help me. > > Thanks. > > Kathleen > -- =============================== WenSui Liu ChoicePoint Precision Marketing Phone: 678-893-9457 Email : wensui.liu@choicepoint.com Blog : statcompute.spaces.live.com =============================== ...

Web resources about - Re: Reading SAS files from other programs #2 - comp.soft-sys.sas

Program - Wikipedia, the free encyclopedia
Text is available under the Creative Commons Attribution-ShareAlike License ;additional terms may apply. By using this site, you agree to the ...

Government reveals changes to controversial Safe Schools program
The federal government has unveiled changes it wants made to a controversial anti-bullying program in schools.

SeaWorld says it will end killer whale breeding program - CBS News 8 - San Diego, CA News Station - KFMB ...
SeaWorld Entertainment, Inc. announced that as of Thursday, orcas will no longer be bred at its parks in San Diego or anywhere else in the country, ...

SeaWorld Orca Breeding Program Coming To End « CBS Boston
The announcement follows years of controversy over keeping orcas in captivity.

Behind the SeaWorld killer whale program controversy - Videos - CBS News
The wildlife theme park chain announced new policies for the breeding and showcasing of its killer whales. The shakeup comes after years of controversy, ...

SeaWorld says it will end killer whale breeding program
MIAMI (AP) — SeaWorld announced Thursday it will immediately stop breeding killer whales, essentially phasing the iconic orcas from its theme ...

YouTube Stops Complaining About T-Mobile’s Binge On, Joins Program
Remember all those years ago, when YouTube publicly railed against T-Mobile’s Binge On program , saying the wireless company may have violated ...

T-Mobile Adds YouTube to Binge On After T-Mobile Changes Program for Video Providers
... concerns all had some sort of agenda. As it turns out, YouTube (and the rest of us who had issues with Binge On) really just wanted the program ...

'Teen Mom OG' Star Catelynn Lowell Leaves Home for Program in Arizona: 'This Is For Me and My Family' ...
'Teen Mom OG' star Catelynn Lowell leaves home after troubling tweets, but insists she's not going to rehab.

Uber Offers Drivers Instant Pay In Pilot Program
Uber drivers will be able to get paid instantly via a GoBank account, in a pilot launched Thursday in San Francisco. Uber drivers in San Francisco ...

Resources last updated: 3/18/2016 12:40:59 PM