Difference between revisions of "Searching for Custom Field Settings Using a Report"

From SmartWiki
Jump to: navigation, search
(Created page with "You can import the following SmartSimple report to search for custom fields in your system with certain values in the Options/Template/...")
 
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
You can [[Importing and Exporting Reports|import]] the following SmartSimple report to search for [[custom fields]] in your system with certain values in the Options/Template/Default Value section of the custom field settings.
 
You can [[Importing and Exporting Reports|import]] the following SmartSimple report to search for [[custom fields]] in your system with certain values in the Options/Template/Default Value section of the custom field settings.
 
  
 
When the report is imported, it will be named "Custom Field - Search Contents" and will be located in the "Custom Fields" report category.
 
When the report is imported, it will be named "Custom Field - Search Contents" and will be located in the "Custom Fields" report category.
 
  
 
When run, the report will prompt you for a text string to be found in the Options/Template/Default Value section of all custom fields in your system and will allow you to view the field settings.
 
When run, the report will prompt you for a text string to be found in the Options/Template/Default Value section of all custom fields in your system and will allow you to view the field settings.
 
  
 
<pre style="white-space: pre-wrap;  white-space: -moz-pre-wrap;  white-space: -pre-wrap;  white-space: -o-pre-wrap;  word-wrap: break-word;"><reportexport>
 
<pre style="white-space: pre-wrap;  white-space: -moz-pre-wrap;  white-space: -pre-wrap;  white-space: -o-pre-wrap;  word-wrap: break-word;"><reportexport>
Line 31: Line 28:
 
  <compiledsql>SELECT customfieldid as objpkey,0 as `~Index~`,customfieldid as 1_customfieldid,name as 2_name,caption as 3_caption,if(allowempty=1,&quot;Yes&quot;,&quot;No&quot;) as 5_allowempty,CONCAT(&quot;&lt;a href=&apos;/s_editcustomfield.jsp?nextlevel=1&amp;entity=&quot;,entity,&quot;&amp;appid=&quot;,CASE WHEN entity in (24,23,26,18,31,28) THEN 102884 WHEN entity=78 THEN itemid ELSE &quot;&quot; END,&quot;&amp;field=&quot;,customfieldid,&quot;&amp;itemid=&quot;,itemid,&quot;&amp;title=Edit&apos; target=&apos;_blank&apos;&gt;View Field&lt;/a&gt;&quot;) as 6_customfieldid FROM SS_System.tblcustomfields
 
  <compiledsql>SELECT customfieldid as objpkey,0 as `~Index~`,customfieldid as 1_customfieldid,name as 2_name,caption as 3_caption,if(allowempty=1,&quot;Yes&quot;,&quot;No&quot;) as 5_allowempty,CONCAT(&quot;&lt;a href=&apos;/s_editcustomfield.jsp?nextlevel=1&amp;entity=&quot;,entity,&quot;&amp;appid=&quot;,CASE WHEN entity in (24,23,26,18,31,28) THEN 102884 WHEN entity=78 THEN itemid ELSE &quot;&quot; END,&quot;&amp;field=&quot;,customfieldid,&quot;&amp;itemid=&quot;,itemid,&quot;&amp;title=Edit&apos; target=&apos;_blank&apos;&gt;View Field&lt;/a&gt;&quot;) as 6_customfieldid FROM SS_System.tblcustomfields
 
  WHERE (rootcompanyid=@rootcompanyid@) aNd (1=1) AND ((options like concat(&quot;%&quot;,*10_0_850*,&quot;%&quot;))) Group By customfieldid Order By 1_customfieldid ASC </compiledsql>
 
  WHERE (rootcompanyid=@rootcompanyid@) aNd (1=1) AND ((options like concat(&quot;%&quot;,*10_0_850*,&quot;%&quot;))) Group By customfieldid Order By 1_customfieldid ASC </compiledsql>
  <promptmsg>Enter search term</promptmsg>
