Subject: how to auto generate date?
Posted By: okboy Post Date: 12/12/2006 1:44:30 PM
i create table call content(Contentinfo, Contenttitle, createdatetime.datetime)

Then in asp.net i am using detailsview to insert the data. So how in the same time i entry the contentinfo and contenttitle, the createdatetime column can auto generate the date and time save to my database?

Reply By: rstelma Reply Date: 12/12/2006 2:49:57 PM
1. Create a new table in Enterprise Manager and create the datetime column. Make sure you don't allow NULLS on this column.

2. In the lower area where it says "Default Value", put in getDate().

Every time you insert into this table it will make a time stamp in that column if that's what you want.





Reply By: okboy Reply Date: 12/12/2006 6:14:12 PM
Thank you very much...it work




Reply By: rstelma Reply Date: 12/12/2006 7:17:14 PM
OK boy... go get em. Glad it worked for you.


Go to topic 53545

Return to index page 95
Return to index page 94
Return to index page 93
Return to index page 92
Return to index page 91
Return to index page 90
Return to index page 89
Return to index page 88
Return to index page 87
Return to index page 86