Hello everybody 🙂!
Please help me to solve my problem. I want to convert pdf to sas table.
How i can do this? Can I convert pdf to sas table direcly in my sas stydio?
Thanks a lot!!
I would try to copy/paste the table data into a DATALINES block of a DATA step.
Search on-line for some tool that can attempt to convert the content of the PDF into text. Then you can read the text into SAS.
If the copy/paste clipboard method doesn't work then open source tools to look into for conversion of a pdf into text: Tika, PDFBox and Tabula.
I've used Tika and PDFBox in past projects successfully for such purposes. PDFBox was "better" suited for pdf documents because the Tika version at the time didn't deal nicely with a specific PDF tag. Never used Tabula but it sounds promising.
With PDFBox the whole PDF document got converted into a text file which we then parsed via SAS code (DataFlux actually) to extract what we needed. It will depend on the structure of your source PDF document how much work writing such text parsing code will be.
As long as the data fits into the clipboard, you should be good.
You may have to take care of extra lines caused by page breaks (and the header and footer lines).
Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!
What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.