+
  <promptmsg>-Enter search term</promptmsg>
 
  <compiledheader>&quot;#&quot;,&quot;Custom Field ID&quot;,&quot;Field Name&quot;,&quot;Field Caption&quot;,&quot;Allow Empty&quot;,&quot;Edit&quot;</compiledheader>
 
  <compiledheader>&quot;#&quot;,&quot;Custom Field ID&quot;,&quot;Field Name&quot;,&quot;Field Caption&quot;,&quot;Allow Empty&quot;,&quot;Edit&quot;</compiledheader>
 
  <htmlheader>&lt;tr&gt;&lt;th class=Sub&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;1_customfieldid&apos;)&quot;&gt;Custom Field ID&lt;/a&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;2_name&apos;)&quot;&gt;Field Name&lt;/a&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;3_caption&apos;)&quot;&gt;Field Caption&lt;/a&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;5_allowempty&apos;)&quot;&gt;Allow Empty&lt;/a&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;6_customfieldid&apos;)&quot;&gt;Edit&lt;/a&gt;&lt;/th&gt;&lt;/tr&gt;</htmlheader>
 
  <htmlheader>&lt;tr&gt;&lt;th class=Sub&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;1_customfieldid&apos;)&quot;&gt;Custom Field ID&lt;/a&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;2_name&apos;)&quot;&gt;Field Name&lt;/a&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;3_caption&apos;)&quot;&gt;Field Caption&lt;/a&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;5_allowempty&apos;)&quot;&gt;Allow Empty&lt;/a&gt;&lt;/th&gt;&lt;th class=Sub&gt;&lt;a class=SubHead href=&quot;javascript:orderreport(&apos;6_customfieldid&apos;)&quot;&gt;Edit&lt;/a&gt;&lt;/th&gt;&lt;/tr&gt;</htmlheader>
Line 163: Line 160:
 
==See Also==
 
==See Also==
 
* [[Importing and Exporting Reports]]
 
* [[Importing and Exporting Reports]]
* [[Reporting on Custom Fields]][[Category:Reports]]
+
* [[Reporting on Custom Fields]]
 +
 
 +
[[Category:Reports]][[Category:Custom Fields]]

Latest revision as of 12:58, 3 November 2014

You can import the following SmartSimple report to search for custom fields in your system with certain values in the Options/Template/Default Value section of the custom field settings.

When the report is imported, it will be named "Custom Field - Search Contents" and will be located in the "Custom Fields" report category.

When run, the report will prompt you for a text string to be found in the Options/Template/Default Value section of all custom fields in your system and will allow you to view the field settings.

