great-expectations / great_expectations

Always know what to expect from your data.
https://docs.greatexpectations.io/
Apache License 2.0
9.83k stars 1.52k forks source link

% string duplication prevents using PARSE_DATE() SQL function #10397

Open strunov opened 3 days ago

strunov commented 3 days ago

Describe the bug

If I use a SQL data asset or a SQL unexpected rows expectation using % format then the query gets changed - the % gets duplicated.

Escaping the query with \% produces \%% query string.

To Reproduce Please include your great_expectations.yml config, the code you’re executing that causes the issue, and the full stack trace of any error(s).

Expected behavior Raw queries should be treated as is IMO

Environment (please complete the following information):

Additional context Add any other context about the problem here.

adeola-ak commented 3 days ago

hi @strunov, thanks for bringing this to our attention. I've shared it with the team and will follow up soon!

cdkini commented 1 day ago

@strunov could you please provide an example of a query that happens to cause this issue? Additionally, where is it that you're actually seeing the mangled query? In the result?