.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Import Excel data into SQL Server express 2008

Posted By:      Posted Date: September 03, 2010    Points: 0   Category :Sql Server
I have recently installed SQL express 08 and created a table to import excel data into.  Im running on a windows 7 64 bit OS i5 processor.  I've disabled the firewall (temporarily) and will set the necessary ports once this is working. I run the following query:  (which i found from multiple sources on the net) Select   * From OPENROWSET ( 'Microsoft.Jet.OLEDB.4.0', 'Excel 8.0;Database=C:\Users\Public\lenovoBkup\contacts\outlookFiles\noib2a.xls', 'Select * From [sheet1$]' )  and receive the following message: Msg 7308, Level 16, State 1, Line 1                                                                                  OLE DB provider 'Microsoft.Jet.OLEDB.4.0' cannot be used for distributed queries because the provider is configured to run in single-threaded apartment mode.  (how did they know i was single and living in an apartment? lol) so after research of the following message i restarted the system and relaunched man

View Complete Post

More Related Resource Links

How to import Data from Excel to SQL Server Express

 Hi,  please any one is expert in Data Base help me, i would like to import two Data columns from Excel file 2003 instead of two columns in a table in Sql Server Express 2005 , How Can i do that? and what is the way if I have Sql Developer 2005, thank you .  

