Creates a global fault for a Web Service object.


   fault RECORD ,
   encoded INTEGER  )
  1. fault defines the Web Service fault.
  2. encoded defines an integer value specifying the encoding mechanism.


The createFault() method creates a global fault for this Web Service object.

The fault parameter can be of any type that defines the SOAP fault in a SOAP response. In case of SOAP fault, the client for this Web Service will receive a variable with the same structure.

When the parameter encoded is true (1), the SOAP Section 5 encoding mechanism is used. False (0) indicates the XML Schema mechanism.

In case of error, the method throws an exception and sets the status variable. Depending on the error, a human-readable description of the problem is available in the sqlca.sqlerrm register. See Error handling in GWS calls (status).