SQLite3x.get_columns
def get_columns(
self,
table: AnyStr
) -> Generator[SQLite3xColumn, None, None]:
"""
Get columns of table as AbstractColumns objects
Parameters
----------
table : AnyStr
Name of table
Returns
----------
Tuple
Columns of table as AbstractColumns objects
"""
Get columns of table as AbstractColumns objects
Example
import sqllex as sx
db = sx.SQLite3x(path='database.db')
# db = sx.PostgreSQL(...)
for column in db.get_columns('table1'):
print(column.name)