How do I add a new Column at a specific position?

Posted on 2004-11-16
Last Modified: 2010-05-18
I am using the below T-SQL script to modify a table:

      ADD [USERPASSWORDDATE] [smalldatetime] NULL

I would like to add the new column at a specific position in the table.  Is there a way to do this?  Right now, when I run this script, it tacks the new column on the end of the table.  I need the new column at a specific location because some programs in my application need particular fields at certain positions.

Thanks for any help
Question by:jsprenk55
    1 Comment
    LVL 1

    Accepted Solution

    You can use the Enterprise Manager to move the column.  Just right-click the table name and choose Design.  At that point, left-click once on the row of the column name you want to move (to highlight it) and then click again and drag/drop.

    To insert it with an SQL statement, you can find that answer here:

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
    For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
    Via a live example, show how to setup several different housekeeping processes for a SQL Server.
    Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.

    729 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    21 Experts available now in Live!

    Get 1:1 Help Now