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. Database & SysAdmin
  3. Database
  4. Inserting a Row - Returning the ID

Inserting a Row - Returning the ID

Scheduled Pinned Locked Moved Database
csharpquestionlearning
2 Posts 1 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.
  • A Offline
    A Offline
    AJ123
    wrote on last edited by
    #1

    Hi There This has got to be an easy one... I am coming to ADO.NET from an ADO background, so i appologise if it comes across as totally stupid! All i want to do is insert a new row into a table and pull back the autonumber primary key assigned to it. What i don't want to have to do is: 1) Fill a Dataset in order to get a DataTable definition. 2) Use stored procedures. Anybody know the answer off the top of their head? Guess i really need to buy a good ADO.NET book. Thanks In Advance Rich

    A 1 Reply Last reply
    0
    • A AJ123

      Hi There This has got to be an easy one... I am coming to ADO.NET from an ADO background, so i appologise if it comes across as totally stupid! All i want to do is insert a new row into a table and pull back the autonumber primary key assigned to it. What i don't want to have to do is: 1) Fill a Dataset in order to get a DataTable definition. 2) Use stored procedures. Anybody know the answer off the top of their head? Guess i really need to buy a good ADO.NET book. Thanks In Advance Rich

      A Offline
      A Offline
      AJ123
      wrote on last edited by
      #2

      Found my answer :- There is a good discussion of this at: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnadonet/html/manidcrisis.asp[^]

      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