Skip to content

Commit

Permalink
Merge pull request #379 from jaceksan/gartner
Browse files Browse the repository at this point in the history
TRIVIAL: gooddata-dbt - do not generate attributes for NUMBERs

Reviewed-by: Jan Kadlec
             https://github.com/hkad98
  • Loading branch information
gdgate authored Oct 9, 2023
2 parents d13e956 + 1a50589 commit c404815
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gooddata-dbt/gooddata_dbt/dbt/tables.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,9 @@ def gooddata_is_fact(self) -> bool:

def gooddata_is_attribute(self) -> bool:
valid_ldm_types = [GoodDataLdmTypes.ATTRIBUTE.value, GoodDataLdmTypes.PRIMARY_KEY.value]
# Without GD metadata, attribute is default unless it is DATETIME data type
# Without GD metadata, attribute is default unless it is DATETIME/NUMBER(FLOAT) data type
return self.meta.gooddata.ldm_type in valid_ldm_types or (
self.meta.gooddata.ldm_type is None and not self.is_date()
self.meta.gooddata.ldm_type is None and not self.is_date() and not self.is_number()
)

def gooddata_is_label(self, attribute_column_name: str) -> bool:
Expand Down

0 comments on commit c404815

Please sign in to comment.