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

  size | the size of the column
  notnull | True for a `NOT NULL` constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
  comment | an optional comment for the column

hash Schema::c_char | ( | int | size,
|  | string | comment
| ) |  |

returns a column hash for a `CHAR` column

Parameters

  size | the size of the column
  comment | the comment for the column

hash Schema::c_date | ( | bool | notnull = `False`,
|  | *string | comment
| ) |  |

returns a column hash for a `DATE` column

Parameters

  notnull | True for a `NOT NULL` constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
  comment | an optional comment for the column

See also
  c_timestamp()

hash Schema::c_date | ( | string | comment | ) |

returns a column hash for a `DATE` column

Parameters

  comment | the 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

  notnull | True for a `NOT NULL` constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
  comment | an 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

  comment | the 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

  notnull | True for a `NOT NULL` constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
  comment | an 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

  size | the size of the column
  scale | the scale of the column
  notnull | True for a `NOT NULL` constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
  comment | an 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

  size | the size of the column
  notnull | True for a `NOT NULL` constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
  comment | an 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

  size | the size of the column
  comment | a 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

  notnull | True for a `NOT NULL` constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
  comment | an optional comment for the column

See also
  c_date()

hash Schema::c_timestamp | ( | string | comment | ) |

returns a column hash for a `TIMESTAMP` column

Parameters

  comment | the 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

  size | the size of the column
  notnull | True for a `NOT NULL` constraint on the column. See constants Schema::C_NULL and Schema::C_NOT_NULL
  comment | an optional comment for the column

hash Schema::c_varchar | ( | int | size,
|  | string | comment
| ) |  |

returns a column hash for a `VARCHAR` column

Parameters

  size | the size of the column
  comment | the comment for the column