<?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 insert year value in a creating table in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/insert-year-value-in-a-creating-table/m-p/873112#M344982</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
create table countries (name char(25), Capital char(25), Population num(45), Area num(35), 
Contant char(25), UNDate num informat=year4. format=year4. );
insert into countries values('Afghanistan','Kabul',17070323,251825,'Asia',1946);
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;In the above insert UNDate value 1946 problem output it gives 1965&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 01 May 2023 07:07:48 GMT</pubDate>
    <dc:creator>BrahmanandaRao</dc:creator>
    <dc:date>2023-05-01T07:07:48Z</dc:date>
    <item>
      <title>insert year value in a creating table</title>
      <link>https://communities.sas.com/t5/SAS-Programming/insert-year-value-in-a-creating-table/m-p/873112#M344982</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
create table countries (name char(25), Capital char(25), Population num(45), Area num(35), 
Contant char(25), UNDate num informat=year4. format=year4. );
insert into countries values('Afghanistan','Kabul',17070323,251825,'Asia',1946);
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;In the above insert UNDate value 1946 problem output it gives 1965&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 01 May 2023 07:07:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/insert-year-value-in-a-creating-table/m-p/873112#M344982</guid>
      <dc:creator>BrahmanandaRao</dc:creator>
      <dc:date>2023-05-01T07:07:48Z</dc:date>
    </item>
    <item>
      <title>Re: insert year value in a creating table</title>
      <link>https://communities.sas.com/t5/SAS-Programming/insert-year-value-in-a-creating-table/m-p/873114#M344983</link>
      <description>&lt;OL&gt;
&lt;LI&gt;There is no YEAR&amp;nbsp;&lt;U&gt;informat&lt;/U&gt;&lt;/LI&gt;
&lt;LI&gt;Maxim 1: Read the Documentation:&amp;nbsp;&lt;A href="https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/leforinforref/p0jwqba6i1r0j1n1xe9ovnn0pamr.htm" target="_blank" rel="noopener"&gt;YEAR Format&lt;/A&gt;&amp;nbsp;Study the documentation closely, and you will see why this conversion happens. Hint: see what kind of data the format expects; in which year is the 1946th day after 1960-01-01?&lt;/LI&gt;
&lt;/OL&gt;</description>
      <pubDate>Mon, 01 May 2023 07:53:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/insert-year-value-in-a-creating-table/m-p/873114#M344983</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2023-05-01T07:53:25Z</dc:date>
    </item>
    <item>
      <title>Re: insert year value in a creating table</title>
      <link>https://communities.sas.com/t5/SAS-Programming/insert-year-value-in-a-creating-table/m-p/873120#M344986</link>
      <description>&lt;P&gt;On top of what&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/11562"&gt;@Kurt_Bremser&lt;/a&gt;&amp;nbsp;said:&lt;/P&gt;
&lt;P&gt;Informats on a table don't come into play when using a SQL insert statement. You need already to provide in the insert statement the value that matches the data type.&lt;/P&gt;
&lt;P&gt;Informats come into play when using an INPUT statement.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Code below that uses a valid informat to demonstrate what I just wrote.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
  create table countries (
    name char(25), 
    Capital char(25), 
    Population num(45), 
    Area num(35), 
    Contant char(25),
    UNDate num informat=date9. 
    );
  insert into countries values('Afghanistan','Kabul',17070323,251825,'Asia','10Mar2023');
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Patrick_0-1682933061626.png" style="width: 1327px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/83438iE2CE9E8473FAD5E8/image-dimensions/1327x28?v=v2" width="1327" height="28" role="button" title="Patrick_0-1682933061626.png" alt="Patrick_0-1682933061626.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 01 May 2023 09:25:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/insert-year-value-in-a-creating-table/m-p/873120#M344986</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2023-05-01T09:25:06Z</dc:date>
    </item>
  </channel>
</rss>

