D
Dave Reardon
I have a table with a field for dates, which contains four rows. I am
attempting to use the first date to populate a field in a different table,
using an update query written in SQL. The syntax is:
rs.ActiveConnection = DR
rs.Open "AttDatesT"
With rs
rs.MoveFirst
datDate = .Fields("DateId")
MsgBox strDate
strSQL1 = "UPDATE [Students-T] SET [Students-T].Date1 = "
DoCmd.RunSQL strSQL1 & datDate
End With
rs.Close
The message box displays the date correctly, eg 10/02/2010 but when I go to
the field to look at the data in the table it typically displays something
like 00:03:35 I assume it is to do with a date conversion, but I don't seem
to find any reference to this anywhere. Any help very welcome.
attempting to use the first date to populate a field in a different table,
using an update query written in SQL. The syntax is:
rs.ActiveConnection = DR
rs.Open "AttDatesT"
With rs
rs.MoveFirst
datDate = .Fields("DateId")
MsgBox strDate
strSQL1 = "UPDATE [Students-T] SET [Students-T].Date1 = "
DoCmd.RunSQL strSQL1 & datDate
End With
rs.Close
The message box displays the date correctly, eg 10/02/2010 but when I go to
the field to look at the data in the table it typically displays something
like 00:03:35 I assume it is to do with a date conversion, but I don't seem
to find any reference to this anywhere. Any help very welcome.