sql server - SQL query in C#, invalid object name T_Server_Info -


there table named t_server_info in database, when try run code executing sql query in c#, error:

invalid object name t_server_info

here code:

private void add_click(object sender, eventargs e) {     string constring = @"data source=inpddba027\ngep;initial catalog=dev_server;integrated security=true";      try     {         con = new sqlconnection(constring);         con.open();          cmd = new sqlcommand(@"insert t_server_info(fs_uid,server_name) values(@fs_uid,@server_name)", con);         cmd.parameters.addwithvalue("@fs_uid", uid.text);         cmd.parameters.addwithvalue("@server_name", uid.text);          cmd.executenonquery();     }     catch (exception ex)     {          messagebox.show(ex.message);     } } 

please help.


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

unity3d - Fatal error- Monodevelop-Unity failed to start -