|
database
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
time stamp magicaly updated when ever update event occures on a rowtime stamp magicaly updated when ever update event occures on a row
in sql server 2000 i have a table. when i do any update on the table, a field of the effected rows gets a new time stamp, there are no triggers on the table, nothing special in the DDL of the table, is there any other way besides a table specific trigger that this time stamp could be getting updated when i do an update on a row? perhaps some other kind of trigger that is not specific to a table but specific to a fielde name in any table? From SQL Server 2005 BOL:
timestamp: "Is a data type that exposes automatically generated, unique binary numbers within a database. timestamp is generally used as a mechanism for version-stamping table rows. The storage size is 8 bytes." further: "The Transact-SQL timestamp data type is different from the timestamp data type defined in the SQL-2003 standard. The SQL-2003 timestamp data type is equivalent to the Transact-SQL datetime data type." As you see, if a DML is executed against the row, the value is automatically updated. Regards -------------------------------- Mike Epprecht, Microsoft SQL Server MVP Zurich, Switzerland IM: m***@epprecht.net MVP Program: http://www.microsoft.com/mvp Blog: http://www.msmvps.com/epprecht/ Show quote "Daniel" <softwareengineer98***@yahoo.com> wrote in message news:eTp2%23yE$FHA.228@TK2MSFTNGP12.phx.gbl... > time stamp magicaly updated when ever update event occures on a row > > in sql server 2000 i have a table. when i do any update on the table, a > field of the effected rows gets a new time stamp, there are no triggers > on > the table, nothing special in the DDL of the table, is there any other way > besides a table specific trigger that this time stamp could be getting > updated when i do an update on a row? perhaps some other kind of trigger > that is not specific to a table but specific to a fielde name in any > table? > > But is it now standard practice for ASP.NET data controls and the ASP.NET
2.0 Website Administration Tool to record all data entry using GMT(-0:00) offestting the actual system time where the event occurs by 6 hours into the future when that actual system time is GMT(-06:00)? <%= Clinton Gallagher METROmilwaukee (sm) "A Regional Information Service" NET csgallagher AT metromilwaukee.com URL http://metromilwaukee.com/ URL http://clintongallagher.metromilwaukee.com/ Show quote "Mike Epprecht (SQL MVP)" <m***@epprecht.net> wrote in message news:uqSaO3E$FHA.2036@TK2MSFTNGP14.phx.gbl... > From SQL Server 2005 BOL: > > timestamp: "Is a data type that exposes automatically generated, unique > binary numbers within a database. timestamp is generally used as a > mechanism for version-stamping table rows. The storage size is 8 bytes." > > further: "The Transact-SQL timestamp data type is different from the > timestamp data type defined in the SQL-2003 standard. The SQL-2003 > timestamp data type is equivalent to the Transact-SQL datetime data type." > > As you see, if a DML is executed against the row, the value is > automatically updated. > > Regards > -------------------------------- > Mike Epprecht, Microsoft SQL Server MVP > Zurich, Switzerland > > IM: m***@epprecht.net > > MVP Program: http://www.microsoft.com/mvp > > Blog: http://www.msmvps.com/epprecht/ > > "Daniel" <softwareengineer98***@yahoo.com> wrote in message > news:eTp2%23yE$FHA.228@TK2MSFTNGP12.phx.gbl... >> time stamp magicaly updated when ever update event occures on a row >> >> in sql server 2000 i have a table. when i do any update on the table, a >> field of the effected rows gets a new time stamp, there are no triggers >> on >> the table, nothing special in the DDL of the table, is there any other >> way >> besides a table specific trigger that this time stamp could be getting >> updated when i do an update on a row? perhaps some other kind of trigger >> that is not specific to a table but specific to a fielde name in any >> table? >> >> > > Hi
Makes no difference timestamp <> datetime data types. They are 2 very different data types. One you get a date and time out of, the other is a binary semi-sequential number. Regards -------------------------------- Mike Epprecht, Microsoft SQL Server MVP Zurich, Switzerland IM: m***@epprecht.net MVP Program: http://www.microsoft.com/mvp Blog: http://www.msmvps.com/epprecht/ Show quote "clintonG" <csgallag***@REMOVETHISTEXTmetromilwaukee.com> wrote in message news:ea7qWTF$FHA.1256@TK2MSFTNGP15.phx.gbl... > But is it now standard practice for ASP.NET data controls and the ASP.NET > 2.0 Website Administration Tool to record all data entry using GMT(-0:00) > offestting the actual system time where the event occurs by 6 hours into > the future when that actual system time is GMT(-06:00)? > > > <%= Clinton Gallagher > METROmilwaukee (sm) "A Regional Information Service" > NET csgallagher AT metromilwaukee.com > URL http://metromilwaukee.com/ > URL http://clintongallagher.metromilwaukee.com/ > > > "Mike Epprecht (SQL MVP)" <m***@epprecht.net> wrote in message > news:uqSaO3E$FHA.2036@TK2MSFTNGP14.phx.gbl... >> From SQL Server 2005 BOL: >> >> timestamp: "Is a data type that exposes automatically generated, unique >> binary numbers within a database. timestamp is generally used as a >> mechanism for version-stamping table rows. The storage size is 8 bytes." >> >> further: "The Transact-SQL timestamp data type is different from the >> timestamp data type defined in the SQL-2003 standard. The SQL-2003 >> timestamp data type is equivalent to the Transact-SQL datetime data >> type." >> >> As you see, if a DML is executed against the row, the value is >> automatically updated. >> >> Regards >> -------------------------------- >> Mike Epprecht, Microsoft SQL Server MVP >> Zurich, Switzerland >> >> IM: m***@epprecht.net >> >> MVP Program: http://www.microsoft.com/mvp >> >> Blog: http://www.msmvps.com/epprecht/ >> >> "Daniel" <softwareengineer98***@yahoo.com> wrote in message >> news:eTp2%23yE$FHA.228@TK2MSFTNGP12.phx.gbl... >>> time stamp magicaly updated when ever update event occures on a row >>> >>> in sql server 2000 i have a table. when i do any update on the table, a >>> field of the effected rows gets a new time stamp, there are no triggers >>> on >>> the table, nothing special in the DDL of the table, is there any other >>> way >>> besides a table specific trigger that this time stamp could be getting >>> updated when i do an update on a row? perhaps some other kind of trigger >>> that is not specific to a table but specific to a fielde name in any >>> table? >>> >>> >> >> > > I'm referring to a datetime data type.
Maybe its me and I never learned that by convention ASP.NET will record a datetime value using a GMT offset. I always thought system time was supposed to be used by convention when creating a new record. That's all I'm really trying to determine right now. <%= Clinton Gallagher Show quote "Mike Epprecht (SQL MVP)" <m***@epprecht.net> wrote in message news:u9vGPbF$FHA.3800@TK2MSFTNGP10.phx.gbl... > Hi > > Makes no difference timestamp <> datetime data types. They are 2 very > different data types. One you get a date and time out of, the other is a > binary semi-sequential number. > > Regards > -------------------------------- > Mike Epprecht, Microsoft SQL Server MVP > Zurich, Switzerland > > IM: m***@epprecht.net > > MVP Program: http://www.microsoft.com/mvp > > Blog: http://www.msmvps.com/epprecht/ > > "clintonG" <csgallag***@REMOVETHISTEXTmetromilwaukee.com> wrote in message > news:ea7qWTF$FHA.1256@TK2MSFTNGP15.phx.gbl... >> But is it now standard practice for ASP.NET data controls and the ASP.NET >> 2.0 Website Administration Tool to record all data entry using GMT(-0:00) >> offestting the actual system time where the event occurs by 6 hours into >> the future when that actual system time is GMT(-06:00)? >> >> >> <%= Clinton Gallagher >> METROmilwaukee (sm) "A Regional Information Service" >> NET csgallagher AT metromilwaukee.com >> URL http://metromilwaukee.com/ >> URL http://clintongallagher.metromilwaukee.com/ >> >> >> "Mike Epprecht (SQL MVP)" <m***@epprecht.net> wrote in message >> news:uqSaO3E$FHA.2036@TK2MSFTNGP14.phx.gbl... >>> From SQL Server 2005 BOL: >>> >>> timestamp: "Is a data type that exposes automatically generated, unique >>> binary numbers within a database. timestamp is generally used as a >>> mechanism for version-stamping table rows. The storage size is 8 bytes." >>> >>> further: "The Transact-SQL timestamp data type is different from the >>> timestamp data type defined in the SQL-2003 standard. The SQL-2003 >>> timestamp data type is equivalent to the Transact-SQL datetime data >>> type." >>> >>> As you see, if a DML is executed against the row, the value is >>> automatically updated. >>> >>> Regards >>> -------------------------------- >>> Mike Epprecht, Microsoft SQL Server MVP >>> Zurich, Switzerland >>> >>> IM: m***@epprecht.net >>> >>> MVP Program: http://www.microsoft.com/mvp >>> >>> Blog: http://www.msmvps.com/epprecht/ >>> >>> "Daniel" <softwareengineer98***@yahoo.com> wrote in message >>> news:eTp2%23yE$FHA.228@TK2MSFTNGP12.phx.gbl... >>>> time stamp magicaly updated when ever update event occures on a row >>>> >>>> in sql server 2000 i have a table. when i do any update on the table, a >>>> field of the effected rows gets a new time stamp, there are no >>>> triggers on >>>> the table, nothing special in the DDL of the table, is there any other >>>> way >>>> besides a table specific trigger that this time stamp could be getting >>>> updated when i do an update on a row? perhaps some other kind of >>>> trigger >>>> that is not specific to a table but specific to a fielde name in any >>>> table? >>>> >>>> >>> >>> >> >> > > |
|||||||||||||||||||||||