I've figured out a way to read XPORT and sas7bdat formats from C#, but having trouble with CPORT.
The format doesn't appear to be recognized using the methods for the other two formats.
I've tried:
- sas.LocalProvider for sas7bdat
- SAS.UV.Transport for XPORT
Neither work for CPORT.
Any ideas?
thanks!
Chris
The format doesn't appear to be recognized using the methods for the other two formats.
Since CPORT creates differently structured files than Xport and is not in data set structure I would be very surprised that a method for either of the those would work. Note that XPORT only works for data members. CPORT exports can contain all sorts of different things stored in SAS catalogs: macro instructions, SAS formats, menus, SCL lists, graphics, AF widgets or programs and more. Each of which may have different binary storage requirements.
Is there any way to programmatically access the data within the CPORT file from .NET?
I see some references to SAS Integrated Object Model (IOM) Server as a possible option, but wanted to see if that was the right path before going that direction.
thanks!
Chris
@csiege wrote:
Is there any way to programmatically access the data within the CPORT file from .NET?
I see some references to SAS Integrated Object Model (IOM) Server as a possible option, but wanted to see if that was the right path before going that direction.
thanks!
Chris
You might search .NET oriented sites as this site would say to use Proc Cimport to recover the information in a CPORT transport file since that is the SAS tool for doing so. I don't know if SAS has ever made the file layout/description/binary coding for Cport files available.
I think XPORT is the only one ever described.
See here:
https://www.loc.gov/preservation/digital/formats/fdd/fdd000464.shtml
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.