<?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 fedwire funds format files with tags and elements in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762167#M241270</link>
    <description>&lt;P&gt;Stuck trying to figure out how to parse a file that we get from fedwire the general format is in attached myfile.txt&amp;nbsp; There can be any number of records. Within the records the data elements are separated by a tag enclosed in {} which represent a field name, the data following the tag is associated with that field, up until we reach next tag {}. Each record can have different tags and different number of tags, as in the attached example all three records have the same tags {1100}, {1110},{1120},{1510},{1520},{2000},{3100},{3320},{3400},and {3600}. However you can see record three then jumps to {4200}, whereas records 1and 2 the next tag is {3620}.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have tried using input&amp;nbsp;@, but struggling with that, stopping after field2, also some of the data within the tag can be variable length, so can't always set the field value to extract exact length of the data, so trying to figure out how to parse by tags {} and capture data.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;options ls=max;
filename fedwire "%sysfunc(pathname(WORK))\fedwire.txt";
data have;
  input;
  file fedwire;
  put _infile_;
  datalines;
{1100}30P N{1110}08030815FT03{1120}20210803L1B7832F00013308030815FT03{1510}1000{1520}20210801B1Q8161C001707{2000}002020230000{3100}021000018BANKOBOB*{3320}F9S2108035631900*{3400}121125631AAA BBB CCCC DD EE*{3600}CTP{3620}3*FA6FE938-A6F6-4EE9-A062-6B87FC752339*{3700}SUSD0,00*{3710}USD203000,*{4200}D1602204277*ALOT OF WRITTING STUFF 98203*{5000}D02628651*MR WARREN JOHN BLAHALBH*FLAT 30 135 AAAAAAA WALK*LONDON N1 7RR GB*{5100}D8033779245*COOTTS AND COMP'L. KING DIV*73 MAN STR, EAST HSE, 3RD FL*D*{6000}HELEN BOBS STUFF*ROUTE: 122228444*
{1100}30P N{1110}08031116FT03{1120}20210803L1B7832F00031008031116FT03{1510}1000{1520}20210803B1QGC06C006237{2000}000300899500{3100}021000021NONEOFBUS*{3320}98566273215FS*{3400}121222484AAA BBB CCCC DD EE*{3600}CTP{3620}3*9A294483-5377-4A00-9362-8C95FEF4229F*{3700}SUSD5,00*{3710}USD6000,00*{4100}F124448405*MOREBLAH BLAH BLAH STUFF*{4200}D88040660033579*EDUARDO BLAH BLAH HERNANDEZ, E*STADOS UNIDOS,11111 LILAC ,TEXAS*{4320}SWF OF 21/09/03*{5000}DCLIENTE:13770683*INDUSTY  S A DE C V*BRALES C P*45694 EL SALTO JALISCO MEXICO*{5100}BRGIOMFE33XMT*
{1100}30P S{1110}08031811FT03{1120}20210803L1B7832F00101008031811FT03{1510}1631{1520}20210803QMGAT015001875{2000}000440962083{3100}125108405CANTSEE ME*{3320}F001BB*{3400}121045584AAA BBB CCCC DD EE*{3600}DRB{4200}F125108405*SOMEWHER OVER THE RAINBOW*{4400}D125108405*NOT IN KANSAS*{5000}F125108405*LOST SOMEWHERE*{5400}125108405{6500}DRAW*CREDIT IMMUNITY PALACE*
run;
data want2;
infile fedwire  truncover;
input @"{1100}" field1 :$5. @"{1110}" field2 :$12. @"{1120}" field3 :$34.;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;Was trying to use regular expression but can't figure that out either, I think this will work, but not sure how to keep field name&amp;nbsp;&amp;nbsp;prxparse('/(?&amp;lt;={\d\d\d\d})\w+/')&lt;/P&gt;
&lt;P&gt;Any help would be appreciated. Thanks&lt;/P&gt;</description>
    <pubDate>Tue, 17 Aug 2021 21:07:34 GMT</pubDate>
    <dc:creator>jimbobob</dc:creator>
    <dc:date>2021-08-17T21:07:34Z</dc:date>
    <item>
      <title>fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762167#M241270</link>
      <description>&lt;P&gt;Stuck trying to figure out how to parse a file that we get from fedwire the general format is in attached myfile.txt&amp;nbsp; There can be any number of records. Within the records the data elements are separated by a tag enclosed in {} which represent a field name, the data following the tag is associated with that field, up until we reach next tag {}. Each record can have different tags and different number of tags, as in the attached example all three records have the same tags {1100}, {1110},{1120},{1510},{1520},{2000},{3100},{3320},{3400},and {3600}. However you can see record three then jumps to {4200}, whereas records 1and 2 the next tag is {3620}.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have tried using input&amp;nbsp;@, but struggling with that, stopping after field2, also some of the data within the tag can be variable length, so can't always set the field value to extract exact length of the data, so trying to figure out how to parse by tags {} and capture data.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;options ls=max;
