Quantcast
Channel: MySQL Forums - Connector/NET and C#, Mono, .Net
Viewing all articles
Browse latest Browse all 1451

update not executing // how to see what's wrong ? (no replies)

$
0
0
hi !

trying to do an upate a single field, but nothing happens... anyone could give me a clue ?

::
public bool update_tel_png()
{
try
{
data.MissingSchemaAction = MissingSchemaAction.Error;
MySqlCommand cmd = new MySqlCommand("UPDATE tbl_address SET tel_png = '?tel_png' WHERE tel_link = '?tel_link'");
cmd.Parameters.Add("?tel_png", MySqlDbType.VarChar, 250, "tel_png").Value = this.hit_telefonnr_png_file;
cmd.Parameters.Add("?tel_link", MySqlDbType.VarChar, 250, "tel_link").Value = this.hit_telefonnr_img_link;

// conn.Open();
data.UpdateCommand = cmd;
data.UpdateCommand.Connection = conn;


//
// data.UpdateCommand.UpdatedRowSource = System.Data.UpdateRowSource.None;
data.UpdateBatchSize = 1;
data.Update(dataset, "tbl_address");

return true;
}
catch
{
return false;
}

}

Viewing all articles
Browse latest Browse all 1451

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>