[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Import  table

Posted on 1998-07-27
4
Medium Priority
?
232 Views
Last Modified: 2012-05-04
How can I import table from Access to SQL Server in VB code?
0
Comment
Question by:Boolean
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 2

Expert Comment

by:threshold
ID: 1089247
VB5.0 or VBA in Access?
0
 
LVL 9

Accepted Solution

by:
cymbolic earned 150 total points
ID: 1089248
Using VBA, you can attach the SQL Server table(s) to your .mdb, and use DAO commands and INSERT INTO SQL... to do the work.

Or, under VB, you can define both the .MDB and the SQL Server database to your app using a DSN for each, then use either DAO or if enterprise version RDO, or ADO, or you also can use a combination of DAO from the .MDB, and you can use SQL insert statements you form from reading the input table, and process into SQL Server using RDO, ADO, or you can  use the SQL Client Object SQL-DMO by including it as a reference in your VB Project.  

Also, you can download uopsizing tools from the Microsoft site that will get your tables and data up to a SQL Server.  The real problem is that there are too many ways to do it!

I am primarily writing and supporting migration systems at this time, doing a lot of migrating of tables from Access .mdbs to SQL server.  Because it is not a simple one for one process, and we need to build cross references in the process, we use VB 5.0 Enterprise edition, ODBC to the .MDB and SQL server, and RDO to read in resultsets from the MDB and insert statements and the .execute method of RDO to create records on the SQL Server Database.  Works as good as nay other method, but you need at least VB 5.0, RDO 2.0, Access 97 (Ver 8.0) to get software that doesn't have so many memory leaks that the process will stop

0
 

Author Comment

by:Boolean
ID: 1089249
I'm using VB5.0, Thanks!
0
 
LVL 1

Expert Comment

by:mativare
ID: 1089250
In MSSQL server 7.0 beta you can use data transformation services to import data it is windows based, fast and handy
you can select multiple tables. I do not know it is challenging
but perhaps it can replace this heavy job cymbolic is doing.
Put still we need to create tables firs with code, if we import into new table we loose indexes and relationships.


0

Featured Post

NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
An alternative to the "For XML" way of pivoting and concatenating result sets into strings, and an easy introduction to "common table expressions" (CTEs). Being someone who is always looking for alternatives to "work your data", I came across this …
Viewers will learn how the fundamental information of how to create a table.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

649 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