Hi,
In a database I have a date which looks like this: 0000-08-01 01:21:00
The style of the date is NOT changeable due to it fits another website which I am writing an export function for.
The error which occurs is this:
Microsoft OLE DB Provider for ODBC Drivers error '80040e21' Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.
The line in which the error occurs if the very first line shown below:
If Not IsNull(ColumnRecord.Fields(x).Value) Then FieldsNameValue = CStr(Right("0000" & Year(ColumnRecord.Fields(x).Value), 4) & "-" & _ Right("00" & Month(ColumnRecord.Fields(x).Value),2) & "-" & _ Right("00" & Day(ColumnRecord.Fields(x).Value),2) & " " & _ Right("00" & Hour(ColumnRecord.Fields(x).Value),2) & ":" & _ Right("00" & Minute(ColumnRecord.Fields(x).Value),2) & ":" & _ Right("00" & Second(ColumnRecord.Fields(x).Value),2)) ElseIf Not IsNull(ColumnRecord.Fields(x).Value) And CStr(ColumnRecord.Fields(x).Value) = "" Then FieldsNameValue = "0000-00-00 00:00:00" Else FieldsNameValue = "NULL" End If
Anyone who has an idea to get around this problem ?