int Vs Numeric , Varchar vs NVarchar - Which is good? (MS ACCESS TO SQL SERVER MIGRATION)

Posted on 2007-10-04
Last Modified: 2009-05-07
I am planning to migrate my website which uses the MS ACESS Database to MS SQL Server 2000.
So, I have to move the tables and queries from access db to sql server using DTS IMPORT EXPORT DATA.

BUT... In MS Access DB, I have set some field datatypes as text and number
but, when moved to SQL SERVER, it is set as INT and NVARCHAR...

Is it good to continue with this datatype(INT and NVARCHAR) or converting it to NUMERIC and VARCHAR is better???

suggestions please....
Question by:jawahar_prasad
    LVL 142

    Accepted Solution

    it fully depends on what data you have.
    int is a integer, no decimals. numeric can store larger number and have decimal parts.

    varchar/nvarchar depends if you have several characterset data to be stored in the field.
    LVL 14

    Expert Comment

    nvarchar - accepts unicode characters
    varchar doe not it depends on your application...
    either you can change to varchar or keep it as such if you want unicode characters.
    LVL 23

    Expert Comment

    by:Ashish Patel
    rather than (INT and NVARCHAR) use (INT and VARCHAR)  where NVarchar is the unicode type. which i assume you wont need. And int is better than numeric is you dont have precision in column values.
    LVL 5

    Expert Comment

    Since in access you can have only number as datatype and in SQL server we have a range of datatypes for numbers like Numeric, int, double etc.
    As per the other experts advice, i too ve the same opinion, if the data is going to be purely numbers with no precision, then simply go for int rather tham numeric.

    Nvarchar and varchar choice is completly yours depending on the values that you have stored in that field.
    By default when you use DTS package to transfer data from text it takes as nvarchar. you can use varchar if you don have any special character set data to be stored in the coulmn

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How your wiki can always stay up-to-date

    Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
    - Increase transparency
    - Onboard new hires faster
    - Access from mobile/offline

    Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
    In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
    Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.
    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.

    760 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

    10 Experts available now in Live!

    Get 1:1 Help Now