Problem with the Update command used with a sqldataadapter


Posted on 16th Feb 2014 07:03 pm by admin

I'm connected to a database on an SQL Server and I'm using a sqldataadapter, sqlconnection, sqldataset generated at DESIGNTIME.
I want to call the update command asociated with a sqldataadapter but I don't want to use all the parametres in the command becose I don't need to.
An sqlUpdateCommand created at DESIGNTIME look like this

Did you know?Explore Trending and Topic pages for more stories like this.
this.sqlUpdateCommand1.CommandText = @"UPDATE masini SET producatoriID = @producatoriID, tip = @tip, combustibil = @combustibil, pret = @pret, [data achizitiei] = @Param2 WHERE (masiniID = @Original_masiniID) AND (combustibil = @Original_combustibil) AND ([data achizitiei] = @Original_data_achizitiei) AND (pret = @Original_pret) AND (producatoriID = @Original_producatoriID OR @Original_producatoriID IS NULL AND producatoriID IS NULL) AND (tip = @Original_tip); SELECT masiniID, producatoriID, tip, combustibil, pret, [data achizitiei] FROM masini WHERE (masiniID = @masiniID)";

Pls get me out of this mess.


And another thing. If you have some documentation on Crystal Reports (for SQL Server databases) please send me an e-mail with an attach file.
No comments posted yet

Your Answer:

Login to answer
134 Like 53 Dislike
Previous forums Next forums
Other forums

Script not running properly
Hello Everyone
This is a basic script for posting to a database. I'm not sure why it doesn't work

image upload, resize THEN submit form
Ok so I have a form that requires the user to upload an image, and then do something with that image

help with this code please?
Hello,

I am trying to build a remote upload script for my image hosting site.

I am usi

INSERT data problem!
After having an string with apostrophes ', double quotes " or any other special characters, suc

PHP switch function help
Hi, I am trying to create a search function for a directory website. On the search function on html

mySQL and PHP search
Hello,
I am trying to code a project and ran into a brick wall with one of my pages. I am pretty

Estimations and Effort
HI Gurus,

Would like to know whether SAP have a provision for carrying out the Project es

PHP Code / Script To check weather the given email exists in a domain
Hi,

I want to implement the following in my web page

in sign up we will ask to enter u

Need Help with a query
Hello,
For some reason I am just not getting the right answer when I do this query and not quite

Need help with simple code, back and forward buttons.
Basically, I have a set of pages in a folder, which have the title somephrasehere_09.php, somephrase

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash