<?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 HASH - Reference definedate is not a member of object c error. in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/HASH-Reference-definedate-is-not-a-member-of-object-c-error/m-p/913594#M360080</link>
    <description>&lt;P&gt;Hi, I am currently studying for the SAS advanced programing exam. One of the practice questions has the following answer but when I try to run the code I get the below error. I tried changing the name of the hash object to something else but that didn't work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ERROR: DATA STEP Component Object failure. Aborted during the COMPILATION phase.&lt;BR /&gt;ERROR 558-185: Reference definedate is not a member of object c.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;DATA examples&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;work.continent&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;ID CtName&lt;BR /&gt;91 North America&lt;BR /&gt;93 Europe&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;work.airports&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;ID City Code Aname Country&lt;BR /&gt;91 Anchorage, AK ANC Anchorage International Airport USA&lt;BR /&gt;93 Stockholm ARN Arlanda Sweden&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;CODE:&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Data work.success work.fail;&lt;BR /&gt;drop rc;&lt;BR /&gt;length CtName $30;&lt;BR /&gt;If _N_=1 then do;&lt;BR /&gt;Call missing (CtName);&lt;BR /&gt;declare hash c(dataset:'work.continent');&lt;BR /&gt;c.definekey('ID');&lt;BR /&gt;c.definedate('CtName');&lt;BR /&gt;c.definedone();&lt;BR /&gt;end;&lt;BR /&gt;set work.airports;&lt;BR /&gt;rc=c.find();&lt;/P&gt;&lt;P&gt;if rc=0 then output work.sucess;&lt;/P&gt;&lt;P&gt;else output work.fail;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Proc print data=work.sucess;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Proc print data=work.fail;&lt;/P&gt;&lt;P&gt;run;&lt;BR /&gt;run;&lt;/P&gt;</description>
    <pubDate>Tue, 30 Jan 2024 15:16:26 GMT</pubDate>
    <dc:creator>TennisKM3</dc:creator>
    <dc:date>2024-01-30T15:16:26Z</dc:date>
    <item>
      <title>HASH - Reference definedate is not a member of object c error.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/HASH-Reference-definedate-is-not-a-member-of-object-c-error/m-p/913594#M360080</link>
      <description>&lt;P&gt;Hi, I am currently studying for the SAS advanced programing exam. One of the practice questions has the following answer but when I try to run the code I get the below error. I tried changing the name of the hash object to something else but that didn't work.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ERROR: DATA STEP Component Object failure. Aborted during the COMPILATION phase.&lt;BR /&gt;ERROR 558-185: Reference definedate is not a member of object c.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;DATA examples&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;work.continent&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;ID CtName&lt;BR /&gt;91 North America&lt;BR /&gt;93 Europe&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;work.airports&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;ID City Code Aname Country&lt;BR /&gt;91 Anchorage, AK ANC Anchorage International Airport USA&lt;BR /&gt;93 Stockholm ARN Arlanda Sweden&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;CODE:&lt;/STRONG&gt;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Data work.success work.fail;&lt;BR /&gt;drop rc;&lt;BR /&gt;length CtName $30;&lt;BR /&gt;If _N_=1 then do;&lt;BR /&gt;Call missing (CtName);&lt;BR /&gt;declare hash c(dataset:'work.continent');&lt;BR /&gt;c.definekey('ID');&lt;BR /&gt;c.definedate('CtName');&lt;BR /&gt;c.definedone();&lt;BR /&gt;end;&lt;BR /&gt;set work.airports;&lt;BR /&gt;rc=c.find();&lt;/P&gt;&lt;P&gt;if rc=0 then output work.sucess;&lt;/P&gt;&lt;P&gt;else output work.fail;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Proc print data=work.sucess;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Proc print data=work.fail;&lt;/P&gt;&lt;P&gt;run;&lt;BR /&gt;run;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jan 2024 15:16:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/HASH-Reference-definedate-is-not-a-member-of-object-c-error/m-p/913594#M360080</guid>
      <dc:creator>TennisKM3</dc:creator>
      <dc:date>2024-01-30T15:16:26Z</dc:date>
    </item>
    <item>
      <title>Re: HASH - Reference definedate is not a member of object c error.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/HASH-Reference-definedate-is-not-a-member-of-object-c-error/m-p/913597#M360082</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/187742"&gt;@TennisKM3&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Just two typos:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;The method's name is DEFINEDAT&lt;STRONG&gt;A&lt;/STRONG&gt;, not DEFINEDAT&lt;STRONG&gt;E&lt;/STRONG&gt;.&lt;/LI&gt;
&lt;LI&gt;The second "c" is missing in &lt;SPAN&gt;&lt;FONT face="courier new,courier"&gt;work.suc&lt;STRONG&gt;c&lt;/STRONG&gt;ess&lt;/FONT&gt; in the OUTPUT statement and the PROC PRINT step.&lt;/SPAN&gt;&lt;/LI&gt;
&lt;/OL&gt;</description>
      <pubDate>Tue, 30 Jan 2024 15:28:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/HASH-Reference-definedate-is-not-a-member-of-object-c-error/m-p/913597#M360082</guid>
      <dc:creator>FreelanceReinh</dc:creator>
      <dc:date>2024-01-30T15:28:17Z</dc:date>
    </item>
    <item>
      <title>Re: HASH - Reference definedate is not a member of object c error.</title>
      <link>https://communities.sas.com/t5/SAS-Programming/HASH-Reference-definedate-is-not-a-member-of-object-c-error/m-p/913600#M360084</link>
      <description>&lt;P&gt;Thanks! Spelling gets me every time.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jan 2024 15:31:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/HASH-Reference-definedate-is-not-a-member-of-object-c-error/m-p/913600#M360084</guid>
      <dc:creator>TennisKM3</dc:creator>
      <dc:date>2024-01-30T15:31:04Z</dc:date>
    </item>
  </channel>
</rss>

