Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. jj72uk

    Skip over data in reading raw data

    Hi Sap, If you dont want the Expenses NetIncome Employees vars then why bring them in in the first place? If there's a reason you could always do a drop/keep to loose them. As for your "&" I'd suggest you have a look at the INDEX function. This allowed you to search a variables string and...
  2. jj72uk

    Zip Excel File With Password from SAS

    Well.. What error are you getting? Also ... Aren't you missing a \ put '"c:\program files\winzip\winzip32.exe"' "&filename" '.zip ' "&filename" '.xls';
  3. jj72uk

    Zip Excel File With Password from SAS

    Hi, On the SAS knowledge base there's this example on password protecting excel files via DDE: http://support.sas.com/kb/31/328.html And for Zipping up files again another SAS help file: http://www2.sas.com/proceedings/sugi29/077-29.pdf The above zip example will need to be modified if its...
  4. jj72uk

    proc export to dat?

    If you want a SAS dataset onto a local drive there's a couple of ways to do it. i) Create a libname where you want the dataset to go and then use a data step referencing that outputted libname. ii) Use a Proc Append
  5. jj72uk

    transferring a sas dataset to local drive question

    A .sas7bdat should be a valid SAS dataset so it should be fine
  6. jj72uk

    Changing numeric to character

    You're getting an error as in one or more of the datasets you're setting together has different formats for the same vars. If all 86 files are meant to be the same and are sourced the same I'd say fix the source. It could be just 1 of the source files that you need to fix. To find this you...
  7. jj72uk

    Import issues Excel to SAS

    Ok, try deleting the whole "sheet" line and re trying. As for file names you'll need: File_20&i And use %do i = 01 %to 20 As for the error I missed a . So: DATAFILE="V:\pcsas_export_files\invoices_&i..xls" I'm on my phone now so unable to test.
  8. jj72uk

    Datetime in sas when uploading from access

    Put the format on the next line after the set statement. It's the way sas reads in the pdv
  9. jj72uk

    Import issues Excel to SAS

    So if its just the invoice one.. %macro overall; %do i = 1 %to 7; /*where 1 is the first number and 7 is the last*/ PROC IMPORT OUT= lib.clients_invoices&i DATAFILE="V:\pcsas_export_files\invoices_&i.xls" DBMS=EXCEL2000 REPLACE; SHEET="Sheet1$"; GETNAMES=YES; RUN...
  10. jj72uk

    Import issues Excel to SAS

    When SAS does a Proc Import it will format it to "BEST" basically. You'll need to add formats to subsequent data steps. Onto the Macro.. Are your 20 files all in the same folder?
  11. jj72uk

    Datetime in sas when uploading from access

    datex = datepart(date) /* where date is the variable thats showing as date/time*/
  12. jj72uk

    Skip rows and begin reading at certain interval

    Im sure there are some infile options that can do this, check out: http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a000146932.htm For a dirty solution you could always do: if testcode >1 then helper = 1;else helper = 0; ---- Next datastep if helper = 0 then...
  13. jj72uk

    Import issues Excel to SAS

    Hi, Using a Proc Import would solve your problem... SAS would automatically place an underscore for spaces...as for special chars. SAS would label them as seem in excel, but rename them... Eg Excel----SAS name---SAS Label Client#--Client_----Client# PROC IMPORT OUT= lib.clients_invoices...
  14. jj72uk

    SAS Log Not populating status when report runs

    Usually the first thing I try... restarting SAS...though it can be annoying if you have a lot of work based datasets!
  15. jj72uk

    calculate sum in column by date

    You could also use a Proc Summary: proc summary data = data1 nway; class date; var value; output out = hlp1 (drop = _freq_ _type_) sum=; run;
  16. jj72uk

    How to calculate only bussiness days

    What about an IF/ELSE? Maybe something like... new_sasdate = input(osjomtpv,yymmdd8.); if new_sasdate - today() <= 5 then osinko ="DIVIDEND"; else if weekday(new_sasdate) = 1 then osinko =""; else if weekday(new_sasdate) = 7 then osinko =""; TEST=new_sasdate - today(); if TEST < 0 then...
  17. jj72uk

    SAS Log Not populating status when report runs

    Are you using : Proc Printto anywhere?
  18. jj72uk

    Macro to automate selection of multiple files with similar name

    A simple loop should suffice.. %macro overall; data setted; set %do i = 1 %to 7; /*where 1 is the first number and 7 is the last*/ p_claim.file06_2001_&i %end; ; run; %mend; %overall;
  19. jj72uk

    SAS and Dodge Excel Files

    have you tried to using the built in export feature File>Export Data And see if it fails again. Also, if when you're exporting its replacing a file you want to make sure the file isn't opened by someone else or someone may be locked in it if its on a network drive
  20. jj72uk

    HELP: Complex time issue SAS code!!!

    I'd love to help, but I cannot get my head around how tad would be worked out... if you can give me a written example of what you'd expect tad to be and why...

Part and Inventory Search

Back
Top