C How do I add a table to a MySQL database???? Please see the details

Updated on technology 2024-03-22
4 answers
  1. Anonymous users2024-02-07

    Do you send out your sql part to take a look? Report any errors?

  2. Anonymous users2024-02-06

    1. Use different connection objects to access the database, and each specific connection object needs to import a different namespace. c The name of the sqlconnection that accesses the SQL Server database is as follows.

    2. Use SQL Server authentication mode to create a connection.

    3. After creating a connection through sqlconnection, c has not really connected to the sql server database; Next, to open the connection; Really establish a closed connection to the database with an empty shout.

    4. After establishing a data connection, send SQL command to the database, then you can use the sqlcommand object: sqlcommand cmd = new sqlcommand(sql, conn);.

    5. For C to send SQL command to the database and return the result set, you need to use the sqldataadapter object: sqldataadapter adp = new sqldataadapter(sql, conn); Returns the result set Crack.

    6. C After completing the operation on the SQL Server database, remember to close the data connection of SQL Connection: ;

  3. Anonymous users2024-02-05

    This one is simple.

    Define database connection global variables.

    const string connstring = @"data source=theman-pc; database=wpgl;user id=sa;password=admins";

    private void button4_click(object sender, eventargs e)

    sqlconnection conn = new sqlconnection(connstring);

    string mysql = "Insert database operations will do the trick";

    sqlcommand cmd = new sqlcommand(mysql, conn);;

  4. Anonymous users2024-02-04

    If you study it, you will understand.

Related questions
7 answers2024-03-22

The button does not have a doubleclick event.

eventhandler(button1_doubleclick);With this method, the double-click event is not triggered when double-clicked, but rather a double-click event. >>>More

9 answers2024-03-22

1. Communicate with the bank and strive to eliminate If the loan is overdue due to non-malicious or force majeure factors (such as **, tsunami), etc., you can call the bank's customer service** or go to the bank branch, sincerely explain your situation, and attach a guarantee for timely repayment in the future. If the bank has not reported to the central bank's credit system, then it is possible to eliminate the loan overdue record. 2. Maintain good repayment and replace the old with the new If you are careless, then you can only maintain good repayment in the future if you want to eliminate the loan overdue record. >>>More

9 answers2024-03-22

The steps to export your iPhone contacts to your Android phone are as follows: >>>More

22 answers2024-03-22

1. Ensure that the characters passed by the text box are numeric characters. >>>More

10 answers2024-03-22

Examples are as follows: 1. Basic information Parent-child class: xx class Children's age: >>>More