Click here to Skip to main content
15,905,682 members
Home / Discussions / Database
   

Database

 
GeneralReducing the size of the database files Pin
Colin Angus Mackay4-Apr-04 23:26
Colin Angus Mackay4-Apr-04 23:26 
GeneralRe: Reducing the size of the database files Pin
Mike Dimmick5-Apr-04 1:02
Mike Dimmick5-Apr-04 1:02 
GeneralRe: Reducing the size of the database files Pin
Colin Angus Mackay5-Apr-04 23:28
Colin Angus Mackay5-Apr-04 23:28 
GeneralConnecting Oracle 10 g Pin
mhmoud rawas4-Apr-04 23:14
mhmoud rawas4-Apr-04 23:14 
GeneralJOIN datatables Pin
vbtoosharp4-Apr-04 15:53
vbtoosharp4-Apr-04 15:53 
GeneralRe: JOIN datatables Pin
Mazdak5-Apr-04 0:01
Mazdak5-Apr-04 0:01 
GeneralAuto Updating Column Pin
monrobot134-Apr-04 14:19
monrobot134-Apr-04 14:19 
GeneralRe: Auto Updating Column Pin
Mike Dimmick5-Apr-04 1:11
Mike Dimmick5-Apr-04 1:11 
It doesn't update to the current date and time, but SQL Server 2000 does have the rowversion type which is automatically updating. IIRC, the value for a changed row is only guaranteed to be different from the old value, not necessarily greater than the old value.

If you want date/time behaviour, you might want to consider using a trigger:
CREATE TRIGGER tg_timestamp ON MyTable
FOR INSERT, UPDATE
AS
UPDATE MyTable
SET TimeStampField = GETUTCDATE()
WHERE PrimaryKey IN
  ( SELECT PrimaryKey FROM inserted )
inserted is a pseudo-table (constructed from the transaction log) containing the new data for all the rows that were inserted or modified (there's also a deleted pseudo-table for the old version of modified rows, for an UPDATE trigger). You'll want to ensure that recursive triggers are not enabled, or you'll just end up going recursive.

I suggest using the UTC date and time so you don't get Daylight Savings Time effects.

Stability. What an interesting concept. -- Chris Maunder
GeneralRe: Auto Updating Column Pin
monrobot135-Apr-04 4:01
monrobot135-Apr-04 4:01 
QuestionSQLCommand ??? Pin
sybux20004-Apr-04 5:51
sybux20004-Apr-04 5:51 
AnswerRe: SQLCommand ??? Pin
AlexDBA4-Apr-04 19:43
AlexDBA4-Apr-04 19:43 
AnswerRe: SQLCommand ??? Pin
Mike Dimmick5-Apr-04 1:42
Mike Dimmick5-Apr-04 1:42 
GeneralRe: SQLCommand ??? Pin
sybux20005-Apr-04 8:24
sybux20005-Apr-04 8:24 
GeneralAutomation Sever cannot create object Pin
Gary Hyslop at home4-Apr-04 4:56
Gary Hyslop at home4-Apr-04 4:56 
GeneralRe: Automation Sever cannot create object Pin
Gary Hyslop9-Apr-04 3:04
Gary Hyslop9-Apr-04 3:04 
QuestionHow can I deploy sql server database? Pin
Mahmoud Hossam3-Apr-04 23:50
Mahmoud Hossam3-Apr-04 23:50 
AnswerRe: How can I deploy sql server database? Pin
Michael P Butler4-Apr-04 0:05
Michael P Butler4-Apr-04 0:05 
AnswerRe: How can I deploy sql server database? Pin
Steven Campbell13-Apr-04 9:28
Steven Campbell13-Apr-04 9:28 
GeneralSELECT * Problem Pin
monrobot133-Apr-04 12:58
monrobot133-Apr-04 12:58 
GeneralRe: SELECT * Problem Pin
Colin Angus Mackay3-Apr-04 14:10
Colin Angus Mackay3-Apr-04 14:10 
GeneralRe: SELECT * Problem Pin
monrobot134-Apr-04 13:58
monrobot134-Apr-04 13:58 
GeneralSo many problems! Pin
ErinSue203-Apr-04 2:13
ErinSue203-Apr-04 2:13 
GeneralRe: So many problems! Pin
Michael P Butler4-Apr-04 0:24
Michael P Butler4-Apr-04 0:24 
Generalado, ms sql server 'text' columns Pin
sstoyan2-Apr-04 10:18
sstoyan2-Apr-04 10:18 
GeneralRe: ado, ms sql server 'text' columns Pin
Mike Dimmick2-Apr-04 11:42
Mike Dimmick2-Apr-04 11:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.