How to Determine records updated/changed

G

Guest

I have a MS SQL2000 database from which I pull records for unattended kiosk
display. How can I test the active records to determine if they've changed or
have been added since the last time a dataset was created? I started building
a hash table to store the record id and last edit timestamp, but that seems
too much. I'm not a SQL server guy.

TIA,

E.
 
C

Cor Ligthert

Esteban,

Do you want to know:
- if there are changes in the datasest which is easy (ds.HasChanges)
- or where the there are records in the database where is the timestamp
newer than the datetime you created your dataset the last time.

The problem with the last is that you (normally) cannot find removed rows in
a database, so you have to reload your last dataset anyhow in one or the
other way to compare that or just take the new one after you have updated it
(and did all concurrency checking etc).

Cor
 
G

Guest

Hi Cor,

ds.HasChanges won't work. The records are not being edited. They are being
read only as a display source in a kiosk (no user interaction).

I thought there might have been some attribute flag or SQL voodoo way to get
the server to do it for me. I'll work up a dataset load to do it.

Thanks for the suggestions, Cor. I'm set until the next bump in the road.

E.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top