Error: DB2 SQL Error: SQLCODE=-458, SQLSTATE=42883, SQLERRMC=TBSPACEID=, TABLEID=, COLNO=, DRIVER=
IN A REFERENCE TO FUNCTION
function-name BY SIGNATURE, A
MATCHING FUNCTION COULD NOT
BE FOUND
Explanation: In a reference to function function-name
by signature, no matching function could be found. The
problem could be with the data type or some other
attributes of a parameter. For some data types there are
attributes in addition to data type:
v Length, precision, or scale
While it is not necessary to specify a length,
precision, or scale attribute for a data type, if one is
specified then there must be an exact match on the
corresponding specification of the parameter for the
existing function as defined in SYSPARMS.
A type of FLOAT(n) does not need to match the
defined value for n since 1<=n<=21 means REAL
and 22<=n<=53 means DOUBLE. Matching occurs
based on whether the type is REAL or DOUBLE.
However, a match on data type is sufficient.
To indicate this, an empty set of parentheses must be
specified for the data types that allow a specification
of length, precision, or scale. For example, assuming
a function exists for which a parameter was defined
as CHAR(12) on the CREATE FUNCTION statement,
a reference to that function by a signature could
specify this parameter as either CHAR(12), or
CHAR(). The CHAR() syntax provides a way to say
“don’t care about length, precision and scale
attributes in finding a matching function”.
FLOAT() cannot be used since the parameter value
indicates different data types (REAL or DOUBLE).
If, however, neither length, precision, scale, or empty
parenthesis were specified, then normal default rules
apply. For example, a specification of CHAR would
result in CHAR(1) as on the CREATE TABLE
statement. Furthermore, this implicit specification of
length, precision, or scale must exactly match the
corresponding specification of the parameter for the
existing function as defined in SYSPARMS.
v Subtype, or encoding scheme
You do not need to specify the subtype or encoding
scheme (CCSID clause) to identify an existing
function in the database. However, if a subtype or
encoding scheme is specified then there must be an
exact match on the corresponding specification of the
parameter for the existing function as defined in
SYSPARMS.
Unqualified function names:
v For ALTER FUNCTION, DROP FUNCTION,
COMMENT ON FUNCTION, GRANT and REVOKE
statements for EXECUTE on functions, an
unqualified function name is implicitly qualified
with the default schema, and this is the schema
where the function with the problem can be found.
See SQL Reference for more information on default
schema.
v In the SOURCE clause of a CREATE FUNCTION
statement, the qualification comes from the SQL
path. In this case, the is no matching function in the
entire path.
Attention:A function cannot be sourced on the
COALESCE, NULLIF, RAISE_ERROR, RID, or
VALUE built-in functions. Additionally, there are
restrictions on the way that you can source on the
COUNT, COUNT_BIG, CHAR, and STRIP built-in
functions because of some of the keywords that they
accept.
System action: The statement cannot be executed.
Programmer response: Possible responses include:
v Changing the SQL path to include the correct
schema.
v Changing the attributes of the parameters.
v Using a SPECIFIC name to refer to the function
instead of a signature.
SQLSTATE: 42883

Error: DB2 SQL Error: SQLCODE=-461, SQLSTATE=42846, SQLERRMC=TBSPACEID=, TABLEID=, COLNO=, DRIVER=
A VALUE WITH DATA TYPE
source-data-type CANNOT BE CAST TO
TYPE target-data-type
Explanation: The statement contains an implicit or
explicit CAST, but the combination of the source and
target data types is not supported. DB2 attempted to
cast a value of source-data-type to the data type
target-data-type. This combination is not supported.
Change the data type of either the source or target so
that the cast is supported. For predefined (built-in) data
types or a cast involving a user-defined distinct type,
see theSQL Reference.
System action: The statement could not be processed.
Programmer response: If an explicit CAST was
specified, correct the CAST specification to specify a
supported combination of source and target types.
SQLSTATE: 42846

Error: DB2 SQL Error: SQLCODE=-469, SQLSTATE=42886, SQLERRMC=TBSPACEID=, TABLEID=, COLNO=, DRIVER=
SQL CALL STATEMENT MUST
SPECIFY AN OUTPUT HOST
VARIABLE FOR PARAMETER number
Explanation: DB2 received an SQL CALL statement
for a stored procedure. DB2 found the row in the
SYSIBM.SYSROUTINES catalog table associated with
the requested procedure name. However, parameter
number was identified in the SYSIBM.SYSPARMS table
as an OUT or INOUT parameter. A host variable must
be supplied on the SQL CALL statement for parameters
defined as OUT or INOUT.
number
The parameter number from the ORDINAL
field in SYSIBM.SYSPARMS.
System action: The statement cannot be executed.
Programmer response: If the SQL CALL statement is
coded incorrectly, modify the SQL application to
provide an output host variable on the SQL CALL
statement.
If the SYSIBM.SYSPARMS table contains incorrect
information, the DROP PROCEDURE and CREATE
PROCEDURE statements must be used to replace the
catalog definition for the stored procedure.
SQLSTATE: 42886

Above are list of DB2 SQL Errors and Warnings from Error -458 to -469 received while performing certain operation against DB2 Database or related products.

SQLCODE – Regardless of whether the application program provides an SQLCA or a stand-alone variable, SQLCODE is set by DB2 after each SQL statement is
executed. DB2 conforms to the ISO/ANSI SQL standard as follows:
If SQLCODE = 0, execution was successful.
If SQLCODE &gt; 0, execution was successful with a warning.
If SQLCODE &lt; 0, execution was not successful.
SQLCODE = 100, “no data” was found. For example, a FETCH statement returned no data because the cursor was positioned after the last row of the result table.

SQLSTATE – SQLSTATE is also set by DB2 after the execution of each SQL statement. Thus, application programs can check the execution of SQL statements by testing SQLSTATE instead of SQLCODE.

With codeplex shutting down, we have moved SQL Nexus to github with a new release (6.0). Now both Pssdiag/SQLDiag manager and SQL Nexus are on github. Where to get it As you navigate to SQL Nexus, you can download code and released binary files. If you choose to download binary files, you can go to...

SQL Server : large RAM and DB Checkpointing Hi everyone, This post’s purpose is to establish a summary of the specific behaviors with relation to DB Checkpoint that may happen within SQL Server when running with a large quantity of allocated memory and when applicable, how to best address them. SQL Server 2016 improves...

Recently we got an inquiry from a customer who received the following message in errorlog and wanted to know why. [INFO] HkDatabaseTryAcquireUserMemory(): Database ID: [7]. Out of user memory quota: requested = 131200; available = 74641; quota = 34359738368; operation = 1. This is my first time to see this error. As usual, I relied...

Recently I assisted on a customer issue where customer wasn’t able to alter a memory optimized table with the following error Msg 41317, Level 16, State 3, Procedure ddl, Line 4 [Batch Start Line 35]A user transaction that accesses memory optimized tables or natively compiled modules cannot access more than one user database or databases...

In a previous blog, I talked about memory optimized table consumes memory until end of the batch. In this blog, I want to make you aware of cardinality estimate of memory optimized table as we have had customers who called in for clarifications. By default memory optimized table variable behaves the same way as...

I worked on an interesting issue today where a user couldn’t restore a backup. Here is what this customer did: backed up a database from an on-premises server (2008 R2) copied the file to an Azure VM tried to restore the backup on the Azure VM (2008 R2 with exact same build#) But he got...

Recently, I looked an In-Memory OLTP issue with Principal Software Engineer Bob Dorr who is still my office neighbor. After restoring a database that had just one memory optimized table, we dropped the table. Even without any memory optimized tables,number of checkpoint files keep going up every time we issue a checkpoint. For a while,...

In this blog Added per-operator level performance stats for Query Processing, Senior PM in QP talks about extending operator level performance stats. They include stats related to reads, CPU and elapse time. These are very helpful to track down query performance issues. We worked on recent case where we put ActualElapsedms in a good...

In blog “Importance of choosing correct bucket count of hash indexes on a memory optimized table”, I talked about encountering performance issues with incorrect sized bucket count. I was actually investigating an out of memory issues with the following error. Msg 701, Level 17, State 103, Line 11There is insufficient system memory in resource pool...

I was working with a customer to troubleshoot memory optimized table issues. In this scenario, our customer uses a memory optimized table variable. He put 1 million rows of data into the table variable and then process it. Based on what he said, I tried to come up with a repro to see if...