About FiveWin ODBC

About FiveWin ODBC

Postby xhbcoder » Tue Dec 05, 2006 4:16 pm

FW,

May I know those who had experienced using FiveODBC.

Thanks,

Jose
xhbcoder
 
Posts: 100
Joined: Wed Oct 04, 2006 4:50 pm
Location: USA

Postby xhbcoder » Tue Dec 05, 2006 4:34 pm

What I mean is how's the performance, specially with MS SQL server.

Thanks.
xhbcoder
 
Posts: 100
Joined: Wed Oct 04, 2006 4:50 pm
Location: USA

Postby Antonio Linares » Tue Dec 05, 2006 11:48 pm

It works fine, but you should upgrade to FWH 32 bits, as it offers a much better integration with the operating system.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42048
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Five ODBC with Clipper

Postby xhbcoder » Wed Dec 13, 2006 5:02 pm

Antonio,

Our base code is in Clipper 5.2. I tried to convert them to xHarbour but there are issues like Telepathy lib which don't have 32 bits version and several C codes that generates errors, when linked. I looked for 32 bit version as you suggested but Extransensory Software do not have 32 bit version of Telepathy.

For now, we are trying to connect our program to SQL server for possible enhancement.

I am able to connnect using FiveODBC but it returns only one record.

Heres the code taken from your example.

******************
Function LS_odbc()
******************
Local oODBC := TOdbc():New "DsnEntry", "YourName", "YourPassword")

If !oOdbc:lSuccess
oOdbc:ShowErrorList("ODBC session not successfully initialized, aborting...")
oOdbc:End()
return nil
Endif
*oDbf := oOdbc:Query( "SELECT * FROM JOURNAL" )
Odbf := TdbOdbcDirect():New("SELECT * FROM JOURNAL WHERE JRDATE = '10/6/06' ORDER BY JRDATE, JRTIME", oOdbc)
if oOdbc:IsError()
oOdbc:ShowErrorList()
oOdbc:aErrors := {}
oDbf:End()
return nil
endif
oDbf:Open()

*oDBF:goBottom()
*msginfo(str(ODbf:recNO()))
*msgInfo(oDBF:jrzday)
*Browse( cTitle, cListName, bNnew, bModify, bDelete, bSearch, bList )
copy to tmp
Browse("Journal")
return nil

Note:
The browse shows one record only.
The tmp file contain one record only.

Can we keep clipper 5.2 and accomplish FiveODBC? Just let me know if it possible.

We don't need to convert to 32 bit right now since Clipper 5.2 version looks stable.

Gracias,

-jose
xhbcoder
 
Posts: 100
Joined: Wed Oct 04, 2006 4:50 pm
Location: USA

Postby Antonio Linares » Wed Dec 13, 2006 6:15 pm

Jose,

Have you checked at the ODBC database that there are more than one record matching that SQL sentence ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42048
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby xhbcoder » Wed Dec 13, 2006 10:18 pm

Antonio,

Thanks for the quick reply.

Yes, there are over 60 rows when I querry it from SQL.
xhbcoder
 
Posts: 100
Joined: Wed Oct 04, 2006 4:50 pm
Location: USA

Postby Eugeniusz Owsiak » Thu Dec 14, 2006 7:27 am

Jose

after line
oDbf:Open()

you must add

oDbf:Complete()


regards Eugeniusz
User avatar
Eugeniusz Owsiak
 
Posts: 60
Joined: Fri Oct 07, 2005 5:38 am
Location: Poland

About odbc

Postby xhbcoder » Mon Dec 18, 2006 6:11 pm

Eugeniusz,

Thanks for the hint. It works.

Regards,

Jose
xhbcoder
 
Posts: 100
Joined: Wed Oct 04, 2006 4:50 pm
Location: USA


Return to FiveWin for CA-Clipper

Who is online

Users browsing this forum: No registered users and 5 guests