<?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 Re: Howto: Merge tables where columns don't match exactly in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189186#M14468</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes it's possible.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In your example it looks you can make them "look" the same. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So lets work on making the columns in Table 2 look like the ones in Table 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It looks like the ones in table one all start with E and have 6 digits afterwards. Assuming this is consistent across all your data, then we can make the ones from Table 2 similar by&lt;/P&gt;&lt;P&gt;1) Extracting first portion of the email (use Scan() Function)&lt;/P&gt;&lt;P&gt;2) Making the number a&amp;nbsp; length of 6 by zero padding. (Use Z6. Format in a put statement)&lt;/P&gt;&lt;P&gt;3) Adding an E to the beginning (Concatenate)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For EG make a calculated column that implements this and then join on the calculated column.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 09 Jan 2014 19:58:23 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2014-01-09T19:58:23Z</dc:date>
    <item>
      <title>Howto: Merge tables where columns don't match exactly</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189183#M14465</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would like to join two tables using one of EG's built in features like query builder.&amp;nbsp; The two columns I would like to use contain matching characters, but also contain other extraneous ones. Both columns are character columns, but one contains a max length of 12 and the other a max length of 128.&amp;nbsp; Is it possible to join these two tables?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example Column 1&lt;/P&gt;&lt;P&gt;E001234&lt;/P&gt;&lt;P&gt;E012345&lt;/P&gt;&lt;P&gt;E123456&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example Column 2&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-email-small" href="mailto:1234@email.com"&gt;1234@email.com&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-email-small" href="mailto:12345@email.com"&gt;12345@email.com&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-email-small" href="mailto:123456@email.com"&gt;123456@email.com&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jan 2014 23:06:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189183#M14465</guid>
      <dc:creator>Otis_</dc:creator>
      <dc:date>2014-01-06T23:06:09Z</dc:date>
    </item>
    <item>
      <title>Re: Howto: Merge tables where columns don't match exactly</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189184#M14466</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Could you please explain a bit more like what you have and what you would like to get?&lt;/P&gt;&lt;P&gt;You can chnage the length. But it looks like your column1 (numeric part)) are same as the numeric part of column2.&lt;/P&gt;&lt;P&gt;Do you like to match on these?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is a suggestion:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;create a column (say match_col) as the numeric part from Column1&lt;/P&gt;&lt;P&gt;create a column(same name match_col) as the numeric part from Column2&lt;/P&gt;&lt;P&gt;then match the tables on match_col&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Mita&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Jan 2014 01:05:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189184#M14466</guid>
      <dc:creator>Mit</dc:creator>
      <dc:date>2014-01-07T01:05:50Z</dc:date>
    </item>
    <item>
      <title>Re: Howto: Merge tables where columns don't match exactly</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189185#M14467</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mita,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have two tables, and I would like to use the common numbers between one column in each table to merge two tables into one.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't know how to create new columns and only bring the numbers over from the existing columns I would like to match.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Jan 2014 19:46:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189185#M14467</guid>
      <dc:creator>Otis_</dc:creator>
      <dc:date>2014-01-09T19:46:38Z</dc:date>
    </item>
    <item>
      <title>Re: Howto: Merge tables where columns don't match exactly</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189186#M14468</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes it's possible.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In your example it looks you can make them "look" the same. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So lets work on making the columns in Table 2 look like the ones in Table 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It looks like the ones in table one all start with E and have 6 digits afterwards. Assuming this is consistent across all your data, then we can make the ones from Table 2 similar by&lt;/P&gt;&lt;P&gt;1) Extracting first portion of the email (use Scan() Function)&lt;/P&gt;&lt;P&gt;2) Making the number a&amp;nbsp; length of 6 by zero padding. (Use Z6. Format in a put statement)&lt;/P&gt;&lt;P&gt;3) Adding an E to the beginning (Concatenate)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For EG make a calculated column that implements this and then join on the calculated column.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Jan 2014 19:58:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Howto-Merge-tables-where-columns-don-t-match-exactly/m-p/189186#M14468</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2014-01-09T19:58:23Z</dc:date>
    </item>
  </channel>
</rss>