filename fedwire "%sysfunc(pathname(WORK))\fedwire.txt";
data have;
  input;
  file fedwire;
  put _infile_;
  datalines;
{1100}30P N{1110}08030815FT03{1120}20210803L1B7832F00013308030815FT03{1510}1000{1520}20210801B1Q8161C001707{2000}002020230000{3100}021000018BANKOBOB*{3320}F9S2108035631900*{3400}121125631AAA BBB CCCC DD EE*{3600}CTP{3620}3*FA6FE938-A6F6-4EE9-A062-6B87FC752339*{3700}SUSD0,00*{3710}USD203000,*{4200}D1602204277*ALOT OF WRITTING STUFF 98203*{5000}D02628651*MR WARREN JOHN BLAHALBH*FLAT 30 135 AAAAAAA WALK*LONDON N1 7RR GB*{5100}D8033779245*COOTTS AND COMP'L. KING DIV*73 MAN STR, EAST HSE, 3RD FL*D*{6000}HELEN BOBS STUFF*ROUTE: 122228444*
{1100}30P N{1110}08031116FT03{1120}20210803L1B7832F00031008031116FT03{1510}1000{1520}20210803B1QGC06C006237{2000}000300899500{3100}021000021NONEOFBUS*{3320}98566273215FS*{3400}121222484AAA BBB CCCC DD EE*{3600}CTP{3620}3*9A294483-5377-4A00-9362-8C95FEF4229F*{3700}SUSD5,00*{3710}USD6000,00*{4100}F124448405*MOREBLAH BLAH BLAH STUFF*{4200}D88040660033579*EDUARDO BLAH BLAH HERNANDEZ, E*STADOS UNIDOS,11111 LILAC ,TEXAS*{4320}SWF OF 21/09/03*{5000}DCLIENTE:13770683*INDUSTY  S A DE C V*BRALES C P*45694 EL SALTO JALISCO MEXICO*{5100}BRGIOMFE33XMT*
{1100}30P S{1110}08031811FT03{1120}20210803L1B7832F00101008031811FT03{1510}1631{1520}20210803QMGAT015001875{2000}000440962083{3100}125108405CANTSEE ME*{3320}F001BB*{3400}121045584AAA BBB CCCC DD EE*{3600}DRB{4200}F125108405*SOMEWHER OVER THE RAINBOW*{4400}D125108405*NOT IN KANSAS*{5000}F125108405*LOST SOMEWHERE*{5400}125108405{6500}DRAW*CREDIT IMMUNITY PALACE*
run;
data want2;
infile fedwire  truncover;
input @"{1100}" field1 :$5. @"{1110}" field2 :$12. @"{1120}" field3 :$34.;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;BR /&gt;Was trying to use regular expression but can't figure that out either, I think this will work, but not sure how to keep field name&amp;nbsp;&amp;nbsp;prxparse('/(?&amp;lt;={\d\d\d\d})\w+/')&lt;/P&gt;
&lt;P&gt;Any help would be appreciated. Thanks&lt;/P&gt;</description>
      <pubDate>Tue, 17 Aug 2021 21:07:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762167#M241270</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-17T21:07:34Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762184#M241282</link>
      <description>&lt;P&gt;The documentation for the file contents is where exactly?&lt;/P&gt;
