
07-24-2015, 05:55 PM
|
Newcomer
|
|
Join Date: Jul 2015
Posts: 6
|
|
default value for a timestamp field
Hi there,
is there no way to have a timestampColumn within an Insert statement?
I could keep it out of course but sometimes, its needed.
This are 2 examples I've tried, but have still an error
Code:
Dim strTimestamp As String = String.Empty
mySQLCommand.Parameters.AddWithValue("@TimestampClm", SqlDbType.Timestamp)
mySQLCommand.Parameters("@TimestampClm").Value = strTimestamp
And even this one hasnt work
Code:
Dim myNull As SqlDateTime
myNull = SqlDateTime.Null
mySQLCommand.Parameters.AddWithValue("@TimestampClm", SqlDbType.Timestamp)
mySQLCommand.Parameters("@TimestampClm").Value = myNull
greetings and thanks
|
|