File tree Expand file tree Collapse file tree
doc/build/changelog/unreleased_20
lib/sqlalchemy/dialects/oracle Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ .. change::
2+ :tags: bug, reflection, oracle
3+ :tickets: 11557
4+
5+ Fixed table reflection on Oracle 10.2 and older where compression options
6+ are not supported.
Original file line number Diff line number Diff line change @@ -2051,8 +2051,16 @@ def _table_options_query(
20512051 ):
20522052 query = select (
20532053 dictionary .all_tables .c .table_name ,
2054- dictionary .all_tables .c .compression ,
2055- dictionary .all_tables .c .compress_for ,
2054+ (
2055+ dictionary .all_tables .c .compression
2056+ if self ._supports_table_compression
2057+ else sql .null ().label ("compression" )
2058+ ),
2059+ (
2060+ dictionary .all_tables .c .compress_for
2061+ if self ._supports_table_compress_for
2062+ else sql .null ().label ("compress_for" )
2063+ ),
20562064 ).where (dictionary .all_tables .c .owner == owner )
20572065 if has_filter_names :
20582066 query = query .where (
You can’t perform that action at this time.
0 commit comments