&lt;P&gt;My guess is some of those "fields" have a mixture of date and other stuff.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is there anything that identifies a line, or combination of lines, as a single record?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If the fields can have different lengths it really helps to know which ones what rules may be involved for the substrings.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 17 Aug 2021 22:05:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762184#M241282</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2021-08-17T22:05:13Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762190#M241285</link>
      <description>&lt;P&gt;If you really want to read the documentation, here you go:&amp;nbsp;&lt;A href="https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.445.7645&amp;amp;rep=rep1&amp;amp;type=pdf" target="_blank"&gt;https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.445.7645&amp;amp;rep=rep1&amp;amp;type=pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yes the data in between the tags can be a mixture, for my purposes if I can get each set of data elements between the tags into its own column of data, then i can parse that data further.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Each row is one record that can be parsed out to many fields. Data between each tag {} can be one or more fields of data as well, but im working on baby steps just trying to break out each set of data between the tags to its own column.&lt;/P&gt;</description>
      <pubDate>Tue, 17 Aug 2021 22:22:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762190#M241285</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-17T22:22:06Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762193#M241288</link>
      <description>&lt;P&gt;Like this?&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data WANT;
  infile FEDWIRE truncover lrecl=8000;
  input ;
  array FIELD[0:99] $10.;
  array VALUE[0:99] $50.;
  RECORD=_N_;
  do SCAN=0 to 99 ;
    FIELD[SCAN]=scan(_INFILE_,SCAN*2+1,'{}');
    VALUE[SCAN]=scan(_INFILE_,SCAN*2+2,'{}');
    if VALUE[SCAN]=' ' then leave; 
  end;
  output;
 run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 17 Aug 2021 22:50:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762193#M241288</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2021-08-17T22:50:01Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762198#M241292</link>
      <description>&lt;P&gt;Thanks Chris, I might be able to work with this. Attached is my desired output&lt;/P&gt;</description>
      <pubDate>Tue, 17 Aug 2021 23:18:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762198#M241292</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-17T23:18:17Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762203#M241295</link>
      <description>&lt;P&gt;Glad to know. I'm not touching MS Office files &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 17 Aug 2021 23:59:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762203#M241295</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2021-08-17T23:59:33Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762204#M241296</link>
      <description>&lt;TABLE style="width: 99.96834441278887%;" border="1" width="99.96834441278887%"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="1.4245014245014245%"&gt;1100&lt;/TD&gt;
