473,386 Members | 1,715 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

copying a table out of access using code

I have already posted a similar question to this but the answers
didn't work so I have decided to post again and hopefully I can be a
little more specific about what I need.
I am using access and vb to draw a sample of x records from a database
containing about 700000 records upon the press of a button and the
user entering some basic parameters. An array of tables are created
through this process and these will be kept within my .mdb, however I
would like a backup copy of two of the tables to be created with each
sample as well and placed in an alternative location. I really need
this to be carried out in code as its needs to be done automatically
and some users may not be able to?!? I would maybe like to store the
tables in a different format like .xls maybe, or something that could
easily be imported back into access but that you do not necessarily
need access to open them. Is this possible? I am estimating that the
potential maximum number of records in a table to be moved would be
about 10000. This would maybe limit the number of different formats it
could be saved as???? I have tried TransferSpreadsheet,
TransferDatabase, Move..., ExportXML, Save and probably some others
that I have now forgotten but I can't get any of them to work. I was
just hoping someone might have some code to do this? Any help or
suggestions will be appreciated. Thanks!
Nov 13 '05 #1
2 1313
Outputto

"MissiMaths" <mi********@hotmail.com> wrote in message
news:75**************************@posting.google.c om...
I have already posted a similar question to this but the answers
didn't work so I have decided to post again and hopefully I can be a
little more specific about what I need.
I am using access and vb to draw a sample of x records from a database
containing about 700000 records upon the press of a button and the
user entering some basic parameters. An array of tables are created
through this process and these will be kept within my .mdb, however I
would like a backup copy of two of the tables to be created with each
sample as well and placed in an alternative location. I really need
this to be carried out in code as its needs to be done automatically
and some users may not be able to?!? I would maybe like to store the
tables in a different format like .xls maybe, or something that could
easily be imported back into access but that you do not necessarily
need access to open them. Is this possible? I am estimating that the
potential maximum number of records in a table to be moved would be
about 10000. This would maybe limit the number of different formats it
could be saved as???? I have tried TransferSpreadsheet,
TransferDatabase, Move..., ExportXML, Save and probably some others
that I have now forgotten but I can't get any of them to work. I was
just hoping someone might have some code to do this? Any help or
suggestions will be appreciated. Thanks!

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.775 / Virus Database: 522 - Release Date: 08/10/2004
Nov 13 '05 #2
Thank you! The outputTo works brilliantly! I was now wondering if
there might be a way within this coding to make the table that has
been moved read only? And how would one use the encoding part of the
ouputTo command, as I can't find any real reference to it within the
help other than to its existance?
Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: radioman | last post by:
Hi all, I would appreciate some help please. I just need pointing in the right direction as I am at a loss. Basically I have a form (frmAddMaster) which displays two subforms "Master Stock...
3
by: sparks | last post by:
I was copying fields from one table to another. IF the var name starts with milk I change it to egg and create it in the destination table. It works fine but I want to copy the description as...
8
by: brian kaufmann | last post by:
Hi, I'm new to Access and this may be a basic question but I would appreciate it if you could let me know how to do this: I've created an Access table and would like to insert a column with...
11
by: Geoff | last post by:
Hi I have a DataTable with thousands of rows. I want a quick way to insert the rows into a table in an Access database with the same structure. I have been using an update command but found it...
1
by: syvman | last post by:
Hi all... I've been trying to copy a VFP table into an Access database and I haven't had much success... The code I'm using below (Access VBA) returns a "Syntax Error" in the SQL statement. If I...
20
by: TC | last post by:
I need an automated procedure to copy data from an Access table to a SQL Server table. Speed is important. What is the recommended technique? I can export the data from Access, copy it via FTP,...
9
by: Kelii | last post by:
I've been trying to get this piece to work for a few hours, but have given up. I hope someone out there can help, I think the issue is relatively straightforward, but being a novice, I'm stumped....
5
by: mark_aok | last post by:
Hi all, I have a situation where I have a split database. At the back end, I need to - create a new table (I will call it newTable) with the exact fields, and relationships as another table...
1
by: iitt2007 | last post by:
I have a XLS file on local machine and would like to copy all the columns to a new SQL table on the 'remote' (not local sql server) using SQL scripts. I tried following : select * into...
2
by: troy_lee | last post by:
What is the best way of copying all the records from a linked table into a replica table that is local on my computer? This is for development work at home where I can not access the main table. Is...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.