Solved

.net app with sqlite db

Posted on 2013-02-06
2
373 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
Comment Utility
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
Comment Utility
Thanks for the insight. I looked for a .net solution but there is nothing out there...
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

763 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

8 Experts available now in Live!

Get 1:1 Help Now