Solved

Web Service to update SQL Server table

Posted on 2009-03-29
3
527 Views
Last Modified: 2012-05-06
I've got a web service written in VB.NET that I use to send datasets to an application and receive data back as a dataset after the user has modified the data within the application.  The biggest drawback to this method is that it could be a large dataset and sometimes the people work over a slow connection.  I've been looking for a way to send back and update an SQL table everytime they modify a record.  The code on the application isn't a problem, but I haven't found a good example of a web service that will update the SQL Server.  I only need to update two fields (a date the record was updated and who it was update by).
0
Comment
Question by:TomCoon
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 96

Expert Comment

by:Bob Learned
ID: 24017392
What kind of "example" are you looking for.  If you are only looking for a way to pass in a primary key value, and any field values, I wouldn't think that would be too difficult.
0
 

Author Comment

by:TomCoon
ID: 24018399
Want to pass primary key and two field values to be updated, one a date field (smalldatetime) and the other text (nvarchar(10)).  Passing it back to the web service isn't a problem, but the code to get the web service to update the SQL Server table is what I'm looking for.
0
 
LVL 96

Accepted Solution

by:
Bob Learned earned 500 total points
ID: 24018516
Are you looking for SqlCommand.ExecuteNonQuery to insert data?

Example:

http://www.startvbdotnet.com/ado/sqlserver1.aspx
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A Change in PHP Behavior with Session Write Short Circuit (http://php.net/manual/en/book.session.php#116217) (Winter 2014)** With the release of PHP 5.6 the session handler changed in a way that many think should be considered a bug.  See the note …
Thoughout my experience working on eCommerce web applications I have seen applications succumbing to increased user demand and throughput. With increased loads the response times started to spike, which leads to user frustration and lost sales. I ha…
This video teaches viewers how to create their own website using cPanel and Wordpress. Tutorial walks users through how to set up their own domain name from tools like Domain Registrar, Hosting Account, and Wordpress. More specifically, the order in…
Learn how to set-up PayPal payment integration in your Wufoo form. Allow your users to remit payment through PayPal upon completion of your online form. This is helpful for collecting membership payments, customer payments, donations, and more.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question