Enable only one user to edit a row in SQL server database using C#, asp.net win apps

Please support our ASP.NET advertiser: Intel Parallel Studio Home
Reply

Join Date: May 2007
Posts: 14
Reputation: vamsikgummadi is an unknown quantity at this point 
Solved Threads: 0
vamsikgummadi's Avatar
vamsikgummadi vamsikgummadi is offline Offline
Newbie Poster

Enable only one user to edit a row in SQL server database using C#, asp.net win apps

 
0
  #1
Aug 7th, 2007
Dear friends,
Fine and hope the same with you all.
I am here with one more new problem which I might be able to solve with your suggestions as we have did earlier.
Problem:
I have a requirement from my client where I need to give update or edit privileges on a particular row located in a table of remote SQL server database using C#,asp.net windows application.
(or)[the other side of my question]
I need to develop a C#, asp.net windows application that will restrict two users (Client side where no database is available) from accessing the same row of a table in a remote SQL server database at the same time.

Eg: ( for explaining the question in a better way)

A Hotel 'Krishna International' is having booking centers to book rooms in this hotel from various locations. All the booking centers will be in a network and from two different locations they should not be able to book the same room at a time.

Hope I am clear with the explanation of my problem. I request you all to think of this problem and suggest me how I can solve this problem. Your directions will be very helpful to solve this problem.
This time I will keep the coding part updated frequently so that it will be helpful to me and all of you to help me in solving this problem.

Hope to get back from you at the earliest.
Thanking you in anticipation,
Vamsi K Gummadi.
Reply With Quote Quick reply to this message  
Join Date: May 2006
Posts: 1,582
Reputation: Infarction has a spectacular aura about Infarction has a spectacular aura about Infarction has a spectacular aura about 
Solved Threads: 52
Infarction's Avatar
Infarction Infarction is offline Offline
Battle Programmer

Re: Enable only one user to edit a row in SQL server database using C#, asp.net win apps

 
0
  #2
Aug 7th, 2007
Look up how transactions work. That'll keep you from giving the same room out to two different parties.
Reply With Quote Quick reply to this message  
Join Date: May 2007
Posts: 14
Reputation: vamsikgummadi is an unknown quantity at this point 
Solved Threads: 0
vamsikgummadi's Avatar
vamsikgummadi vamsikgummadi is offline Offline
Newbie Poster

Re: Enable only one user to edit a row in SQL server database using C#, asp.net win apps

 
0
  #3
Aug 9th, 2007
Hello,
Thank you for the reply and I am looking into the solution you suggested for.

In the problem I am trying to explain.
The database will be on a system 'C' and there are two clients 'A' and 'B' who are connected to 'C' through network.

A-----------------C------------------B
client database client

The client 'A' and 'B' will not have any database with them. Both of them must be able to view the database at the same time but if they try to edit (' book the room') only one should be allowed to perform the transaction at a time.
i.e., I need to restrict the number of users accessing the same row of a table in SQL database with edit and update previleges at the same time to 'One' using C# windows application. I don't have rights on the database so I need to develop this functionality as a client side windows application. I have complete previleges on all the sytems being used as clients.

Hope I am clear with my explanation.
Waiting for your suggestions,
thanking you,
Vamsi K Gummadi.
Reply With Quote Quick reply to this message  
Join Date: May 2007
Posts: 14
Reputation: vamsikgummadi is an unknown quantity at this point 
Solved Threads: 0
vamsikgummadi's Avatar
vamsikgummadi vamsikgummadi is offline Offline
Newbie Poster

Re: Enable only one user to edit a row in SQL server database using C#, asp.net win apps

 
0
  #4
Aug 9th, 2007
Hi,

Additional clarification for ' I don't have rights on the database' as and when user A or user B preforms a funtion like button press the room needs to be booked but only to one either A or B (snapshot).
Bye,
Vamsi K Gummadi
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC