Skip to content

Add sqllogictest coverage for UDWF return types in information_schema #20090

@AndreaBozzo

Description

@AndreaBozzo

Context

In #20079, the information_schema was updated to use return_field_from_args / return_field / WindowUDFFieldArgs::field instead of the older return_type API for UDFs, UDAFs, and UDWFs.

As noted in this review comment, it would be good to add sqllogictest coverage to verify that information_schema.routines correctly reports return types for window UDFs (the get_udwf_args_and_return_types path).

What needs to be done

Add a sqllogictest (in test_files/information_schema.slt or a new file) that:

  1. Registers a window UDF (or uses a built-in one)
  2. Queries information_schema.routines filtering for that window function
  3. Asserts the return type column is populated correctly (previously it was always NULL)

The relevant code is in datafusion/catalog/src/information_schema.rs around the get_udwf_args_and_return_types function.

Willingness to submit a PR

Yes, but as this can potentially be a good newcomer task i'm up to leave for someone else

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions