To manually import Excel data into SQL

Source: Internet
Author: User

1. Right click on the database name, Tasks---Import data ...

2. Choose Data source:microsoft Excel, select the Excel file and Excel version. Excel version and data source Excel must match

3. Choose a destination:sql Server Native Client 10.0, enter the SQL Server name, authentication method, username password to import, select the database to import

4. Tick the worksheet (Source) of the Excel you want to import, and select the SQL data table (Destination) you want to import. You can edit the corresponding relationship between the columns of Excel and the fields of the data table by clicking on Edit Mappings. If the title of the Excel column and the field name of the data table are the same (case-insensitive), mappings will give the auto-corresponding, inconsistent, and can be manually matched.

Attention:

1. The data type of the Excel column must match the data type of the SQL data table field

2. Excel data to meet the SQL data table field is not empty, unique constraints

There is a very strange problem when importing today, Excel has a column of pure numbers, but the corresponding SQL table field is the nvarchar type.

I set the Excel column to text format, but still no, the prompt when importing is a double type, cannot be converted to nvarchar type, how to set prompt is double type.

Finally, in the Excel data column, precede the number with a single quotation mark, the upper left corner of the cell appears the green triangle number, select "The number stored as text", then import, it is OK.

Another: http://jingyan.baidu.com/article/e3c78d64663d873c4c85f5ec.html

To manually import Excel data into SQL

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.