Solved

Playing with databases...

Posted on 1998-06-30
1
155 Views
Last Modified: 2010-05-03
Is there any way to add one database (dBaseIV) to another so that there isn't any dublicates in data?
Here's example:
I've got one database where is datas from 1/1/1998 to 15/6/1998 and another where is datas from 1/6/1998 to 30/6/1998. I wanna kind of update this first database so that there is all datas from 1/1/1998 to 30/6/1998.

Could there be any SQL-clause to do this? If there is could you give me example?

Thanks for advance.
0
Comment
Question by:majala
1 Comment
 
LVL 5

Accepted Solution

by:
dirtdart earned 50 total points
ID: 1464589
When I've had to do this, I've used the following method:

Dim srcRs As Recordset
Dim destRs As Recordset
Dim SQL As String

SQL = "SELECT * FROM MyTable WHERE MyField = '" & srcRs("MyField") & "'"

set destRs = db.OpenRecordset(SQL)
destRs.MoveLast
destRs.MoveFirst
If destRs.Recordcount <> 0
    'Move record from one table to the other because it doesn't exist
End If
destRs.Close

0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

708 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now