May 12, 2006 #1 baden100 Programmer Apr 26, 2006 10 US When I've got a DateTime field defined in a SQL Server table, how do I get the value to get auto populated if none is given in a query. ie. If I manually add a record to the table, I want the datetime field to autopopulate. Thanks
When I've got a DateTime field defined in a SQL Server table, how do I get the value to get auto populated if none is given in a query. ie. If I manually add a record to the table, I want the datetime field to autopopulate. Thanks
May 12, 2006 #2 DotNetGnat Programmer Mar 10, 2005 5,548 IN use GetDate() function to insert the current date... -DNG Upvote 0 Downvote
May 12, 2006 #3 jbenson001 Programmer Jan 7, 2004 8,172 US You can set a default on the date column to getdate() Jim Upvote 0 Downvote
May 12, 2006 Thread starter #4 baden100 Programmer Apr 26, 2006 10 US Great. Thanks guys! Upvote 0 Downvote