Entering content frame

Function documentation Method rawCmd Locate the document in the library structure

Use

rawCmd is a method of the class DBM.

You use this method to send a Structure linkDBM command to the DBM server. Errors returned by the DBM Server do not trigger an exception.

Note

By contrast, errors that occur during execution of the method cmd do trigger exceptions.

Features

rawCmd (cmd_string)

 

cmd_string

DBM command

 

Result:

     Successful execution:

OK

Result of the DBM command

     if an error occurs:

ERR

Error message

Example

     You query the operational state of the database instance with the DBM command db_state:

result = session.rawCmd ('db_state')

print repr (result)

'OK\nState\nOFFLINE\n'

     You enter an invalid DBM command:

result = session.rawCmd ('invalid command')

print repr (result)

'ERR\n-24977,ERR_COMMAND: unknown command "invalid"\n'

 

Leaving content frame