Skip to content

Commit

Permalink
Bumped version and fixed small bug when filtering on a db name with d…
Browse files Browse the repository at this point in the history
…ifferent case
  • Loading branch information
oravidov committed Oct 17, 2021
1 parent 0bb4cfb commit 6e34e3c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lineage/snowflake_query_history.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class SnowflakeQueryHistory(QueryHistory):
('SHOW', 'COPY', 'COMMIT', 'DESCRIBE', 'ROLLBACK', 'CREATE_STREAM', 'DROP_STREAM', 'PUT_FILES',
'BEGIN_TRANSACTION', 'GRANT', 'ALTER_SESSION', 'USE') and
(query_text not ilike '%.query_history%') and
(contains(collate(query_text, 'en-ci'), collate(:1, 'en-ci')) or database_name = :1)
(contains(collate(query_text, 'en-ci'), collate(:1, 'en-ci')) or collate(database_name, 'en-ci') = :1)
order by end_time;
"""
INFO_SCHEMA_END_TIME_UP_TO_CURRENT_TIMESTAMP = 'end_time_range_end=>to_timestamp_ltz(current_timestamp())'
Expand All @@ -43,7 +43,7 @@ class SnowflakeQueryHistory(QueryHistory):
('SHOW', 'COPY', 'COMMIT', 'DESCRIBE', 'ROLLBACK', 'CREATE_STREAM', 'DROP_STREAM', 'PUT_FILES',
'BEGIN_TRANSACTION', 'GRANT', 'ALTER_SESSION', 'USE') and
(query_text not ilike '%.query_history%') and
(contains(collate(query_text, 'en-ci'), collate(:1, 'en-ci')) or database_name = :1)
(contains(collate(query_text, 'en-ci'), collate(:1, 'en-ci')) or collate(database_name, 'en-ci') = :1)
order by end_time;
"""
ACCOUNT_USAGE_END_TIME_UP_TO_CURRENT_TIMESTAMP = 'end_time <= current_timestamp()'
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
setup(
name='elementary-lineage',
description='Presenting data lineage based on your data warehouse query history',
version='0.0.16',
version='0.0.17',
packages=find_packages(),
python_requires='>=3.6.2',
entry_points='''
Expand Down

0 comments on commit 6e34e3c

Please sign in to comment.