Server Administration > Reports > Best Practices for Creating Report Recipes
  
Best Practices for Creating Report Recipes
This section describes best practices for creating report recipes, as recommended by PTC. It also points out efficiencies that can be gained by creating report recipes in a certain way, as well as identifying any risks, constraints, or other limits.
Do not directly modify existing report recipes
To preserve existing report recipes for future use, create a copy of the recipe and modify the copy to suit your needs.
Include comments in a report recipe
To document the functions of tags in a report recipe, PTC recommends including comments before each distinct block of tags. If a report is very large, this can simplify navigation in the report recipe for you and other authors. For example:
<!-- Change Package Entries info -->
<!-- Display change package entry heading -->
<tr>
<td class="heading4">&cpentryheading</td>
</tr>
Use the <%weburl%> tag to create URLs in report recipes
The <%weburl%> tag automatically resolves to http:// or https://, depending on whether SSL is enabled on the Windchill RV&S server. This prevents you from having to update report recipes whenever SSL is enabled or disabled.
Recommended: <img src="<%weburl%>logo.gif">
Not recommended: <img src="http://<%hostname%>:<%hostport%>/logo.gif">
Refrain from using hard-coded field names in report recipes
If possible, use report parameters so that the recipe can be dynamically configured by the report creator and used for more than one purpose.
If you must use hard-coded default Windchill RV&S fields in report recipes, use the <%builtin fieldname%> tag
Reports will not break if the default fieldname is changed.
Use report recipes and not report templates to create reports
Report templates contain hard-coded field names that, if changed, cause the report to break.