Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Bcp from Access into SQL Server
Message
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Import/Export
Versions des environnements
SQL Server:
SQL Server 2005
Divers
Thread ID:
01567365
Message ID:
01567383
Vues:
28
Thank you Martina! Your help is very appreciated. I am adjusting this to the local requirements.
>Hi Rollin,
>
>You can use Ad hoc Query on MSSQL: http://www.sqlservercentral.com/Forums/Topic334873-338-1.aspx#bm335131
>It's simply use {Microsoft Access Driver (*.mdb, *.accdb)} instead "Microsoft.ACE.OLEDB.12.0" if you need read *.accdb on 64 bit SQL
>
>
>SET @lcLKV='\\server\folder\any.accdb'
> SET @lcSQL=N'INSERT INTO #LKV '+
>    'SELECT *
>       FROM OPENROWSET(''MSDASQL'', ''Driver={Microsoft Access Driver (*.mdb, *.accdb)};Dbq='+@lcLKV+';Uid=;Pwd='',
>                       ''SELECT * FROM [anytable] '')
>    '
>
> --PRINT @lcSQL
>
> EXEC sp_executesql @lcSQL
>
>
>MartinaJ
>
>>I need to automate the importation of Access tables into SQL Server. The Access database(s) are sent in on a regular schedule and I need to bring the data into SQL Server. I am not as familiar with bcp as I would like (I assume this would be the best tool to use). Any help on this would be appreciated.
Thank You

Rollin Burr

Politicians and diapers have one thing in common. They should both be changed regularly, and for the same reason.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform