ASA SQL Reference
System Procedures and Functions
System and catalog stored procedures
Permits a web service to set an HTTP header in the result.
sa_set_http_header (field-name, value)
field-name A string containing the name of one of the HTTP header fields.
value The value to which the named parameter should be set.
None.
None.
sa_set_http_option system procedure
call dbo.sa_set_http_header( 'Content-Type', 'text/html' )
Setting the special header field @HttpStatus sets the status code returned with the request. For example, the following command sets the status code to 404 Not Found.
dbo.sa_set_http_header( '@HttpStatus', '404' )
The body of the error message is inserted automatically. Only valid HTTP error codes can be used. Setting the status to an invalid code causes an SQL error.