Click here to Skip to main content
16,005,206 members
Home / Discussions / Database
   

Database

 
GeneralRe: Problem with C# and MySQL Pin
Snowjim31-Jan-03 6:36
Snowjim31-Jan-03 6:36 
GeneralRe: Problem with C# and MySQL Pin
kaschimer31-Jan-03 6:54
kaschimer31-Jan-03 6:54 
GeneralRe: Problem with C# and MySQL Pin
Snowjim31-Jan-03 6:58
Snowjim31-Jan-03 6:58 
GeneralRe: Problem with C# and MySQL Pin
David Salter1-Feb-03 10:18
David Salter1-Feb-03 10:18 
GeneralRe: Problem with C# and MySQL Pin
Snowjim1-Feb-03 12:11
Snowjim1-Feb-03 12:11 
GeneralRe: Problem with C# and MySQL Pin
David Salter1-Feb-03 12:49
David Salter1-Feb-03 12:49 
GeneralRe: Problem with C# and MySQL Pin
Snowjim1-Feb-03 12:58
Snowjim1-Feb-03 12:58 
GeneralRe: Problem with C# and MySQL Pin
Snowjim1-Feb-03 14:40
Snowjim1-Feb-03 14:40 
Hello again, now i have get the code to work, it shows the stuf in the mysql server in to a form in C#.

{<br />
	IDataReader reader;<br />
	IDbCommand cmd;<br />
	System.Data.OleDb.OleDbConnection con;<br />
	con=new System.Data.OleDb.OleDbConnection("");<br />
			con.ConnectionString="server=localhost;Provider=MySQLProv;Data Source=database;";<br />
<br />
	try<br />
	{<br />
		con.Open();<br />
		if (con.State==ConnectionState.Open)<br />
		{<br />
			cmd = con.CreateCommand();<br />
			cmd.CommandText = "UPDATE humans SET Name = 'Nisse'  WHERE id = '3'";<br />
			cmd.ExecuteNonQuery();<br />
			cmd.CommandText = "SELECT * FROM humans";<br />
			reader = cmd.ExecuteReader();<br />
<br />
			while (reader.Read())<br />
			{<br />
				lb.Items.Add(reader.GetString(1) + "  " + reader.GetString(2));<br />
			}<br />
			MessageBox.Show("Connection to MySQL opened through OLE DB Provider");<br />
			con.Close();<br />
			}<br />
		}<br />
		catch(Exception ex)<br />
		{<br />
		MessageBox.Show(ex.Message);<br />
		}<br />
	}<br />
<br />
}



But as you se i am trying to update the mysql data base. This does not work i get the following error DB_ERRORSINCOMMAND(0x80040E14)

Do you got a ide of why i get this error?
GeneralRe: Problem with C# and MySQL Pin
David Salter2-Feb-03 11:41
David Salter2-Feb-03 11:41 
GeneralRe: Problem with C# and MySQL Pin
David Salter2-Feb-03 11:49
David Salter2-Feb-03 11:49 
GeneralTimestamp and long problem in access Pin
leppie30-Jan-03 23:12
leppie30-Jan-03 23:12 
GeneralRe: Timestamp and long problem in access Pin
Bernhard Hofmann31-Jan-03 1:40
Bernhard Hofmann31-Jan-03 1:40 
GeneralRe: Timestamp and long problem in access Pin
leppie31-Jan-03 4:16
leppie31-Jan-03 4:16 
GeneralRe: Timestamp and long problem in access Pin
leppie31-Jan-03 23:18
leppie31-Jan-03 23:18 
GeneralRe: Timestamp and long problem in access Pin
Bernhard Hofmann3-Feb-03 5:18
Bernhard Hofmann3-Feb-03 5:18 
GeneralRe: Timestamp and long problem in access Pin
leppie3-Feb-03 6:10
leppie3-Feb-03 6:10 
GeneralPerforming Bulk Insert from C# Pin
Darryl Borden29-Jan-03 11:22
Darryl Borden29-Jan-03 11:22 
GeneralRe: Performing Bulk Insert from C# Pin
SimonS29-Jan-03 20:54
SimonS29-Jan-03 20:54 
GeneralRe: Performing Bulk Insert from C# Pin
Darryl Borden30-Jan-03 4:47
Darryl Borden30-Jan-03 4:47 
GeneralRe: Performing Bulk Insert from C# Pin
Bruce Duncan30-Jan-03 8:21
Bruce Duncan30-Jan-03 8:21 
Generalfrustrated!!!! Pin
Gabriel.P.G28-Jan-03 16:55
Gabriel.P.G28-Jan-03 16:55 
GeneralAccess Front End, SQL Back End and Record Locking Pin
Paul Watson28-Jan-03 2:17
sitebuilderPaul Watson28-Jan-03 2:17 
GeneralRe: Access Front End, SQL Back End and Record Locking Pin
Richard Deeming28-Jan-03 3:36
mveRichard Deeming28-Jan-03 3:36 
GeneralRe: Access Front End, SQL Back End and Record Locking Pin
Paul Watson31-Jan-03 6:47
sitebuilderPaul Watson31-Jan-03 6:47 
Generalsearching a dataset Pin
Sean Cull26-Jan-03 13:31
Sean Cull26-Jan-03 13:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.