Class Call


  • public class Call
    extends Statement
    A statement that calls a procedure, and returns a resultant table. This is used to perform some sort of function over the database. For example, "CALL SYSTEM_MAKE_BACKUP('/my_backups/1')" makes a copy of the database in the given directory on the disk.
    Author:
    Tobias Downer
    • Constructor Detail

      • Call

        public Call()
    • Method Detail

      • prepare

        public void prepare()
                     throws DatabaseException
        Description copied from class: Statement
        Prepares the statement with the given Database object. This is called before the statement is evaluated. The prepare statement queries the database and resolves information about the statement (for example, it resolves column names and aliases and determines the tables that are touched by this statement so we can lock the appropriate tables before we evaluate).

        NOTE: Care must be taken to ensure that all methods called here are safe in as far as modifications to the data occuring. The rules for safety should be as follows. If the database is in EXCLUSIVE mode, then we need to wait until it's switched back to SHARED mode before this method is called. All collection of information done here should not involve any table state info. except for column count, column names, column types, etc. Queries such as obtaining the row count, selectable scheme information, and certainly 'getCellContents' must never be called during prepare. When prepare finishes, the affected tables are locked and the query is safe to 'evaluate' at which time table state is safe to inspect.

        Specified by:
        prepare in class Statement
        Throws:
        DatabaseException