<?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 unable to read date value while connected to database in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/unable-to-read-date-value-while-connected-to-database/m-p/676714#M204069</link>
    <description>&lt;P&gt;Unable to read the value of date column while fetching from database . Please help me out.&lt;/P&gt;
&lt;P&gt;The corresponding date value is present in the following format&amp;nbsp; as mentioned below where closeddate appears as date variable .&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The following error is occurring&amp;nbsp; if we use any conversion functions&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;ERROR: PROC SQL requires any created table to have at least 1 column.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PROC SQL;&lt;BR /&gt;CONNECT TO ODBC(&lt;BR /&gt;DATAsrc='DATALAKE'&lt;BR /&gt;USER='****'&lt;BR /&gt;password='******'&lt;BR /&gt;);&lt;BR /&gt;create table main as&lt;BR /&gt;select * from&lt;BR /&gt;connection to odbc &lt;BR /&gt;(&lt;BR /&gt;SELECT&lt;BR /&gt;*&lt;BR /&gt;FROM&lt;BR /&gt;PROD.CASE_S A&lt;BR /&gt;where A.closedate=&lt;FONT color="#0000FF"&gt;'20MAR2018:17:06:35.000000'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FFFF00"&gt;)&lt;/FONT&gt;&lt;BR /&gt;;&lt;/P&gt;
&lt;P&gt;disconnect from odbc;&lt;BR /&gt;quit;&lt;/P&gt;</description>
    <pubDate>Fri, 14 Aug 2020 13:30:49 GMT</pubDate>
    <dc:creator>rohithverma</dc:creator>
    <dc:date>2020-08-14T13:30:49Z</dc:date>
    <item>
      <title>unable to read date value while connected to database</title>
      <link>https://communities.sas.com/t5/SAS-Programming/unable-to-read-date-value-while-connected-to-database/m-p/676714#M204069</link>
      <description>&lt;P&gt;Unable to read the value of date column while fetching from database . Please help me out.&lt;/P&gt;
&lt;P&gt;The corresponding date value is present in the following format&amp;nbsp; as mentioned below where closeddate appears as date variable .&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The following error is occurring&amp;nbsp; if we use any conversion functions&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;ERROR: PROC SQL requires any created table to have at least 1 column.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PROC SQL;&lt;BR /&gt;CONNECT TO ODBC(&lt;BR /&gt;DATAsrc='DATALAKE'&lt;BR /&gt;USER='****'&lt;BR /&gt;password='******'&lt;BR /&gt;);&lt;BR /&gt;create table main as&lt;BR /&gt;select * from&lt;BR /&gt;connection to odbc &lt;BR /&gt;(&lt;BR /&gt;SELECT&lt;BR /&gt;*&lt;BR /&gt;FROM&lt;BR /&gt;PROD.CASE_S A&lt;BR /&gt;where A.closedate=&lt;FONT color="#0000FF"&gt;'20MAR2018:17:06:35.000000'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FFFF00"&gt;)&lt;/FONT&gt;&lt;BR /&gt;;&lt;/P&gt;
&lt;P&gt;disconnect from odbc;&lt;BR /&gt;quit;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Aug 2020 13:30:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/unable-to-read-date-value-while-connected-to-database/m-p/676714#M204069</guid>
      <dc:creator>rohithverma</dc:creator>
      <dc:date>2020-08-14T13:30:49Z</dc:date>
    </item>
    <item>
      <title>Re: unable to read date value while connected to database</title>
      <link>https://communities.sas.com/t5/SAS-Programming/unable-to-read-date-value-while-connected-to-database/m-p/676723#M204071</link>
      <description>&lt;P&gt;Looks like you need help with the syntax used in your remote database?&amp;nbsp; Does the query you posted work?&amp;nbsp; Does it generate an error?&amp;nbsp; What is your actual issue?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What database are you connecting to?&amp;nbsp; How does that database want users to specify a literal datetime value in code?&lt;/P&gt;</description>
      <pubDate>Fri, 14 Aug 2020 13:32:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/unable-to-read-date-value-while-connected-to-database/m-p/676723#M204071</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2020-08-14T13:32:07Z</dc:date>
    </item>
    <item>
      <title>Re: unable to read date value while connected to database</title>
      <link>https://communities.sas.com/t5/SAS-Programming/unable-to-read-date-value-while-connected-to-database/m-p/676736#M204073</link>
      <description>By syntax wise it was working fine but it was not capturing the date value in the closeddate column . It leads to the below error when we try to use to_char or any function in the where condition in order to filter the data. Please help me on this if possible . &lt;BR /&gt;&lt;BR /&gt;ERROR: PROC SQL requires any created table to have at least 1 column.</description>
      <pubDate>Fri, 14 Aug 2020 14:12:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/unable-to-read-date-value-while-connected-to-database/m-p/676736#M204073</guid>
      <dc:creator>rohithverma</dc:creator>
      <dc:date>2020-08-14T14:12:02Z</dc:date>
    </item>
  </channel>
</rss>

