I develop a simple 3-tier database library Version 0.1
It is very easy to use. This version is applied to fpc/win32 only and will port to other OS later.
How easy ? Just look at the following code samples :
Include the following units: pinousclient, db, memds
var
mConn : TdgsClient ;
mdb : TMemDataSet ;
mError : String ;
begin
mdb := TMemDataset.Create( nil ) ;
mConn := Tdgsclient.Create ;
// SetHost( 'serverip','key in dgserver.conf','alias', serverport )
mConn.SetHost( '127.0.0.1','123456789','PDEMO',6999 ) ;
mConn.Connect ;
mError := mConn.ActiveSQL( mdb, 'select * from salesman' ) ; // your SQL here
if mError <> '' then
WriteLn( 'Error : ' + mError ) // Show error message from server
else
begin
// show the content of database ;
mdb.first ;
while not mdb.Eof do
begin
WriteLn( mdb.FieldByName( 'salesid' ).AsString + ':' + mdb.FieldByName( 'salesname' ).AsString ) ;
mdb.Next ;
end ;
end;
// Disconnect from server and Free
mConn.DisConnect ;
mConn.Free ;
mdb.Free ;
end ;
You can download the wrapper / library and the server here :
http://www.francogrp.com/3-tier-demo0.1.zip The performance is awesome !
Have fun !