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

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

FROM_UNIXTIME($phpdate);
Hello,

I tried to use this :

$date = FROM_UNIXTIME($phpdate);

ANd I was t

Local file browser with php
Halo..

So this is what i want to create. I have a folder that i share and it has many movies.

Transferring session variables into MySQL
I am trying to transfer $_SESSION variables into MySQL. However there is an error in my MySQL statem

Preg_match unknown modifyer
Hello,

Im trying to write a little script for my forums i need to get the reply from my forum

BAPI BBP_INB_DELIVERY_CREATE - material number missing in delivery
Hi Experts,

I was able to successfully create an Inbound delivery with reference to a PO

that old Malformed Headers problem again!!!!! HELP!!!!!!
I've read the http://www.phpfreaks.com/forums/index.php/topic,37442.0.html

I don't think my c

Session is not saving
I am not trying to do anything too fancy, I am just trying to get some $_SESSION data to save and us

Extracting Long text from message class with parameters
Hi,

I would like to extract the long text from a message class. However, the long text ha

C++ API to Oracle dB
I need to perform a select command to the Oracle dB to obtain information from a table.
What libr

Help Optimizing code
Good Morning,

I wrote a small import function for a website of mine and I know there has to b

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