
Dynamically adding tables?
Hi, all
You can accomplish it by using Access' own SELECT... INTO syntax.
Access Help refers it as "make-table queries"
Suppose you have a table named Employees and you want to make
a backup of it. You simply write and execute an SQL as follows :
SELECT * INTO EmployeesBackup FROM Employees
This would make a new table named EmployeesBackup which would
have same content as Employees.
Considering that you have two separate databases as source and
target, you have to use the IN clause in your SQL to specify the path
of the databases. Using the above example, your SQL statement
should look like this :
SELECT *
INTO EmployeesBackup IN "c:\myapp\data\target.mdb"
FROM Employees IN " \\someserver\data\source.mdb "
Hope it helps,
Serdar Aytamaner
Quote:
> Hi,
> You can use ADOX library. It allows to change database
> structure.
> Val
>> -----Original Message-----
>> Hi,
>> The problem I need to solve via vb6.0 and access
>> 2000. I have two
>> databases. I need to move table(s) from one data base to
>> the other. I only
>> need to move the table(s) that are not in receiving
>>database.
>> I have VB code that can locate the missing tables. My
>> question is how do I
>> add a table? I really do not want to build a sql
>> statement to create athe
>> table and define all columns.
>> Any suggestion will be greatly appreciated.
>> --
>> Capt'n Roy