Observation: Encountering error - Year, Month, and Day parameters describe an un-representable DateTime. Check InnerException property for more detail. SQLSTATE=58005
Condition: Happens when I execute a Stored-procedure which queries & returns records from a single table based on the parameter provided.
OS: Windows Vista
IDE: Miscrosoft Visual Studio 2005 (C# Windows Application)
Other Information: Kindly have other tables also with these kinds of field layout and I don't find this happening. On checking I came across this link http://support.microsoft.com/kb/926357/en-us?sd=rss&spid=1967. However, it cannot be installed on my system.
Would it be possible for someone to please help me with this.
Table Structure Pattern
CREATE TABLE TRANSACTION_MASTER
RECORD_ID INTEGER NOT NULL,
DATE_OF_CREATION TIMESTAMP NOT NULL,
LAST_UPDATED_BY VARCHAR(200) NOT NULL,
LAST_UPDATED_FROM VARCHAR(200) NOT NULL,
INVOICE_AMOUNT DECIMAL(30 , 2)
DATA CAPTURE NONE
Stored Procedure Pattern
CREATE PROCEDURE USER.GET_TRANSACTION_MASTERS
INOUT VAL_UNIQUE_RECORD_ID INTEGER,
INOUT VAL_DATE_OF_CREATION TIMESTAMP,
INOUT VAL_DATE_OF_MODIFICATION TIMESTAMP,
INOUT VAL_DATE_OF_DELETION TIMESTAMP,
INOUT VAL_LAST_UPDATED_BY VARCHAR(200),
INOUT VAL_LAST_UPDATED_FROM VARCHAR(200),
INOUT VAL_IS_ACTIVE INTEGER,
INOUT VAL_INVOICE_DATE DATE,
INOUT VAL_INVOICE_NO VARCHAR(50),
INOUT VAL_INVOICE_AMOUNT DECIMAL(30 , 2)
RESULT SETS 1
DECLARE CR_TRANSACTIONMASTERS CURSOR WITH RETURN FOR
INVOICE_NO = VAL_INVOICE_NO
VAL_INVOICE_NO LIKE VAL_INVOICE_NO
VAL_INVOICE_NO IS NOT NULL
VAL_INVOICE_NO IS NULL
(DATE(INVOICE_DATE) = DATE(VAL_INVOICE_DATE) AND VAL_INVOICE_DATE IS NOT NULL)
VAL_INVOICE_DATE IS NULL
INVOICE_AMOUNT = VAL_INVOICE_AMOUNT
VAL_INVOICE_AMOUNT IS NOT NULL
VAL_INVOICE_AMOUNT IS NULL
NOTICE: developerWorks Community will be offline May 29-30, 2015 while we upgrade to the latest version of IBM Connections. For more information, read our upgrade FAQ.
This topic has been locked.
1 reply Latest Post - 2013-01-19T20:29:37Z by SystemAdmin
Pinned topic IBM DB2 Express-C Exception SQLSTATE=58005 Year, Month, and Day parameters
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2013-01-19T20:29:37Z at 2013-01-19T20:29:37Z by SystemAdmin
SystemAdmin 110000D4XK2826 PostsACCEPTED ANSWER
Re: IBM DB2 Express-C Exception SQLSTATE=58005 Year, Month, and Day parameters2013-01-19T20:29:37Z in response to SystemAdminContent moved to.
Sorry, it was a mistake from my side. I ended up posting the same thing 4 times. I am sorry about the same. Since there is no delete/edit option posting this here.