Merging two SQLite database files (C# .NET)

Posted by CODe on Stack Overflow See other posts from Stack Overflow or by CODe
Published on 2010-12-28T05:47:14Z Indexed on 2010/12/28 5:54 UTC
Read the original article Hit count: 354

Filed under:
|
|
|
|

Hello all,

I'm using C#/.NET with the C# wrapper for SQLite. I'm attempting to merge two SQLite databases together while excluding duplicates.

I found this, which is referenced from a few different forum questions. http://old.nabble.com/Attempting-to-merge-large-databases-td18131366.html

Would I run the following queries in my SQLite configuration as listed below?

attach 'c:\test\b.db3' as toMerge;   
insert into AuditRecords select * from toMerge.AuditRecords; 

My main question is whether the above will remove duplicates, and if it doesn't, is there a merge or some other command I can use?

Thanks very much!

© Stack Overflow or respective owner

Related posts about c#

Related posts about .NET