&lt;TD width="3.767014878125989%"&gt;1110&lt;/TD&gt;
&lt;TD width="10.0664767331434%"&gt;1120&lt;/TD&gt;
&lt;TD width="1.48781259892371%"&gt;1510&lt;/TD&gt;
&lt;TD width="6.995884773662551%"&gt;1520&lt;/TD&gt;
&lt;TD width="3.7353592909148463%"&gt;2000&lt;/TD&gt;
&lt;TD width="6.267806267806268%"&gt;3100&lt;/TD&gt;
&lt;TD width="5.159860715416271%"&gt;3320&lt;/TD&gt;
&lt;TD width="3.8619816397594176%"&gt;3400&lt;/TD&gt;
&lt;TD width="1.4561570117125673%"&gt;3600&lt;/TD&gt;
&lt;TD width="4.178537511870846%"&gt;3620&lt;/TD&gt;
&lt;TD width="2.9123140234251346%"&gt;3700&lt;/TD&gt;
&lt;TD width="3.4504590060145612%"&gt;3710&lt;/TD&gt;
&lt;TD width="6.236150680595125%"&gt;4100&lt;/TD&gt;
&lt;TD width="7.375751820196265%"&gt;4200&lt;/TD&gt;
&lt;TD width="2.5324469768914213%"&gt;4320&lt;/TD&gt;
&lt;TD width="4.495093383982273%"&gt;4400&lt;/TD&gt;
&lt;TD width="7.818930041152264%"&gt;5000&lt;/TD&gt;
&lt;TD width="5.824628046850269%"&gt;5100&lt;/TD&gt;
&lt;TD width="2.880658436213992%"&gt;5400&lt;/TD&gt;
&lt;TD width="4.083570750237417%"&gt;6000&lt;/TD&gt;
&lt;TD width="3.9569484013928458%"&gt;6500&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="1.4245014245014245%"&gt;30P N&lt;/TD&gt;
&lt;TD width="3.767014878125989%"&gt;08030815FT03&lt;/TD&gt;
&lt;TD width="10.0664767331434%"&gt;20210803L1B7832F00013308030815FT03&lt;/TD&gt;
&lt;TD width="1.48781259892371%"&gt;1000&lt;/TD&gt;
&lt;TD width="6.995884773662551%"&gt;20210801B1Q8161C001707&lt;/TD&gt;
&lt;TD width="3.7353592909148463%"&gt;002020230000&lt;/TD&gt;
&lt;TD width="6.267806267806268%"&gt;021000018BANKOBOB*&lt;/TD&gt;
&lt;TD width="5.159860715416271%"&gt;F9S2108035631900*&lt;/TD&gt;
&lt;TD width="3.8619816397594176%"&gt;121125631AAA BBB CCCC DD EE*&lt;/TD&gt;
&lt;TD width="1.4561570117125673%"&gt;CTP&lt;/TD&gt;
&lt;TD width="4.178537511870846%"&gt;3*FA6FE938-A6F6-4EE9-A062-6B87FC752339*&lt;/TD&gt;
&lt;TD width="2.9123140234251346%"&gt;SUSD0,00*&lt;/TD&gt;
&lt;TD width="3.4504590060145612%"&gt;USD203000,*&lt;/TD&gt;
&lt;TD width="6.236150680595125%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="7.375751820196265%"&gt;D1602204277*ALOT OF WRITTING STUFF 98203*&lt;/TD&gt;
&lt;TD width="2.5324469768914213%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="4.495093383982273%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="7.818930041152264%"&gt;D02628651*MR WARREN JOHN BLAHALBH*FLAT 30 135 AAAA&lt;/TD&gt;
&lt;TD width="5.824628046850269%"&gt;D8033779245*COOTTS AND COMP'L. KING DIV*73 MAN STR&lt;/TD&gt;
&lt;TD width="2.880658436213992%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="4.083570750237417%"&gt;HELEN BOBS STUFF*ROUTE: 122228444*&lt;/TD&gt;
&lt;TD width="3.9569484013928458%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="1.4245014245014245%"&gt;30P N&lt;/TD&gt;
&lt;TD width="3.767014878125989%"&gt;08031116FT03&lt;/TD&gt;
&lt;TD width="10.0664767331434%"&gt;20210803L1B7832F00031008031116FT03&lt;/TD&gt;
&lt;TD width="1.48781259892371%"&gt;1000&lt;/TD&gt;
&lt;TD width="6.995884773662551%"&gt;20210803B1QGC06C006237&lt;/TD&gt;
&lt;TD width="3.7353592909148463%"&gt;000300899500&lt;/TD&gt;
&lt;TD width="6.267806267806268%"&gt;021000021NONEOFBUS*&lt;/TD&gt;
&lt;TD width="5.159860715416271%"&gt;98566273215FS*&lt;/TD&gt;
&lt;TD width="3.8619816397594176%"&gt;121222484AAA BBB CCCC DD EE*&lt;/TD&gt;
&lt;TD width="1.4561570117125673%"&gt;CTP&lt;/TD&gt;
&lt;TD width="4.178537511870846%"&gt;3*9A294483-5377-4A00-9362-8C95FEF4229F*&lt;/TD&gt;
&lt;TD width="2.9123140234251346%"&gt;SUSD5,00*&lt;/TD&gt;
&lt;TD width="3.4504590060145612%"&gt;USD6000,00*&lt;/TD&gt;
&lt;TD width="6.236150680595125%"&gt;F124448405*MOREBLAH BLAH BLAH STUFF*&lt;/TD&gt;
&lt;TD width="7.375751820196265%"&gt;D88040660033579*EDUARDO BLAH BLAH HERNANDEZ, E*STA&lt;/TD&gt;
&lt;TD width="2.5324469768914213%"&gt;SWF OF 21/09/03*&lt;/TD&gt;
&lt;TD width="4.495093383982273%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="7.818930041152264%"&gt;DCLIENTE:13770683*INDUSTY&amp;nbsp; S A DE C V*BRALES C P*4&lt;/TD&gt;
&lt;TD width="5.824628046850269%"&gt;BRGIOMFE33XMT*&lt;/TD&gt;
&lt;TD width="2.880658436213992%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="4.083570750237417%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="3.9569484013928458%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="1.4245014245014245%"&gt;30P S&lt;/TD&gt;
&lt;TD width="3.767014878125989%"&gt;08031811FT03&lt;/TD&gt;
&lt;TD width="10.0664767331434%"&gt;20210803L1B7832F00101008031811FT03&lt;/TD&gt;
&lt;TD width="1.48781259892371%"&gt;1631&lt;/TD&gt;
&lt;TD width="6.995884773662551%"&gt;20210803QMGAT015001875&lt;/TD&gt;
&lt;TD width="3.7353592909148463%"&gt;000440962083&lt;/TD&gt;
&lt;TD width="6.267806267806268%"&gt;125108405CANTSEE ME*&lt;/TD&gt;
&lt;TD width="5.159860715416271%"&gt;F001BB*&lt;/TD&gt;
&lt;TD width="3.8619816397594176%"&gt;121045584AAA BBB CCCC DD EE*&lt;/TD&gt;
&lt;TD width="1.4561570117125673%"&gt;DRB&lt;/TD&gt;
&lt;TD width="4.178537511870846%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="2.9123140234251346%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="3.4504590060145612%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="6.236150680595125%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="7.375751820196265%"&gt;F125108405*SOMEWHER OVER THE RAINBOW*&lt;/TD&gt;
&lt;TD width="2.5324469768914213%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="4.495093383982273%"&gt;D125108405*NOT IN KANSAS*&lt;/TD&gt;
&lt;TD width="7.818930041152264%"&gt;F125108405*LOST SOMEWHERE*&lt;/TD&gt;
&lt;TD width="5.824628046850269%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="2.880658436213992%"&gt;125108405&lt;/TD&gt;
&lt;TD width="4.083570750237417%"&gt;&amp;nbsp;&lt;/TD&gt;
&lt;TD width="3.9569484013928458%"&gt;DRAW*CREDIT IMMUNITY PALACE*&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;</description>
      <pubDate>Wed, 18 Aug 2021 00:10:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762204#M241296</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-18T00:10:50Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762206#M241297</link>
      <description>&lt;P&gt;1. How do you establish the list of variable names?&lt;/P&gt;
&lt;P&gt;2. The names you show are invalid: the first character is a digit.&lt;/P&gt;</description>
      <pubDate>Wed, 18 Aug 2021 01:37:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762206#M241297</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2021-08-18T01:37:29Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762314#M241343</link>
      <description>&lt;P&gt;The goal is to rename the numbers to field name, for example 1100 = Message_Disposition, 1110 =&amp;nbsp;Receipt_Time_Stamp, this pdf list out the actuals names that I would rename the variables to&amp;nbsp;&lt;A href="https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.445.7645&amp;amp;rep=rep1&amp;amp;type=pdf" target="_blank"&gt;https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.445.7645&amp;amp;rep=rep1&amp;amp;type=pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Aug 2021 15:34:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762314#M241343</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-18T15:34:34Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762356#M241366</link>
      <description>&lt;P&gt;Seems pretty simple to read.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data mydata;
  infile 'c:\downloads\myfile.txt' dlm='{}' truncover ;
  length row col 8 tag $20 text $200 ;
  row+1;
  do col=1 by 1 until(tag=' ');
    input tag text @;
    if tag ne ' ' then output;
  end;
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Results:&lt;/P&gt;
&lt;PRE&gt;Obs    row    col    tag     text

  1     1       1    1100    30P N
  2     1       2    1110    08030815FT03
  3     1       3    1120    20210803L1B7832F00013308030815FT03
  4     1       4    1510    1000
  5     1       5    1520    20210801B1Q8161C001707
  6     1       6    2000    002020230000
  7     1       7    3100    021000018BANKOBOB*
  8     1       8    3320    F9S2108035631900*
  9     1       9    3400    121125631AAA BBB CCCC DD EE*
 10     1      10    3600    CTP
 11     1      11    3620    3*FA6FE938-A6F6-4EE9-A062-6B87FC752339*
 12     1      12    3700    SUSD0,00*
 13     1      13    3710    USD203000,*
 14     1      14    4200    D1602204277*ALOT OF WRITTING STUFF 98203*
 15     1      15    5000    D02628651*MR WARREN JOHN BLAHALBH*FLAT 30 135 AAAAAAA WALK*LONDON N1 7RR GB*
 16     1      16    5100    D8033779245*COOTTS AND COMP'L. KING DIV*73 MAN STR, EAST HSE, 3RD FL*D*
 17     1      17    6000    HELEN BOBS STUFF*ROUTE: 122228444*
 18     2       1    1100    30P N
 19     2       2    1110    08031116FT03
 20     2       3    1120    20210803L1B7832F00031008031116FT03
