PLS-00651: implementation type in Aggregate/Table function should be a valid type Cause: User tried to use some other database object like a package to define implementation type of an aggregate/table function. Action: Use a valid user defined type as implementation type.