<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to create V5 xpt file in sas 9.4 in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/685672#M207987</link>
    <description>&lt;P&gt;Hi Experts,&lt;/P&gt;&lt;P&gt;&amp;nbsp;How can we create the&amp;nbsp;different version of XPT file in SAS 9.4 ??&lt;/P&gt;&lt;P&gt;&amp;nbsp;I need the xpt V4,V5,V6,V7 and V8 file for testing .&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sasi.k&lt;/P&gt;</description>
    <pubDate>Tue, 22 Sep 2020 12:26:46 GMT</pubDate>
    <dc:creator>sasikala</dc:creator>
    <dc:date>2020-09-22T12:26:46Z</dc:date>
    <item>
      <title>How to create V5 xpt file in sas 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/685672#M207987</link>
      <description>&lt;P&gt;Hi Experts,&lt;/P&gt;&lt;P&gt;&amp;nbsp;How can we create the&amp;nbsp;different version of XPT file in SAS 9.4 ??&lt;/P&gt;&lt;P&gt;&amp;nbsp;I need the xpt V4,V5,V6,V7 and V8 file for testing .&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sasi.k&lt;/P&gt;</description>
      <pubDate>Tue, 22 Sep 2020 12:26:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/685672#M207987</guid>
      <dc:creator>sasikala</dc:creator>
      <dc:date>2020-09-22T12:26:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to create V5 xpt file in sas 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/685736#M208020</link>
      <description>&lt;P&gt;&lt;A href="https://documentation.sas.com/?docsetId=movefile&amp;amp;docsetTarget=p0szyk23me80c4n1aqtz1x708cq2.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en"&gt;https://documentation.sas.com/?docsetId=movefile&amp;amp;docsetTarget=p0szyk23me80c4n1aqtz1x708cq2.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This covers V5 and V8, not sure about the others.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/113481"&gt;@sasikala&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hi Experts,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;How can we create the&amp;nbsp;different version of XPT file in SAS 9.4 ??&lt;/P&gt;
&lt;P&gt;&amp;nbsp;I need the xpt V4,V5,V6,V7 and V8 file for testing .&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Sasi.k&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 Sep 2020 15:34:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/685736#M208020</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-09-22T15:34:51Z</dc:date>
    </item>
    <item>
      <title>Re: How to create V5 xpt file in sas 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/685738#M208022</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/113481"&gt;@sasikala&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hi Experts,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;How can we create the&amp;nbsp;different version of XPT file in SAS 9.4 ??&lt;/P&gt;