...&lt;/PRE&gt;</description>
      <pubDate>Wed, 18 Aug 2021 17:50:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762356#M241366</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2021-08-18T17:50:21Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762357#M241367</link>
      <description>&lt;P&gt;Awesome. I love SAS folks. Thank you so much Tom.&amp;nbsp; Chris thanks as well for your help,&lt;/P&gt;</description>
      <pubDate>Wed, 18 Aug 2021 18:02:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762357#M241367</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-18T18:02:16Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762393#M241388</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13255"&gt;@jimbobob&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;The goal is to rename the numbers to field name, for example 1100 = Message_Disposition, 1110 =&amp;nbsp;Receipt_Time_Stamp, this pdf list out the actuals names that I would rename the variables to&amp;nbsp;&lt;A href="https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.445.7645&amp;amp;rep=rep1&amp;amp;type=pdf" target="_blank" rel="noopener"&gt;https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.445.7645&amp;amp;rep=rep1&amp;amp;type=pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;You might consider a custom format to supply the text "Message disposition" or similar for the value of the Tag, using &lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/159"&gt;@Tom&lt;/a&gt;'s code.&lt;/P&gt;
&lt;P&gt;Or create a format so that the formatted value of the Tag variable could be used by Proc Transpose in an ID statement if you had a variable that would indicate which observations were from the same line in the original file.&lt;/P&gt;
&lt;P&gt;Example using a format to create new variables using with Proc Transpose:&lt;/P&gt;
&lt;PRE&gt;data example;
   input x $ y $ z $;
datalines;
1 2 abc
4 5 pdq
;

proc format;
value $ycode
'2'='Some_description'
'4'='Other_desc'
'5'='This_description'
;
run;

proc transpose data=example
   out=trans;
