Skip to main content
add_known_type_from_table(table_name, type_descriptor)[source]

Sets what records of a table’s type decode with, as add_known_type(), finding the type out from the table. A class is mapped to the table’s type; a TypeObjectMap or GPUdbRecordType must have the table’s columns, in its order and of its types.

Parameters

table_name (str) –

The table.

type_descriptor –

As add_known_type() takes it.

Returns

The table’s type ID.

Raises

GPUdbException –

If the table cannot be shown, holds records of more than one type, or its type is not the one given.