Query
blackline.factories.query
QueryFactory
Query builder class to build query object.
Source code in BAR /opt/hostedtoolcache/Python/3.10.12/x64/lib/python3.10/site-packages/blackline/factories/query.py
collection = collection
instance-attribute
date_format = date_format
instance-attribute
dialect = dialect
instance-attribute
start_date = start_date or datetime.now()
instance-attribute
template = Template(trim_blocks=True, lstrip_blocks=True, params=template_params, where=where_clause)
instance-attribute
__init__(collection, template_params=None, dialect=None, start_date=None, date_format='%Y-%m-%d', where_clause=None)
summary
Parameters:
Name | Type | Description | Default |
---|---|---|---|
collection |
DatasetCollection
|
description |
required |
start_date |
Optional[datetime]
|
description. Defaults to None. |
None
|
template_params |
Optional[TemplateParams]
|
description. Defaults to None. # noqa: E501 |
None
|
date_format |
str
|
description. Defaults to "%Y-%m-%d". |
'%Y-%m-%d'
|
where_clause |
Optional[str]
|
Where clause that will be APPENDED to exisiting WHERE |
None
|
Source code in /opt/hostedtoolcache/Python/3.10.12/x64/lib/python3.10/site-packages/blackline/factories/query.py
cutoff_date(period)
fields_by_period()
Get columns by retention period.