by x;
id y;
var z;
format y $ycode.;
run;
&lt;/PRE&gt;
&lt;P&gt;Placing a significant chunk of _infile_ into a permanent variable might work for a line identifier if nothing better comes to mind using Tom's code.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Aug 2021 22:21:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762393#M241388</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2021-08-18T22:21:43Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762436#M241418</link>
      <description>&lt;P&gt;A unique row identifier is what the ROW variable is for in the selected answer.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Aug 2021 03:11:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762436#M241418</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2021-08-19T03:11:15Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762567#M241463</link>
      <description>&lt;P&gt;Excellent, thanks Ballard, way better than the route I was taking using a replace macro I found in a SAS paper was working but taking forever to run. this was instant.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Aug 2021 15:21:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762567#M241463</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-19T15:21:35Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762685#M241498</link>
      <description>&lt;P&gt;Hey Tom, ran into a snag with some of my files. I found that in some file the records start with "YFT811 " before starting the rest of the delimited file, so the delimted file really starts at position 9: I found a paper on using a variable for the dlm= option, but I've had no luck figuring out how to do it&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 673px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/62746iD76F6831DCE278D1/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Paper I was trying to follow:&amp;nbsp;&amp;nbsp;&lt;A href="https://www.lexjansen.com/nesug/nesug12/cc/cc23.pdf" target="_blank"&gt;https://www.lexjansen.com/nesug/nesug12/cc/cc23.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;My Attempted Code:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data x;
  infile "C:\Users\jwalker\Desktop\New folder (2)\FedLine32948_PCBB_FXWIRE_FEDLINE_202107201050.txt" dlm=mydlm truncover;
  length row col 8 tag $32 text $1000;
  row+1;
  mydlm = 'YFT811';
  input v1 $ @;
  do col=1 by 1 until(tag=' ');
  	 mydlm = '{}';
    input tag text @;
    if tag ne ' ' then output;
  end;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;I there a way to do this or tell the input to start at position 9?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Aug 2021 20:26:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762685#M241498</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-19T20:26:15Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762688#M241499</link>
      <description>&lt;P&gt;Just read that into a different variable, call it EXTRA.&amp;nbsp; No need to change your delimiters.&lt;/P&gt;
&lt;P&gt;You can even test if it looks like a TAG value (all digits) and and reset the column pointer to column 1 when it does so you don't end up reading the first TAG value into EXTRA and getting everything out of sync.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data x;
  infile "C:\Users\jwalker\Desktop\New folder (2)\FedLine32948_PCBB_FXWIRE_FEDLINE_202107201050.txt"
    dlm='{}' truncover
  ;
  length row col 8 extra tag $32 text $1000;
  row+1;
  input extra @;
  if not notdigit(extra) then input @1 @ ;
  do col=1 by 1 until(tag=' ');
    input tag text @;
    if tag ne ' ' then output;
  end;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Looking at the documentation you might even want to make TAG a numeric variable since all of the values are 4 digit numbers.&amp;nbsp; Then you could add the extra input the first tag is missing.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data x;
  infile "C:\Users\jwalker\Desktop\New folder (2)\FedLine32948_PCBB_FXWIRE_FEDLINE_202107201050.txt"
    dlm='{}' truncover
  ;
  length row col tag 8 extra $32 text $1000;
  row+1;
  input tag ?? @1 @;
  if missing(tag) then input extra @ ;
  do col=1 by 1 until(missing(tag));
    input tag text @;
    if not missing(tag) then output;
  end;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 19 Aug 2021 20:40:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762688#M241499</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2021-08-19T20:40:04Z</dc:date>
    </item>
    <item>
      <title>Re: fedwire funds format files with tags and elements</title>
      <link>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762691#M241501</link>
      <description>Man you're a genius, I've been trying to figure this out for 4 hours. Thank you so much.&lt;BR /&gt;</description>
      <pubDate>Thu, 19 Aug 2021 20:41:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/fedwire-funds-format-files-with-tags-and-elements/m-p/762691#M241501</guid>
      <dc:creator>jimbobob</dc:creator>
      <dc:date>2021-08-19T20:41:23Z</dc:date>
    </item>
  </channel>
</rss>

