I'm getting the following erro when trying to use a report parameter as datatype datetime.
'An error occurred while processing the table 'ChangeRequestTable' Table':
Arithmetic overflow error converting expression to data type smalldatetime.
If I display the value of the ReportParamter I get a value like
13/03/2011 13:05:48
If I try to use a value in this format in my SqlDataSource I get the same Arithmetic Overflow error.
The SqlDataSource works fine if the value is in the following format:
2011-03-13 00:00:00
Can you tell me how I can get the ReportParamter to return the date in a format that the SqlDatasource will accept?
I've tried numerous things...
I've tried wrapping the paramter in the SQLDatasource query...i.e.
CONVERT(VARCHAR(19),@StartDate,120)
I've tried converting the paramtyer expression...
=CDATE(Paramters.ReportPeriodStartDate.Value).ToShortDateString
I've tried changing the databasedata type from smalldatetime to datetime...
I'm out of ideas...
I've opened a support ticket but no response yet :-(
I'm sure this shouldn't be a difficult thing.
Its always the small unexpected things that puts a spanner in the works :-(
Many Thanks in advance, Des
'An error occurred while processing the table 'ChangeRequestTable' Table':
Arithmetic overflow error converting expression to data type smalldatetime.
If I display the value of the ReportParamter I get a value like
13/03/2011 13:05:48
If I try to use a value in this format in my SqlDataSource I get the same Arithmetic Overflow error.
The SqlDataSource works fine if the value is in the following format:
2011-03-13 00:00:00
Can you tell me how I can get the ReportParamter to return the date in a format that the SqlDatasource will accept?
I've tried numerous things...
I've tried wrapping the paramter in the SQLDatasource query...i.e.
CONVERT(VARCHAR(19),@StartDate,120)
I've tried converting the paramtyer expression...
=CDATE(Paramters.ReportPeriodStartDate.Value).ToShortDateString
I've tried changing the databasedata type from smalldatetime to datetime...
I'm out of ideas...
I've opened a support ticket but no response yet :-(
I'm sure this shouldn't be a difficult thing.
Its always the small unexpected things that puts a spanner in the works :-(
Many Thanks in advance, Des