Solved

.net app with sqlite db

Posted on 2013-02-06
2
380 Views
Last Modified: 2013-02-11
Hi -
I have a sqlite database that uses Write-Ahead Log (wal). So the main db does not update live.

I need to right an app in .net (vb) that gets real time stats.

If I copy the db file and the wal file to my local hard drive, is there anyway to flush/merge the data to update the main db.

e.g
file 1: test.db (main db)
file 2: test.db-wal (wal file holding current information)

want to flush test.db-wal into test.db  so the the most resent information is in the main db

Thanks in advance
0
Comment
Question by:doctor069
2 Comments
 
LVL 11

Accepted Solution

by:
madgino earned 500 total points
ID: 38862961
The synchronization between wal and main is called "checkpoint"
It seems that doing a "checkpoint" is not possible using .NET library, at least there is nothing documented about this.

The operation seems to be available from the C library, you have below the documentation but I couldn't find an example.

Theoretically you can call C libraries from .NET.

http://www.sqlite.org/c3ref/wal_checkpoint_v2.html
http://www.sqlite.org/c3ref/wal_checkpoint.html



https://www.google.com/#hl=en&q=using+c+library+in+.net
0
 

Author Closing Comment

by:doctor069
ID: 38877120
Thanks for the insight. I looked for a .net solution but there is nothing out there...
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

735 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