Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Dataset database issues

Dataset database issues

Scheduled Pinned Locked Moved C#
databasecomsecurityhelpannouncement
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    cvncpu
    wrote on last edited by
    #1

    I have this function: [WebMethod] public string SetUserInfo(string AuthID, DataSet dg2) { if (AuthID=="********") { Oconn.Open(); da.Update(dg2); Oconn.Close(); return "it seems to have worked."; } else { return "Your Authentication Failed"; } } and this is my da (dataAdapter) var: public SqlDataAdapter da = new SqlDataAdapter(); but it keeps coming back with an error: "Update unable to find TableMapping['Table'] or DataTable 'Table'" http://digg.com

    B A 2 Replies Last reply
    0
    • C cvncpu

      I have this function: [WebMethod] public string SetUserInfo(string AuthID, DataSet dg2) { if (AuthID=="********") { Oconn.Open(); da.Update(dg2); Oconn.Close(); return "it seems to have worked."; } else { return "Your Authentication Failed"; } } and this is my da (dataAdapter) var: public SqlDataAdapter da = new SqlDataAdapter(); but it keeps coming back with an error: "Update unable to find TableMapping['Table'] or DataTable 'Table'" http://digg.com

      B Offline
      B Offline
      Bahadir Cambel
      wrote on last edited by
      #2

      You should supply a DataTable named as Table in WebService function inputs(DataSet dg2)

      1 Reply Last reply
      0
      • C cvncpu

        I have this function: [WebMethod] public string SetUserInfo(string AuthID, DataSet dg2) { if (AuthID=="********") { Oconn.Open(); da.Update(dg2); Oconn.Close(); return "it seems to have worked."; } else { return "Your Authentication Failed"; } } and this is my da (dataAdapter) var: public SqlDataAdapter da = new SqlDataAdapter(); but it keeps coming back with an error: "Update unable to find TableMapping['Table'] or DataTable 'Table'" http://digg.com

        A Offline
        A Offline
        albCode
        wrote on last edited by
        #3

        public string SetUserInfo(string AuthID, DataSet dg2) { if (AuthID=="********") { Oconn.Open(); string connection = "server = localhost;database=urdatabase;uid=urid;pwd=urpswd"; string updatedata = "update urtable set AuthID = " + " '" + this.textbox1.text + "where AuthID = "********"; SqlConenction conn = new SqlConnection(connection ); SqlCommad cmdupdate = new SqlCommad(updatedata ,conn); da.Fill(udataset,"urtable"); Oconn.Close(); } else { return "Your Authentication Failed"; } } Maybe this helps u Regards;

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups