OHDSI / WhiteRabbit

WhiteRabbit is a small application that can be used to analyse the structure and contents of a database as preparation for designing an ETL. It comes with RabbitInAHat, an application for interactive design of an ETL to the OMOP Common Data Model with the help of the the scan report generated by White Rabbit.
http://ohdsi.github.io/WhiteRabbit
Apache License 2.0
173 stars 85 forks source link

SnowflakeHandler in v1.0.0-RC1 ignores database and schema in some cases #409

Open janblom opened 3 months ago

janblom commented 3 months ago

Describe the bug When running WhiteRabbit against a Snowflake instance with multiple databases and/or schema's, tables are not always properly identified by the correct database & schema, leading to crashes and/or errors reporting non-existent tables or columns.

To Reproduce Steps to reproduce the behavior: This requires a Snowflake instance with multiple database and/or schema's and duplicate column names across tables to reproduce. Bug fixes will need to be field-tested with instances that have these features.

Expected behavior Snowflake tables and columns should always be identified by the correct database and schema.

Desktop (please complete the following information):

Additional context Add any other context about the problem here.

janblom commented 2 months ago

An additional fix was applied to prevent an exception that was reported by a tester ("java.lang.ClassCastException: class org.ohdsi.rabbitInAHat.dataModel.Table cannot be cast to class java.lang.Comparable (org.ohdsi.rabbitInAHat.dataModel.Table is in unnamed module of loader 'app'; java.lang.Comparable is in module java.base of loader 'bootstrap')