Qore Schema Module Reference  1.1.1
 All Classes Namespaces Functions Variables Groups Pages
Schema Namespace Reference

this namespace contains all public definitions in the Schema module More...

Classes

class  AbstractSchema
 the AbstractSchema class is a base class to assist with automatic schema management More...
 
class  AbstractVersionedSchema
 this class extends Schema::AbstractSchema by providing version logic based on a schema version string contained within the schema itself More...
 
class  SchemaCallbackHelper
 this class provides callback support for schema operations More...
 

Functions

hash c_char (int size, bool notnull=False, *string comment)
 returns a column hash for a CHAR column More...
 
hash c_char (int size, string comment)
 returns a column hash for a CHAR column More...
 
hash c_date (bool notnull=False, *string comment)
 returns a column hash for a DATE column More...
 
hash c_date (string comment)
 returns a column hash for a DATE column More...
 
hash c_int (bool notnull=False, *string comment)
 returns a column hash for an INT column More...
 
hash c_int (string comment)
 returns a column hash for an INT column More...
 
hash c_number (bool notnull=False, *string comment)
 returns a column hash for a NUMBER or NUMERIC column More...
 
hash c_number (int size, int scale, bool notnull=False, *string comment)
 returns a column hash for a NUMBER or NUMERIC column More...
 
hash c_number (int size, bool notnull=False, *string comment)
 returns a column hash for a NUMBER or NUMERIC column More...
 
hash c_number (int size, string comment)
 returns a column hash for a NUMBER or NUMERIC column More...
 
hash c_timestamp (bool notnull=False, *string comment)
 returns a column hash for a TIMESTAMP column More...
 
hash c_timestamp (string comment)
 returns a column hash for a TIMESTAMP column More...
 
hash c_varchar (int size, bool notnull=False, *string comment)
 returns a column hash for a VARCHAR column More...
 
hash c_varchar (int size, string comment)
 returns a column hash for a VARCHAR column More...
 

Variables

const C_NOT_NULL = True
 Helper constant for column hash functions with "NOT NULL" constraint for better readability.
 
const C_NULL = False
 Helper constant for column hash functions with "NULL" constraint for better readability.
 

Detailed Description

this namespace contains all public definitions in the Schema module

Function Documentation

hash Schema::c_char ( int  size,
bool  notnull = False,
*string  comment 
)

returns a column hash for a CHAR column

Parameters
sizethe size of the column
notnullTrue for a NOT NULL constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
commentan optional comment for the column
hash Schema::c_char ( int  size,
string  comment 
)

returns a column hash for a CHAR column

Parameters
sizethe size of the column
commentthe comment for the column
hash Schema::c_date ( bool  notnull = False,
*string  comment 
)

returns a column hash for a DATE column

Parameters
notnullTrue for a NOT NULL constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
commentan optional comment for the column
See Also
c_timestamp()
hash Schema::c_date ( string  comment)

returns a column hash for a DATE column

Parameters
commentthe comment for the column
See Also
c_timestamp()
hash Schema::c_int ( bool  notnull = False,
*string  comment 
)

returns a column hash for an INT column

Parameters
notnullTrue for a NOT NULL constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
commentan optional comment for the column
Note
might be a numeric type if INT is not supported by the dataserver
See Also
c_number()
hash Schema::c_int ( string  comment)

returns a column hash for an INT column

Parameters
commentthe comment for the column
Note
might be a numeric type if INT is not supported by the dataserver
See Also
c_number()
hash Schema::c_number ( bool  notnull = False,
*string  comment 
)

returns a column hash for a NUMBER or NUMERIC column

Parameters
notnullTrue for a NOT NULL constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
commentan optional comment for the column
See Also
c_int()
hash Schema::c_number ( int  size,
int  scale,
bool  notnull = False,
*string  comment 
)

returns a column hash for a NUMBER or NUMERIC column

Parameters
sizethe size of the column
scalethe scale of the column
notnullTrue for a NOT NULL constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
commentan optional comment for the column
See Also
c_int()
hash Schema::c_number ( int  size,
bool  notnull = False,
*string  comment 
)

returns a column hash for a NUMBER or NUMERIC column

Parameters
sizethe size of the column
notnullTrue for a NOT NULL constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
commentan optional comment for the column
See Also
c_int()
hash Schema::c_number ( int  size,
string  comment 
)

returns a column hash for a NUMBER or NUMERIC column

Parameters
sizethe size of the column
commenta comment for the column
See Also
c_int()
hash Schema::c_timestamp ( bool  notnull = False,
*string  comment 
)

returns a column hash for a TIMESTAMP column

Parameters
notnullTrue for a NOT NULL constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
commentan optional comment for the column
See Also
c_date()
hash Schema::c_timestamp ( string  comment)

returns a column hash for a TIMESTAMP column

Parameters
commentthe comment for the column
See Also
c_date()
hash Schema::c_varchar ( int  size,
bool  notnull = False,
*string  comment 
)

returns a column hash for a VARCHAR column

Parameters
sizethe size of the column
notnullTrue for a NOT NULL constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
commentan optional comment for the column
hash Schema::c_varchar ( int  size,
string  comment 
)

returns a column hash for a VARCHAR column

Parameters
sizethe size of the column
commentthe comment for the column