schemainspect
schemainspect copied to clipboard
include defaults in create function signature
I noticed when altering the default value of a function parameter that migra didn't pick up that there had been a change.
This was due to only using pg_get_function_identity_arguments()
for the signature, which does not include defaults.
This change adds an extra column to the functions.sql
query to get pg_get_function_arguments(p.oid) as function_arguments
which is then used as the signature for the create function statement. We still use the identity arguments for dropping the function.