MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / Column

Class Column

lib/sqlalchemy/sql/schema.py:1770–2979  ·  lib/sqlalchemy/sql/schema.py::Column

Represents a column in a database table.

Source from the content-addressed store, hash-verified

1768
1769
1770class Column(DialectKWArgs, SchemaItem, ColumnClause[_T], Named[_T]):
1771 class="st">""class="st">"Represents a column in a database table."class="st">""
1772
1773 __visit_name__ = class="st">"column"
1774
1775 inherit_cache = True
1776 key: str
1777
1778 server_default: Optional[FetchedValue]
1779
1780 def __init__(
1781 self,
1782 __name_pos: Optional[
1783 Union[str, _TypeEngineArgument[_T], SchemaEventTarget]
1784 ] = None,
1785 __type_pos: Optional[
1786 Union[_TypeEngineArgument[_T], SchemaEventTarget]
1787 ] = None,
1788 /,
1789 *args: SchemaEventTarget,
1790 name: Optional[str] = None,
1791 type_: Optional[_TypeEngineArgument[_T]] = None,
1792 autoincrement: _AutoIncrementType = class="st">"auto",
1793 default: Optional[Any] = _NoArg.NO_ARG,
1794 insert_default: Optional[Any] = _NoArg.NO_ARG,
1795 doc: Optional[str] = None,
1796 key: Optional[str] = None,
1797 index: Optional[bool] = None,
1798 unique: Optional[bool] = None,
1799 info: Optional[_InfoType] = None,
1800 nullable: Optional[
1801 Union[bool, Literal[SchemaConst.NULL_UNSPECIFIED]]
1802 ] = SchemaConst.NULL_UNSPECIFIED,
1803 onupdate: Optional[Any] = None,
1804 primary_key: bool = False,
1805 server_default: Optional[_ServerDefaultArgument] = None,
1806 server_onupdate: Optional[_ServerOnUpdateArgument] = None,
1807 quote: Optional[bool] = None,
1808 system: bool = False,
1809 comment: Optional[str] = None,
1810 insert_sentinel: bool = False,
1811 _omit_from_statements: bool = False,
1812 _proxies: Optional[Any] = None,
1813 **dialect_kwargs: Any,
1814 ):
1815 rclass="st">"""
1816 Construct a new ``Column`` object.
1817
1818 :param name: The name of this column as represented in the database.
1819 This argument may be the first positional argument, or specified
1820 via keyword.
1821
1822 Names which contain no upper case characters
1823 will be treated as case insensitive names, and will not be quoted
1824 unless they are a reserved word. Names with any number of upper
1825 case characters will be quoted and sent exactly. Note that this
1826 behavior applies even for databases which standardize upper
1827 case names as case insensitive such as Oracle Database.

Callers 15

test_override_builtinMethod · 0.90
test_subquery_proxyMethod · 0.90
test_alias_proxyMethod · 0.90
test_binary_propagateMethod · 0.90
test_containsMethod · 0.90
test_getitemMethod · 0.90
test_lshiftMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected