Skip to content

Commit

Permalink
Utilise SQLAlchemy text function
Browse files Browse the repository at this point in the history
  • Loading branch information
lars-fillmore committed May 9, 2024
1 parent 5abb31e commit 37d7488
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cubedash/summary/_extents.py
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,7 @@ def _dataset_creation_expression(md: MetadataType) -> ClauseElement:
doc = md.dataset_fields["metadata_doc"].alchemy_expression
creation_dt = md.definition["dataset"].get("creation_dt") or ["creation_dt"]
creation_expression = text(
str(doc[creation_dt]) + "::timestamp at time zone 'utc'"
str(doc[creation_dt].astext) + "::timestamp at time zone 'utc'"
)

# If they're missing a dataset-creation time, fall back to the time it was indexed.
Expand Down

0 comments on commit 37d7488

Please sign in to comment.