relational UDFs can register a functions for returns, which can be used to dynamically generate the schema