Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
sent_sara
Constraint Violating Yak Guru
377 Posts |
Posted - 2006-12-02 : 03:22:00
|
hi fys,iam having the table called attendancetable:attendancecolumn:unit token name att01 att02 atto3 and so on....21322031during runtime in vb6.0 iam accessing the unit 21.if iam accessing the unit 21 other people should not access.so how to do this whether thr vb6.0 or thr sqlserver..Any idea?????sqlserver 2000 |
|
jezemine
Master Smack Fu Yak Hacker
2886 Posts |
Posted - 2006-12-02 : 13:22:05
|
Not exactly sure what you are asking. Do you mean you want to mark a row as "locked" in certain cases, so that others can't select/update/delete it?if so you could have an IsLocked column, or LockedBy if you want to keep track of who has the row open for editing. Probably you need LockedBy so you know who is authorized to edit the row after it's been locked. Then any sproc that selects/updates/deletes rows from this table could check that column and fail the request if it's already locked. of course this assumes that all table access is done through sprocs. if your table is open to ad hoc queries, there's not a lot you can do to prevent access to a single row. SqlSpec: a fast and comprehensive data dictionary generator for SQL Server 2000/2005, Analysis Server 2005, Access 97/2000/XP/2003 http://www.elsasoft.org |
|
|
|
|
|