Skip to content

Add Null Type Coercions for Placeholders#20543

Open
cetra3 wants to merge 1 commit intoapache:mainfrom
pydantic:parameter_type_coercion
Open

Add Null Type Coercions for Placeholders#20543
cetra3 wants to merge 1 commit intoapache:mainfrom
pydantic:parameter_type_coercion

Conversation

@cetra3
Copy link
Contributor

@cetra3 cetra3 commented Feb 25, 2026

Which issue does this PR close?

At least this one: #19471 but might be others

Rationale for this change

This fixes a problem we have where placeholder types are Null, and we need to add explicit type casts in the query.

I.e, you can't use placeholders for date_bin functions:

select date_bin($resolution, timestamp) 

This works though (currently):

select date_bin($resolution::interval, timestamp) 

What changes are included in this PR?

Adds some extra type coercions

Are these changes tested?

Yes, new tests added

Are there any user-facing changes?

Not really?

@github-actions github-actions bot added logical-expr Logical plan and expressions sqllogictest SQL Logic Tests (.slt) labels Feb 25, 2026
@cetra3 cetra3 force-pushed the parameter_type_coercion branch from 50b4a69 to 9d4791f Compare February 26, 2026 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

logical-expr Logical plan and expressions sqllogictest SQL Logic Tests (.slt)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant