<?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 Easy Way to convert every var to Character in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795507#M40227</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I need to recreate an excel report, moving every formula to SAS.&lt;/P&gt;&lt;P&gt;The final form is not in a Dataset structure, variables names are on the left.&lt;/P&gt;&lt;P&gt;I will need to transpose everything.&lt;/P&gt;&lt;P&gt;Is there a way to convert easily the whole table to Character?&lt;/P&gt;&lt;P&gt;I mean without a macro function or a list of put().&lt;/P&gt;&lt;P&gt;Thank you in advance&lt;/P&gt;</description>
    <pubDate>Thu, 10 Feb 2022 15:42:38 GMT</pubDate>
    <dc:creator>eugeniothierry</dc:creator>
    <dc:date>2022-02-10T15:42:38Z</dc:date>
    <item>
      <title>Easy Way to convert every var to Character</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795507#M40227</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I need to recreate an excel report, moving every formula to SAS.&lt;/P&gt;&lt;P&gt;The final form is not in a Dataset structure, variables names are on the left.&lt;/P&gt;&lt;P&gt;I will need to transpose everything.&lt;/P&gt;&lt;P&gt;Is there a way to convert easily the whole table to Character?&lt;/P&gt;&lt;P&gt;I mean without a macro function or a list of put().&lt;/P&gt;&lt;P&gt;Thank you in advance&lt;/P&gt;</description>
      <pubDate>Thu, 10 Feb 2022 15:42:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795507#M40227</guid>
      <dc:creator>eugeniothierry</dc:creator>
      <dc:date>2022-02-10T15:42:38Z</dc:date>
    </item>
    <item>
      <title>Re: Easy Way to convert every var to Character</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795511#M40228</link>
      <description>Conveniently, TRANSPOSE often does this for you. So depending on how you do your transpose that may be one way. &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Or can you use PROC REPORT to create the report with ODS EXCEL?</description>
      <pubDate>Thu, 10 Feb 2022 16:00:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795511#M40228</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2022-02-10T16:00:14Z</dc:date>
    </item>
    <item>
      <title>Re: Easy Way to convert every var to Character</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795530#M40229</link>
      <description>&lt;PRE&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13879"&gt;@Reeza&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;Conveniently, TRANSPOSE often does this for you. So depending on how you do your transpose that may be one way. &lt;BR /&gt;&lt;BR /&gt;&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;When the VAR statement contains numeric variables and at least one character variable all number variables are converted to their FORMATTED values.&amp;nbsp; You will see this message.&lt;/P&gt;
&lt;PRE&gt;NOTE: Numeric variables in the input data set will be converted to character in the output data set.
&lt;/PRE&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc transpose data=sashelp.class out=allchar1;
   var _all_;
   run;
proc transpose data=allchar1 out=allchar2(drop=_name_);
   var col:;
   run;
proc contents varnum;
proc print;
   run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 253px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/68367i0C37717018AD0443/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Feb 2022 16:57:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795530#M40229</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2022-02-10T16:57:42Z</dc:date>
    </item>
    <item>
      <title>Re: Easy Way to convert every var to Character</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795545#M40230</link>
      <description>&lt;P&gt;One thing you cannot tell from looking at that ODS output is that the values are right aligned in the character fields.&amp;nbsp; If you look at the&amp;nbsp;POT (plain old text) output instead it is more visible.&lt;/P&gt;
&lt;PRE&gt;Obs    Name       Sex    Age    Height    Weight

  1    Alfred      M     14        69     112.5
  2    Alice       F     13      56.5        84
  3    Barbara     F     13      65.3        98
  4    Carol       F     14      62.8     102.5
  5    Henry       M     14      63.5     102.5
  6    James       M     12      57.3        83
  7    Jane        F     12      59.8      84.5
  8    Janet       F     15      62.5     112.5
  9    Jeffrey     M     13      62.5        84
 10    John        M     12        59      99.5
 11    Joyce       F     11      51.3      50.5
 12    Judy        F     14      64.3        90
 13    Louise      F     12      56.3        77
 14    Mary        F     15      66.5       112
 15    Philip      M     16        72       150
 16    Robert      M     12      64.8       128
 17    Ronald      M     15        67       133
 18    Thomas      M     11      57.5        85
 19    William     M     15      66.5       112

&lt;/PRE&gt;</description>
      <pubDate>Thu, 10 Feb 2022 18:09:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795545#M40230</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2022-02-10T18:09:46Z</dc:date>
    </item>
    <item>
      <title>Re: Easy Way to convert every var to Character</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795558#M40231</link>
      <description>&lt;P&gt;When right aligned in $200 it can be confusing.&amp;nbsp; I could have used a LEFT();&lt;/P&gt;</description>
      <pubDate>Thu, 10 Feb 2022 19:55:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795558#M40231</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2022-02-10T19:55:25Z</dc:date>
    </item>
    <item>
      <title>Re: Easy Way to convert every var to Character</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795568#M40232</link>
      <description>Thank you, when I transposed my data, numeric variables showed as "..." in SAS egp.&lt;BR /&gt;So I assumed something didn't work properly. I was wrong.&lt;BR /&gt;I will try proc report as I rarely use it.</description>
      <pubDate>Thu, 10 Feb 2022 21:48:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795568#M40232</guid>
      <dc:creator>eugeniothierry</dc:creator>
      <dc:date>2022-02-10T21:48:48Z</dc:date>
    </item>
    <item>
      <title>Re: Easy Way to convert every var to Character</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795597#M40233</link>
      <description>But It is not good for BIG table and not efficient .</description>
      <pubDate>Fri, 11 Feb 2022 05:00:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Easy-Way-to-convert-every-var-to-Character/m-p/795597#M40233</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2022-02-11T05:00:48Z</dc:date>
    </item>
  </channel>
</rss>

