Re: dhRichClient and Locking

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance




"P.McFarlane" <phil_mac@xxxxxxxxxxxxxx> schrieb im Newsbeitrag
news:O03Bapz3JHA.4632@xxxxxxxxxxxxxxxxxxxxxxx

I have downloaded the latest dhRichClent and demos to
look at the possibility of moving from an access database
using dao to SQLite. I have converted the existing db to
sqlite format to test using RPCDBDemo.
First I would test your converted DB locally - to make sure
it is working as it should using "normal clientside SQLite".

When this works fine - and the performance is Ok (sometimes
the imported Indexes do not match well with the way sqlite
optimizes queries internally and need to be redefined) - well
then you should try the network-stuff with RPC.

The demo works fine as is however if I substitute my database
I get the following error message:
In RPC-Mode the Server is the only instance which sees the
DB - and the DB should be put into your Folder, which
also hosts the RPC-Dll-Binaries. In your case this is:
D:\RichClient\RPC-Demos\ServerBin\RPCDlls\..

You will have to put your DB there (let's call it "MyDB.db3"
for example).
Since you say, the original Demo works fine - then take a look
at the DB-File, this RPC-Demo is using originally - it should
also be there in that folder (called "NWind.db" then).

Now the decision, which DB to access remotely has to be
done at the clientside.
If you open the clientside RPC-Projekt, which you will find
in the Demo-Folder ..\RPCClientDemo-SQLite-RemoteDB\
There is currently a constant in each of the 3 different
forms - two of them are specialized to work with NWind.db
only - the third one can work generically against every sqlite-
DB - the name of the form is: fSQLiteAccess ... and as said,
please change the appropriate Const for your current serverside
DBName from:
Private Const SQLiteDBName$ = "Nwind.db"
to:
Private Const SQLiteDBName$ = "MyDB.db3"

Here the needed steps again:
1. convert your *.mdb to sqlite-format and test it locally
2. copy your new sqlite-db into the serverside "Root-Folder"
which is ...\ServerBin\RPCDlls\..
3. Open the clientisde RPC-DB-Project and change the
DBName-Constant in fSQLiteAccess to match the
DBName of your current serverside DB.
4. Start one of the ServerBinaries from inside \ServerBin\
(either the SimpleServer, or the service-controller-based
Server) and check, that the status-infos you get are OK.
5. Now you can test, by starting the RPC-DB-Demo-Client
directly from within the VB-IDE if you want.
In case your server runs locally, you don't need to specify
an IP-address in the upcoming "intermediate Starterform".
Now go straight to the first button, since that will start the
generic working Form, which we just gave a different
DBName "to know".
6. In that form your first action should be, to scan the serverside
DB for all tables it currently contains, using the appropriate
Button ("Get Table- and View-names").
If that succeeds, then "everything else" should normally work
too.

HTH - and let me know how it does and "feels-like" regarding
performance when you have it working.

Regards,

Olaf


.


Quantcast