<?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 Informat to convert char time variable to numeric time variable in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Informat-to-convert-char-time-variable-to-numeric-time-variable/m-p/786257#M251006</link>
    <description>&lt;PRE&gt;data new;
   comm_time = '13:08:09';
   numeric_comm_time = input(comm_time, ???.);
run;&lt;/PRE&gt;
&lt;P&gt;The actual dataset shows the comm-time as a char variable.&amp;nbsp; Since I will need to use the comm_time in a calculation with a date&lt;/P&gt;
&lt;P&gt;IE if date1 &amp;lt; date2 and com_time1 &amp;lt; comm_time 2 then do something......&lt;/P&gt;
&lt;P&gt;I will need to display/convert the char variable to a numeric variable.&amp;nbsp; I just do not know what to insert in the input value where I am showing ??? Notice it shows as 13:08:09.&amp;nbsp; Is there an informat to address this???&lt;/P&gt;</description>
    <pubDate>Thu, 16 Dec 2021 04:03:28 GMT</pubDate>
    <dc:creator>Q1983</dc:creator>
    <dc:date>2021-12-16T04:03:28Z</dc:date>
    <item>
      <title>Informat to convert char time variable to numeric time variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Informat-to-convert-char-time-variable-to-numeric-time-variable/m-p/786257#M251006</link>
      <description>&lt;PRE&gt;data new;
   comm_time = '13:08:09';
   numeric_comm_time = input(comm_time, ???.);
run;&lt;/PRE&gt;
&lt;P&gt;The actual dataset shows the comm-time as a char variable.&amp;nbsp; Since I will need to use the comm_time in a calculation with a date&lt;/P&gt;
&lt;P&gt;IE if date1 &amp;lt; date2 and com_time1 &amp;lt; comm_time 2 then do something......&lt;/P&gt;
&lt;P&gt;I will need to display/convert the char variable to a numeric variable.&amp;nbsp; I just do not know what to insert in the input value where I am showing ??? Notice it shows as 13:08:09.&amp;nbsp; Is there an informat to address this???&lt;/P&gt;</description>
      <pubDate>Thu, 16 Dec 2021 04:03:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Informat-to-convert-char-time-variable-to-numeric-time-variable/m-p/786257#M251006</guid>
      <dc:creator>Q1983</dc:creator>
      <dc:date>2021-12-16T04:03:28Z</dc:date>
    </item>
    <item>
      <title>Re: Informat to convert char time variable to numeric time variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Informat-to-convert-char-time-variable-to-numeric-time-variable/m-p/786266#M251008</link>
      <description>&lt;P&gt;Quite obvious: you want to read a time, and the length of the string is 8, so try TIME8.&lt;/P&gt;</description>
      <pubDate>Thu, 16 Dec 2021 06:44:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Informat-to-convert-char-time-variable-to-numeric-time-variable/m-p/786266#M251008</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2021-12-16T06:44:49Z</dc:date>
    </item>
  </channel>
</rss>