<reportexport>
 <cfmapping></cfmapping>
 <typemapping></typemapping>
 <customfieldlist></customfieldlist>
 <excel_start></excel_start>
 <excel_file>0</excel_file>
 <excel_exformat>1</excel_exformat>
 <excel_mstart></excel_mstart>
 <word_tablebm></word_tablebm>
 <donotrebuild>0</donotrebuild>
 <mergesubrpt>0</mergesubrpt>
 <objectids>9000,</objectids>
 <primaryobjectid>9000</primaryobjectid>
 <fieldlist>,0,844,845,846,842</fieldlist>
 <custabletype></custabletype>
 <totallist>Custom Fields</totallist>
 <totalcustomfield></totalcustomfield>
 <reportfilter></reportfilter>
 <header></header>
 <footer></footer>
 <description>Searches the contents (Options, default values, WPV content etc) for the text entered</description>
 <compiledsql>SELECT customfieldid as objpkey,0 as `~Index~`,customfieldid as 1_customfieldid,name as 2_name,caption as 3_caption,if(allowempty=1,"Yes","No") as 5_allowempty,CONCAT("<a href='/s_editcustomfield.jsp?nextlevel=1&entity=",entity,"&appid=",CASE WHEN entity in (24,23,26,18,31,28) THEN 102884 WHEN entity=78 THEN itemid ELSE "" END,"&field=",customfieldid,"&itemid=",itemid,"&title=Edit' target='_blank'>View Field</a>") as 6_customfieldid FROM SS_System.tblcustomfields
 WHERE (rootcompanyid=@rootcompanyid@) aNd (1=1) AND ((options like concat("%",*10_0_850*,"%"))) Group By customfieldid Order By 1_customfieldid ASC </compiledsql>
 <promptmsg>-Enter search term</promptmsg>
 <compiledheader>"#","Custom Field ID","Field Name","Field Caption","Allow Empty","Edit"</compiledheader>
 <htmlheader><tr><th class=Sub></th><th class=Sub><a class=SubHead href="javascript:orderreport('1_customfieldid')">Custom Field ID</a></th><th class=Sub><a class=SubHead href="javascript:orderreport('2_name')">Field Name</a></th><th class=Sub><a class=SubHead href="javascript:orderreport('3_caption')">Field Caption</a></th><th class=Sub><a class=SubHead href="javascript:orderreport('5_allowempty')">Allow Empty</a></th><th class=Sub><a class=SubHead href="javascript:orderreport('6_customfieldid')">Edit</a></th></tr></htmlheader>
 <compiledtag><tr><td class=Data1>~Index~</td><td class=Data1>~1_customfieldid~</td><td class=Data1>~2_name~</td><td class=Data1>~3_caption~</td><td class=Data1>~5_allowempty~</td><td class=Data1>~6_customfieldid~</td></tr></compiledtag>
 <compiledtemplate></compiledtemplate>
 <criteriatemplate></criteriatemplate>
 <recordlimit>0</recordlimit>
 <usenewbuilder>1</usenewbuilder>
 <buildermatrix><reportbuilder>
 <column>
 <columnindex>0</columnindex>
 <columnname>#</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>0 as `~Index~`::0</fields>
 <columnsql>0 as `~Index~`</columnsql>
 <visibles>1</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>1</columnindex>
 <columnname>Custom Field ID</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>customfieldid as customfieldid::844</fields>
 <columnsql>customfieldid as customfieldid</columnsql>
 <groupby>10</groupby>
 <sortby>ASC</sortby>
 <visibles>1</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>2</columnindex>
 <columnname>Field Name</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>name as name::845</fields>
 <columnsql>name as name</columnsql>
 <visibles>1</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>3</columnindex>
 <columnname>Field Caption</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>caption as caption::846</fields>
 <columnsql>caption as caption</columnsql>
 <visibles>1</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>4</columnindex>
 <columnname>Field Description</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>cusdesp as cusdesp::847</fields>
 <columnsql>cusdesp as cusdesp</columnsql>
 <visibles>0</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>5</columnindex>
 <columnname>Allow Empty</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>if(allowempty=1,"Yes","No") as allowempty::842</fields>
 <columnsql>if(allowempty=1,"Yes","No") as allowempty</columnsql>
 <visibles>1</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>6</columnindex>
 <columnname>Edit</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>customfieldid as customfieldid::844</fields>
 <columnsql>CONCAT("@lt@a href='/s_editcustomfield.jsp?nextlevel=1@at@entity=",entity,"@at@appid=",CASE WHEN entity in (24,23,26,18,31,28) THEN 102884 WHEN entity=78 THEN itemid ELSE "" END,"@at@field=",customfieldid,"@at@itemid=",itemid,"@at@title=Edit' target='_blank'@gt@View Field@lt@/a@gt@") as customfieldid</columnsql>
 <advcus>CONCAT("@lt@a href='/s_editcustomfield.jsp?nextlevel=1@at@entity=",[9],"@at@appid=",CASE WHEN [9] in (24,23,26,18,31,28) THEN 102884 WHEN [9]=78 THEN [8] ELSE "" END,"@at@field=",[2],"@at@itemid=",[8],"@at@title=Edit' target='_blank'@gt@View Field@lt@/a@gt@")</advcus>
 <visibles>1</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>7</columnindex>
 <columnname>Item ID</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>itemid as itemid::839</fields>
 <columnsql>itemid as itemid</columnsql>
 <visibles>0</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>8</columnindex>
 <columnname>Entity</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>entity as entity::840</fields>
 <columnsql>entity as entity</columnsql>
 <visibles>0</visibles>
 <totals>0</totals>
 </column>
 <column>
 <columnindex>9</columnindex>
 <columnname>Options/Template/Default Value</columnname>
 <tabletype>9000</tabletype>
 <fieldtype>9000:0:0</fieldtype>
 <fields>options as options::850</fields>
 <columnsql>options as options</columnsql>
 <visibles>0</visibles>
 <totals>0</totals>
 <criteria1>like concat("%",???,"%")</criteria1>
 </column>
 <columnmapping>#==~Index~;;Custom Field ID==~1_customfieldid~;;Field Name==~2_name~;;Field Caption==~3_caption~;;==;;Allow Empty==~5_allowempty~;;Edit==~6_customfieldid~;;==;;==;;==;;</columnmapping>
 </reportbuilder></buildermatrix>
 <issingleview>0</issingleview>
 <rinetenabled>0</rinetenabled>
 <singleviewtemplate></singleviewtemplate>
 <compiledsingleview></compiledsingleview>
 <cacheenabled>0</cacheenabled>
 <hideglobaltemplate>0</hideglobaltemplate>
 <cacheinterval>0</cacheinterval>
 <cacheuser>0</cacheuser>
 <straightjoin>0</straightjoin>
 <enabletranslate>0</enabletranslate>
 <noparas>0</noparas>
 <name>Custom Field - Search Contents</name>
 </reportexport>
 

See Also