&lt;P&gt;&amp;nbsp;I need the xpt V4,V5,V6,V7 and V8 file for testing .&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Sasi.k&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;There is no published V4 or V6 format.&lt;/P&gt;
&lt;P&gt;The XPORT libname engine only supports the version 5 format.&amp;nbsp; Once you have a libref defined using that engine you can use it with standard SAS code.&amp;nbsp; Note the V5 format means 8 character names and maximum of 200 characters for strings and other older limitations of datasets.&amp;nbsp; Example code:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname in xport 'my physical file name';
proc copy inlib=in outlib=work; run;
libname out xport 'another file name';
data out.class;
  set sashelp.class;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;There are macros ( &lt;A href="https://documentation.sas.com/?docsetId=movefile&amp;amp;docsetTarget=p13q0v60f08mj3n1ebm8salcpkmh.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en#" target="_self"&gt;loc2xpt&lt;/A&gt; and &lt;A href="https://documentation.sas.com/?docsetId=movefile&amp;amp;docsetTarget=p1tp8gighlgeifn173i6kzw2w3bu.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en" target="_self"&gt;xpt2loc&lt;/A&gt;) that create/read "V8" format XPORT files.&amp;nbsp; Last time I looked at it does appear to have slight differences between V8 and V9 formats.&amp;nbsp; At least the header records it generates include those tags.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The CPORT transport file formats used by the CPORT and CIMPORT procs are only forward compatible.&amp;nbsp; You can read older files with newer versions of SAS, but you cannot create them.&lt;/P&gt;</description>
      <pubDate>Tue, 22 Sep 2020 15:46:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/685738#M208022</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2020-09-22T15:46:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to create V5 xpt file in sas 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/686331#M208233</link>
      <description>&lt;P&gt;Thank you so much.!&amp;nbsp;Tom.&lt;/P&gt;&lt;P&gt;I understand, we can read only OLD version if XPT and CPORT in SAS V9 and can not create it.&lt;/P&gt;&lt;P&gt;Colud you please help me on below quries -&lt;/P&gt;&lt;P&gt;1. Is there any way to programatically identify the XPT is created by libname XPORT engine or LOC2XPT macro ?&lt;/P&gt;&lt;P&gt;2.Will XPT2LOC macro support to extarct the all old version XPT&amp;nbsp;files and,&amp;nbsp;V8 and V9 XPT file created by Libname XPORT engine ?&lt;/P&gt;&lt;P&gt;3. I understand V5 XPT&amp;nbsp;and V8 XPT has its own format as documented in &lt;A href="https://documentation.sas.com/?docsetId=movefile&amp;amp;docsetTarget=n1xbwdre0giahfn11c99yjkpi2yb.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en"&gt;https://documentation.sas.com/?docsetId=movefile&amp;amp;docsetTarget=n1xbwdre0giahfn11c99yjkpi2yb.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;My understaing here 1.&amp;nbsp;The&amp;nbsp;V5,V6 and V7&amp;nbsp;version XPT&amp;nbsp;will support&amp;nbsp;only&amp;nbsp;for V5 XPT formats&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; 2. The V8&amp;nbsp;will support only form V8 xpt format&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3. The V9 will support for both V5 and V8 (VALIDMEMNAME=EXTEND option for V8)&lt;/P&gt;&lt;P&gt;4. Is XPT file version specific to SAS release version ? i mean V6&amp;nbsp;XPT file can be created by SAS V6 &amp;nbsp;?&lt;/P&gt;&lt;P&gt;Please Correct my understanding on point 3 and 4.&lt;/P&gt;&lt;P&gt;Thanks in advance !&lt;/P&gt;</description>
      <pubDate>Thu, 24 Sep 2020 10:33:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/686331#M208233</guid>
      <dc:creator>sasikala</dc:creator>
      <dc:date>2020-09-24T10:33:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to create V5 xpt file in sas 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/686695#M208424</link>
      <description>&lt;P&gt;There is no V6 version of XPORT format.&amp;nbsp; There was not any change in the length of variable names or character strings or labels between V5 and V6 of SAS.&lt;/P&gt;
&lt;P&gt;It was the short lived SAS V7 that introduced the longer variable names and longer character variables and longer labels.&amp;nbsp; That has continued as the standard with the more popular SAS V8 (notice that the .sas7bdat extension is still being used for the files where datasets are stored).&lt;/P&gt;
&lt;P&gt;The other changes to the structure that causes the macro to generate other headers has to do with the length of format names.&amp;nbsp; Originally those were still limited to 8 characters when the names of variables and members was increased to 32.&amp;nbsp; At some point that was increased also.&amp;nbsp; So I think the things that the macros call V9 will support longer format names.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The macros will support read/writing the older V5 format.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to check what type of file you have read the first 80.&amp;nbsp; There is a clear pattern difference between the two formats.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;filename xpt temp;
filename cpt temp;
libname out xport "%sysfunc(pathname(xpt))";
data out.class; set sashelp.class; run;
libname out clear;
proc cport data=sashelp.class file=cpt ;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;PRE&gt;535   data _null_;
536     infile xpt recfm=f lrecl=80 obs=1;
537     input;
538     list;
539   run;

NOTE: The infile XPT is: ...
RULE:     ----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+--
1         HEADER RECORD*******LIBRARY HEADER RECORD!!!!!!!000000000000000000000000000000
NOTE: 1 record was read from the infile XPT.

540
541   data _null_;
542     infile cpt recfm=f lrecl=80 obs=1;
543     input;
544     list;
545   run;

NOTE: The infile CPT is: ...

RULE:     ----+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+--
1         **COMPRESSED** **COMPRESSED** **COMPRESSED** **COMPRESSED** **COMPRESSED********
NOTE: 1 record was read from the infile CPT.
&lt;/PRE&gt;</description>
      <pubDate>Fri, 25 Sep 2020 14:00:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/686695#M208424</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2020-09-25T14:00:01Z</dc:date>
    </item>
    <item>
      <title>Re: How to create V5 xpt file in sas 9.4</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/688855#M209357</link>
      <description>&lt;P&gt;Thanks Tom. This helps.&lt;/P&gt;</description>
      <pubDate>Mon, 05 Oct 2020 11:24:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-create-V5-xpt-file-in-sas-9-4/m-p/688855#M209357</guid>
      <dc:creator>sasikala</dc:creator>
      <dc:date>2020-10-05T11:24:01Z</dc:date>
    </item>
  </channel>
</rss>

