<?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: Grab ID and assign another ID from a macro list in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Grab-ID-and-assign-another-ID-from-a-macro-list/m-p/521626#M141549</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/1717"&gt;@saslove&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;I have an ID list&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;%let study1_ids="ab","xy","we","st","ut","po","vc","gh"; (study 1)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Now, for another study (let's say study 2) with a different set of IDS, I need to go over each ID list (which is entirely different from the above list- but for each id, I need to assign each id above.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For ex&lt;/P&gt;
&lt;P&gt;abc&amp;nbsp;(study 2) = ab (study 1)&lt;/P&gt;
&lt;P&gt;d3e (study 2) = xy (study 1)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thoughts?&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Question the need for quotes and commas in that study1_ids.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This makes no sense in SAS: what&amp;nbsp;are ABC, AB, d3e or xy. If they are values of a variable then what is the name of the variable?&lt;/P&gt;
&lt;PRE&gt;abc (study 2) = ab (study 1)

d3e (study 2) = xy (study 1)
&lt;/PRE&gt;
&lt;P&gt;Provide a few concrete examples with values from both "lists" and what the result should be.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This sort of sounds like you probably should have the values involved in data sets and then SQL to match things.&lt;/P&gt;</description>
    <pubDate>Fri, 14 Dec 2018 19:53:06 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2018-12-14T19:53:06Z</dc:date>
    <item>
      <title>Grab ID and assign another ID from a macro list</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Grab-ID-and-assign-another-ID-from-a-macro-list/m-p/521616#M141547</link>
      <description>&lt;P&gt;I have an ID list&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;%let study1_ids="ab","xy","we","st","ut","po","vc","gh"; (study 1)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Now, for another study (let's say study 2) with a different set of IDS, I need to go over each ID list (which is entirely different from the above list- but for each id, I need to assign each id above.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For ex&lt;/P&gt;
&lt;P&gt;abc&amp;nbsp;(study 2) = ab (study 1)&lt;/P&gt;
&lt;P&gt;d3e (study 2) = xy (study 1)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thoughts?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Dec 2018 19:35:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Grab-ID-and-assign-another-ID-from-a-macro-list/m-p/521616#M141547</guid>
      <dc:creator>saslove</dc:creator>
      <dc:date>2018-12-14T19:35:56Z</dc:date>
    </item>
    <item>
      <title>Re: Grab ID and assign another ID from a macro list</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Grab-ID-and-assign-another-ID-from-a-macro-list/m-p/521626#M141549</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/1717"&gt;@saslove&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;I have an ID list&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;%let study1_ids="ab","xy","we","st","ut","po","vc","gh"; (study 1)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Now, for another study (let's say study 2) with a different set of IDS, I need to go over each ID list (which is entirely different from the above list- but for each id, I need to assign each id above.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For ex&lt;/P&gt;
&lt;P&gt;abc&amp;nbsp;(study 2) = ab (study 1)&lt;/P&gt;
&lt;P&gt;d3e (study 2) = xy (study 1)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thoughts?&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Question the need for quotes and commas in that study1_ids.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This makes no sense in SAS: what&amp;nbsp;are ABC, AB, d3e or xy. If they are values of a variable then what is the name of the variable?&lt;/P&gt;
&lt;PRE&gt;abc (study 2) = ab (study 1)

d3e (study 2) = xy (study 1)
&lt;/PRE&gt;
&lt;P&gt;Provide a few concrete examples with values from both "lists" and what the result should be.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This sort of sounds like you probably should have the values involved in data sets and then SQL to match things.&lt;/P&gt;</description>
      <pubDate>Fri, 14 Dec 2018 19:53:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Grab-ID-and-assign-another-ID-from-a-macro-list/m-p/521626#M141549</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-12-14T19:53:06Z</dc:date>
    </item>
  </channel>
</rss>

