Results 1 to 5 of 5
  1. #1
    Join Date
    Sep 2005

    Unanswered: data types in SQL Server

    I'm new to SQL Server, but could someone explain how to set up a field with an auto number/increment that can be used within an Access DB?

  2. #2
    Join Date
    Jan 2004
    In a large office with bad lighting
    Go to Books OnLine. Lookup IDENTITY. Read. Create DDL. Try it, you'll like it .

    -- This is all just a Figment of my Imagination --

  3. #3
    Join Date
    Nov 2002
    Do you have SQL Server Client Tools Installed?

    Do you know what Books Online is?

    How about Enterprise Manager or Query Analyzer?

    Do you know what DDL is?

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  4. #4
    Join Date
    Sep 2005
    In reply to your questions:

    1. Yes
    2. No
    3. Yes
    4. No

    I've found all that and read about it but that's what I've already done. What I wanted to do was set up a system in Access using forms etc but link the tables to SQL Server instead.
    Usually when you create the tables in Access and set up an autonumber field, create a form, run it, when you change part of the form it automatically displays the number when you add a record, I take it when doing it through SQL Server it doesn't do that?
    Last edited by KevCB226; 10-12-05 at 05:37.

  5. #5
    Join Date
    Jun 2003
    Provided Answers: 1
    First, I recommend that you create and Access Data Project rather than an Access MDB with linked tables, if you have not already taken this route.

    Second, why are you displaying the auto-generated ID on your form anyway? Identity values are surrogate keys, and on principle should not be exposed to the users.

    Third, create your auto-incrementing ID value in your table using Enterprise Manager. The identity value is not assigned, however, until the record is saved, so it will not be able to display it on your form until the transaction is committed.
    If it's not practically useful, then it's practically useless.

    blindman "sqlblindman"

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts