gsqlcmd Template Options
/noTemplate
Use this option to disable use of a template for HTML and XML output.
/placeholder=<placeholder>
Use this option to define a template placeholder to insert output data.
For example, if a template like sales_report.htm contains the {sales} placeholder, use the option:
gsqlcmd exec db export-sales.sql /asHtml /template=sales_report.htm /placeholder={sales}
The default HTML and XML templates contain a single {table} placeholder used by default.
For example, the command with the default template looks like
gsqlcmd exec db export-sales.sql sales_report.htm
/template=<file name>
Use this option to define an output template.
Use it with the /placeholder option.
For example, if a template like sales_report.htm contains the {sales} placeholder, use the option:
/template=sales_report.htm /placeholder={sales}
Note that you can edit the default XML and HTML templates located in the Resources folder.
The default templates contain the {table} placeholder used by default.
The HTML template can also contain the {title} placeholder to include a value of the /title option.
/title=<title>
Use this option to define a value for the {title} placeholder of HTML templates.
For example:
gsqlcmd exec db export-sales.sql sales_report.htm "/title=Sales Report"
In this command, gsqlcmd creates the sales_report.htm using the default template, inserting data into the {table} placeholder and the specified title into the {title} placeholder.
Contents