Help with LETODB and xharbour

245 views
Skip to first unread message

jmrodr...@gmail.com

unread,
Oct 27, 2017, 3:59:26 PM10/27/17
to
I work with xHarbour 1.2.3 Intl. (SimpLex) (Build 20170513) and BCC 55.
I want to try the letodb library.
I downloaded the latest version from http://www.kresin.ru/en/letodb.html (letodb-2.17-b3.bcc and letodb-2.17-b3.src).

I use this test program:

function main()

local cServer:='//127.0.0.1:2812/' // IPadress of server

REQUEST LETO
RDDSETDEFAULT("LETO")

if Leto_Connect(cServer)==-1 // is the server listening?
? 'No hay conexion con el servidor ' + cServer
? 'Error:' + str(LETO_CONNECT_ERR())
else
? 'Conexión correcta con el Servidor' + cServer
endif

RETURN nil

I run the letodb server without problems:


LETODB.INI:

Port=2812
DataPath=C:\DEV\LETODB
Logfile=letodb.log
Default_Driver=CDX


LETODB.LOG:

10/27/17 20:55:43: Leto DB Server has been started.
Leto DB Server v.2.17b3 ! INIT: DataPath=C:\DEV\LETODB, ShareTables=0, MaxUsers=500, MaxTables=5000, CacheRecords=10


I compile the test program with HARBOUR it works correctly but if I compile it in my environment (xHarbour + BCC52) it gives error 7 when trying to connect:

No hay conexion con el servidor //127.0.0.1:2812/
Error: 7

I do not know why. Some help?

Thank's!!!

Richard Visscher

unread,
Oct 27, 2017, 5:49:01 PM10/27/17
to
Op vrijdag 27 oktober 2017 21:59:26 UTC+2 schreef jmrodr...@gmail.com:
Hi,

If you look at rddleto.ch, there you find code 7 ( socket error )

Regards,
Richard
Message has been deleted

jmrodr...@gmail.com

unread,
Oct 28, 2017, 4:10:54 AM10/28/17
to
Thank's Richard, yes already I saw it, but some idea of ​​why the same code works with harbour and not with xharbour? What can be the cause? 
Socket error it's very generic I do not know how to continue.

Enrico Maria Giordano

unread,
Oct 28, 2017, 4:47:19 AM10/28/17
to


Il 27/10/2017 21:59, jmrodr...@gmail.com ha scritto:

> I compile the test program with HARBOUR it works correctly but if I compile it in my environment (xHarbour + BCC52) it gives error 7 when trying to connect:
>
> No hay conexion con el servidor //127.0.0.1:2812/
> Error: 7
>
> I do not know why. Some help?

Could it be that it's for Harbour only (ie. compiled with Harbour)?

EMG

--
http://www.emagsoftware.it
http://www.emagsoftware.it/emgmusic
http://www.emagsoftware.it/spectrum
http://www.emagsoftware.it/tbosg

Enrico Maria Giordano

unread,
Oct 28, 2017, 4:51:13 AM10/28/17
to


Il 28/10/2017 10:47, Enrico Maria Giordano ha scritto:

> Could it be that it's for Harbour only (ie. compiled with Harbour)?

Maybe there is a xHarbour version too?

Richard Visscher

unread,
Oct 28, 2017, 6:20:40 AM10/28/17
to
On Saturday, October 28, 2017 at 10:10:54 AM UTC+2, jmrodr...@gmail.com wrote:
> Thank's Richard, yes already I saw it, but some idea of ​​why the same code works with harbour and not with xharbour? What can be the cause? 
> Socket error it's very generic I do not know how to continue.

I think the Harbour Threading/socket part is not the same as Xharbour, you can try downloading a lower version eg LetoDB 2.12 which has a different socket part i think.

regards,
Richard

jmrodr...@gmail.com

unread,
Oct 31, 2017, 3:12:50 PM10/31/17
to
Hi, I can not get it to work. Can someone confirm to me that the combination of xharbour 1.2.3 and letodb works? Someone uses it in production?

My problem is that my applications use gtwvw and this library does not work properly in harbor. This does not allow me to migrate to harbor.

Thank you very much for the help.

Jose Manuel

Richard Visscher

unread,
Oct 31, 2017, 3:24:17 PM10/31/17
to
Op dinsdag 31 oktober 2017 20:12:50 UTC+1 schreef jmrodr...@gmail.com:
Hi,

Which compiler are you using with xharbour ?

Regards,
Richard

jmrodr...@gmail.com

unread,
Nov 1, 2017, 3:40:44 AM11/1/17
to
hi Richard, thanks for your interest. I use bcc 5.5

Best regards

JM Rodriguez

cul...@gmail.com

unread,
Nov 2, 2017, 1:21:41 PM11/2/17
to
Hi
much better is use sqlrdd or RDDADS

Regards
Luiz

Anderson Cardoso

unread,
Sep 20, 2022, 1:38:47 PMSep 20
to
In the reade.txt it says:
2.5 xHarbour

SERVER: the server itself must be build with Harbour, cannot be done with xHB.
Same applies for utils like console monitor.

CLIENT: client library (RDD) can be build with xHarbour, use the 'rddleto.lib.xbp' definition for
xBuilder. For Windows ( but not for XCC ), it will by default use a second thread ( without HVM ),
so the executable must be linked with a library containing '_beginthreadex()'.
cFlag define: LETO_NO_THREAD=1 set for xHB will disable this and the need for threading function,
[ C-compiler: note that xBuilder doesn't store used C-compiler -- change it on demand.
XCC: can't compile 3rd party 'lz4.c', compile it with PellesC >= 4.5 manually,
and replace it in list of files for xBuilder with resulting 'lz4.obj':
pocc.exe -Fo"obj\lz4.obj" -Ot -I"include" -I"source\3rd\lz4\lib" -I%PATH_XHB%"\include"
-I%PATH_POCC%"\Include" -I%PATH_POCC%"\include\Win" "source\3rd\lz4\lib\lz4.c"

So, all we need is to compile the LIB with xHarbour.
The server can be done with Harbour or downloaded here: https://linguagemclipper.com.br/blogs/tutoriais/tutorial-letodbf-como-servico-do-windows

I am trying to compile this LIB with no success. Why don´t you include this RDDLETO.LIB in the package of xHarbour v1.2.3 ? All we need is the lib compiled with same version of xHarbour used.

Anderson Cardoso

unread,
Sep 20, 2022, 1:40:52 PMSep 20
to
v1.2.3 didn´t work with BCC55 with me, I had to use BCC58.
I can´t compile this rddleto.lib eighter.
Reply all
Reply to author
Forward
0 new messages