How to Import Excel Data into SQL Server 2008(64 bit) Using SQL Query (in Windows Server 2008 64bit

I am developing VB .Net application in Visual Studio 2008(64bit), SQL Server 2008(64bit) and Windows Server 2008(64bit) environment.

I need to import an Excel and Flat files data into SQL Server database using SQL Query. I tried a lot with the following SQL Queries directly with SQL Server Management Studio,

1. SELECT * INTO  dbo.ExcelImportTest FROM OPENROWSET('Microsoft.Jet.OLEDB.4.0','Excel 8.0;Database=D:\PTPLDCT\DCT Test Datasource\DCT_Excel_Test_Sample_1.xls',
'select * from [Sheet1$]')

While executing i got an error as below,

Msg 7403, Level 16, State 1, Line 1
The OLE DB provider "Microsoft.Jet.OLEDB.4.0" has not been registered.

2. I have also tried with MSDASQL provider,

Select * from openrowset('MSDASQL','Driver={Microsoft Excel Driver (*.xls)};
Dbq=DCT_Excel_Test_Sample_1.xls;DefaultDir=D:\PTPLDCT\DCT Test Datasource\', 'Select * from [Sheet1$]')

Then i encountered the following error,

OLE DB provider "MSDASQL" for linked server "(null)" returned message "[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified".
Msg 7303, Level 16, State 1, Line 1
Cannot initialize the data source object of OLE DB provider "MSDASQL" for linked server "(null)".

3. Finally i have tried the Query with Linked Server,

EXEC sp_addlinkedserver @server = '

Data Import sql server 2008 to SQL 2000


HI All,

How to Import data from sql server 2008 to sql server 2000 ? (i don't have any idea about SSIS, expect this any chance is there? i was try with import functionality some records are copy after it was faild i have nearly 80 Lacks records)

Please help me how to solve this issue this is very urgent form me...

Thanks, Prasad.

Import Visual Pro 5 data into sql server 2008


Hi I need to import Basis Visual Pro 5 data into sql server 2008. In sql server 2000 that was possible but in this version i can not do it. Reading the docs i find there are some xml mapping files but it doesn`t help me because i am new in sql server 2008.

If someone has done it i appreciate to tell me how. Thanks

SQL Server Management Studio Express Data Import



I have installed SQL Server Management Studio Express and trying to import my access tables to SQL database.  In the blogs I have read I can do it from Tasks>>>>Import Data BUt my Tasks menu does not contain any Import Data.   It only contains

Detach, Shrink, Backup, Restore, Generate Scripts.

What is the problem with my Server Management Studio Express

import unstructured data from excel to SQL Server??


I need urgent help with  importing unstructured data from excel to SQL Server

where  columns of sql table are not in first row in the excel sheet

Excel sheet format is like the following

first name  on first row

last name is on second row  and second column B

date on third row and on column D

I will open connection to excel sheet and start copying data into sql Table

please help

Trying to import excel data into dbo schema using odbc connection with sql server


I have written this vb.net code to import an excel spread sheet but need for it to imported into the dbo shema. When I look in the database the table name is me.tablename instead of dbo.tablename.

    Public Sub Main()
        Dim sheetname As String
        excelpath = "S:\Account Management\jkormann\DynamicScoring\GE_Money_MN.xls"
        ServerName = "server"
        DBName = "sf"
        'SchemaName = "dbo"
        InsertedTableName = Dts.Variables("strTableName").Value.ToString
        sheetname = Dts.Variables("strSheet").Value.ToString
        'ImporttoServer(CStr(ExcelPath), CStr(ServerName), CStr(DBName), CStr(SchemaName), CStr(InsertedTableName))
        ImporttoServer(CStr(ExcelPath), CStr(ServerName), CStr(DBName), CStr(InsertedTableName), CStr(sheetname))

        Dts.TaskResult = Dts.Results.Success

Import data from notepad to SQL Server 2008


I have a notepad file like below:

Name:           Kerlavage, AR
Lab:            Bioinformatics
Institution:    The Institute for Genomic Research
Address:        9712 Medical Center Drive, Rockville, MD 20850 USA
Tel:            3018699056
Fax:            3018699423
E-mail:         arkerlav@tigr.org

PubMed ID:      2047873
Title:          Complementary DNA sequencing: expressed sequence tags and
                human genome project
Authors:        Adams,M.D., Kelley,J.M., Gocayne,J.D., Dubnick,M.,
                Polymeropoulos,M.H., Xiao,H., Merril,C.R., Wu,A., Olde,B.,
                Moreno,R.F., atal

Import/Export data with SQL Server 2005 Express

Hello folks!
I have installed SQL Server 2005 Express and SQL Server Management Studio Express. Everything looks ok and works fine, but I can't find the Data Import/Export Wizard.  Can anyone tell me how to Import/Export data?

Thank you!!!

SQL Express R2 - Import / Export Data (32-bit) - Excel - Unexpected Unrecoverable Error


Preface - I'm BRAND NEW to SQL! Bought a book and working to learn :) I've have a lot of experience in Access and other msft titles.

I've installed SQL Express 64 bit on Win 7 (64) and I'm trying to setup my 1st table to start practicing running queries on and I’m having nothing but trouble!! I'm trying to use the import / export wizard to import Excel '07 spreadsheet that has a table of data and I CANNOT get through this without crashing! EVERY SINGLE TIME!

My Steps:

1.  Open Wizard

Import excel data to Sql Server 2005 problem




I have tried to import data from Excel 2003 to Sql Server 2005 using the Import Wizard to no avail.  Here is my issue:


Excel column has            After import, database table

these value sets:             has these corresponding value sets:

1.01                              null

1.02                              null

1.04                              1.04

1.05                              1.05

1.06                              null

How to import dbf file data into Sql Server r2 2008


Hi to all,

          I have a task to convert dbf file into  sql .Can any one tell me how to convert dbf file into sql server r2 2008.



Mohammad Siddiqali

Under The Table: Spatial Data Support In SQL Server 2008


New spatial data support in SQL Server 2008 opens the door to mapping and querying geometric and geographic data, allowing you to build exciting new applications.

Bob Beauchemin

MSDN Magazine February 2009

Hierarchy ID: Model Your Data Hierarchies With SQL Server 2008


Here we explain how the new hierarchyID data type in SQL Server 2008 helps solve some of the problems in modeling and querying hierarchical information.

Kent Tegels

MSDN Magazine September 2008

Consuming External Data Using SharePoint Server 2010 Business Connectivity Services and an Excel 201

Learn how to use BCS in SharePoint Server 2010 to access and update external data by using Microsoft Excel 2010 as a client.

How to connect to local instance of SQL Server 2008 Management Studio Express ?


I just installed SQL Server 2008 Management studio Express on my Vista machine.

i tried connecting to local machine using :

.\sqlexpress, (local)\sqlexpress, or .\SQLExpress, MyPCNAME\SQLExpress

nothing is working, getting this error:

Cannot connect to PC-NAME\SQLEXPRESS. A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

sql server 2008 import/export wizard... completely useless??



import/export wizard in 2000 had lots of options.

I could copy databases without a care in the world. Including constraints, stored proc., AND the data, etc.

Now, with v2008, the wizard is dumbed down too much. It's a "stupid" copy function that fails on the first constraint it meets.

"Copy database.." is not an option here: it needs sysadmin on both source and destination server.

Re-adding the constraints manually is not an option either: the database is WAY too large. 

I'm actually hoping there is a temporary bug in the import/export wizard. Each option (and you have THREE...) returns with a new error.

Googling, I found I am not alone:


This post is exactly my situation. Here's what his post says: (bolded key parts)


I'm trying to get used to sql server 2008 having been forced to upgrade by my isp. I need to back up my key db on a weekly remote schedule, so have been trying to use ssms to export data from my remote db to a local copy.

Firstly I created a new empty db on the local machine. Then I scripted the structure of the db on the remote machine and ran the resulting query on the local machin

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend