ALTER SERVICE statement

Use this statement to alter a web service.

Syntax 1 - DISH service
ALTER SERVICE service-name
[ TYPE 'DISH' ]
[ GROUP { group-name | NULL } ]
[ FORMAT { 'DNET' | 'CONCRETE' [ EXPLICIT { ON | OFF } ]| 'XML' | NULL } ]
[ common-attributes ]
Syntax 2 - SOAP service
ALTER SERVICE service-name
[ TYPE 'SOAP' ]
[ DATATYPE { ON | OFF | IN | OUT } ]
[ FORMAT { 'DNET' | 'CONCRETE' [ EXPLICIT { ON | OFF } ] | 'XML' | NULL } ]
[ common-attributes ]
[ AS statement ]
Syntax 3 - Miscellaneous services
ALTER SERVICE service-name
[ TYPE { 'RAW' | 'HTML' | 'XML' } ]
[ URL [ PATH ] { ON | OFF | ELEMENTS } ]
[ common-attributes ]
[ AS { statement | NULL } ]
common-attributes:
[ AUTHORIZATION { ON | OFF } ]
[ ENABLE | DISABLE ]
[ METHODS 'method,...' ]
[ SECURE { ON | OFF } ]
[ USER { user-name | NULL } ]
method:
DEFAULT
| POST
| GET
| HEAD
| PUT
| DELETE
| NONE
| *
Parameters

The description of the ALTER SERVICE parameters are identical to those of the CREATE SERVICE statement. See CREATE SERVICE statement.

Remarks

The ALTER SERVICE statement makes changes to the ISYSWEBSERVICE system table, and allows the database server to act as a web server.

Permissions

Must have DBA authority.

Side effects

None.

See also
Standards and compatibility
  • SQL/2003   Vendor extension.

Example

To set up a web server quickly, start a database server with the -xs (http or https) option, then execute the following statements:

CREATE SERVICE tables TYPE 'HTML';
ALTER SERVICE tables
   AUTHORIZATION OFF
   USER DBA
   AS SELECT *
      FROM SYS.SYSTAB;

After executing these statements, use any web browser to open the URL http://localhost/tables.