<?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 proc format in permanent library in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/proc-format-in-permanent-library/m-p/545693#M151019</link>
    <description>&lt;P&gt;Hello&lt;/P&gt;
&lt;P&gt;I am trying to learn how to create a permanent user define format.&lt;/P&gt;
&lt;P&gt;Please find the code below.&lt;/P&gt;
&lt;P&gt;When I am trying to use this format I get an error.&lt;/P&gt;
&lt;P&gt;" Format SMOKE was not found or could not be loaded."&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Libname project  "/path/";
proc format library=project;
value smoke
.='missing'
1='current smoker'
2='former smoker'
3='never smoked'
;
run;
data aa;
input ID smokestatus;
cards;
1 1
2 1
3 2
;
run;
data bb;
set aa;
format smokestatus smoke.;
Run;
proc print data=bb noobs;run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Mon, 25 Mar 2019 06:17:01 GMT</pubDate>
    <dc:creator>Ronein</dc:creator>
    <dc:date>2019-03-25T06:17:01Z</dc:date>
    <item>
      <title>proc format in permanent library</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-in-permanent-library/m-p/545693#M151019</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;
&lt;P&gt;I am trying to learn how to create a permanent user define format.&lt;/P&gt;
&lt;P&gt;Please find the code below.&lt;/P&gt;
&lt;P&gt;When I am trying to use this format I get an error.&lt;/P&gt;
&lt;P&gt;" Format SMOKE was not found or could not be loaded."&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Libname project  "/path/";
proc format library=project;
value smoke
.='missing'
1='current smoker'
2='former smoker'
3='never smoked'
;
run;
data aa;
input ID smokestatus;
cards;
1 1
2 1
3 2
;
run;
data bb;
set aa;
format smokestatus smoke.;
Run;
proc print data=bb noobs;run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 25 Mar 2019 06:17:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-in-permanent-library/m-p/545693#M151019</guid>
      <dc:creator>Ronein</dc:creator>
      <dc:date>2019-03-25T06:17:01Z</dc:date>
    </item>
    <item>
      <title>Re: proc format in permanent library</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-format-in-permanent-library/m-p/545696#M151020</link>
      <description>&lt;P&gt;When you put formats into another library than WORK, you need to adapt the &lt;A href="https://documentation.sas.com/?cdcId=pgmsascdc&amp;amp;cdcVersion=9.4_3.4&amp;amp;docsetId=lesysoptsref&amp;amp;docsetTarget=p1fvn6rwmpf1njn1whkud1hmsc97.htm&amp;amp;locale=en" target="_blank" rel="noopener"&gt;FMTSEARCH&lt;/A&gt; system option accordingly.&lt;/P&gt;
&lt;P&gt;Per default, SAS searches for formats in WORK and in a library called LIBRARY, if such exists (predefined formats in SASHELP are always searched, of course).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In your case you have to add&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;options fmtsearch=(work project);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;before the format can be used successfully. Defining a library called LIBRARY and defining your permanent formats there would work without having to change the FMTSEARCH option.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Mar 2019 06:30:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-format-in-permanent-library/m-p/545696#M151020</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2019-03-25T06:30:30Z</dc:date>
    </item>
  </channel>
</rss>

