New API to MSSQL using FreeTDS DB-Lib

Forum related to MS SQL Server

Moderators: gto, cipto_kh, EgonHugeist

Post Reply
mdbs99
Fresh Boarder
Fresh Boarder
Posts: 4
Joined: 22.10.2010, 13:24
Location: Rio de Janeiro, Brazil
Contact:

New API to MSSQL using FreeTDS DB-Lib

Post by mdbs99 »

Hi,
Some developers are working in a wrapper to use FreeTDS in FreePascal/SQLdb and this already working good.

IMHO, Zeos should be use this new API because it is better than old ntwdblib.dll.

Click here to see the discussion about TMSSQLConnection class.

The ADO is the better way to works with MSSQL, but ADO do not work with FreePascal, so I think this is a good option.
mdbs99
Fresh Boarder
Fresh Boarder
Posts: 4
Joined: 22.10.2010, 13:24
Location: Rio de Janeiro, Brazil
Contact:

Post by mdbs99 »

Nobody interested?
User avatar
EgonHugeist
Zeos Project Manager
Zeos Project Manager
Posts: 1936
Joined: 31.03.2011, 22:38

Post by EgonHugeist »

Sound's very interesting, i will take a look..
Best regards, Michael

You want to help? http://zeoslib.sourceforge.net/viewtopic.php?f=4&t=3671
You found a (possible) bug? Use the new bugtracker dude! http://sourceforge.net/p/zeoslib/tickets/

Image
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

It would be very interesting. If you think you could write a FreeTDS driver and want to add it to the zeoslib project, please contact me, so I can add you to the commiters list on sourceforge.

Mark

BTW : I do NOT have time nor test servers available for active mssql development. So I can only provide some theoretical or logistical support on this.
Image
rautgigi
Fresh Boarder
Fresh Boarder
Posts: 16
Joined: 08.10.2006, 19:54

Post by rautgigi »

Hi,

This is my implementation for FreeTDS driver. It's base on dbLib driver with some modifications. I make some test with same basic sql and it should be fine. It will be more ease for me also if you can include it into svn.

You should change WINDOWS_DLL_LOCATION inside ZPlainFreeTDS with dblib_dll.dll or what is the name of the freeTDS library.

All the best,
Bogdan Dragulin
You do not have the required permissions to view the files attached to this post.
Last edited by rautgigi on 22.05.2012, 10:47, edited 1 time in total.
User avatar
EgonHugeist
Zeos Project Manager
Zeos Project Manager
Posts: 1936
Joined: 31.03.2011, 22:38

Post by EgonHugeist »

rautgigi,

YEEESS somebody who works with us! Terrifik! I' ll look @this very exactly, trust me on that! :D
But first on the next days. I was also working on the TDS-Driver. But i'm not ready because i've simplified the whohle DBLib untit. My proposal is attached. Can you take a look to this too?

I've tryed to manage some strong simplifications. Also i've thinned the code extreamly out. The existing ASE and and MsSQL7 files are out of use now. But i've problems with the exception-handlers... And acually no luck with connecting to my 2005 Server...

Did you've success with connecting? May i ask you some things concering the FreeTDS?

Which server did you use here? With which TDSVER did you compile the library

Michael
You do not have the required permissions to view the files attached to this post.
Best regards, Michael

You want to help? http://zeoslib.sourceforge.net/viewtopic.php?f=4&t=3671
You found a (possible) bug? Use the new bugtracker dude! http://sourceforge.net/p/zeoslib/tickets/

Image
rautgigi
Fresh Boarder
Fresh Boarder
Posts: 16
Joined: 08.10.2006, 19:54

Post by rautgigi »

Hi,

I will have a look on the dblib. Yes you can always ask :).
I just add #define MSDBLIB 1 to the Src\win32\config.h file and comment out
//#define TDS42 1 and add #define TDS72 1. So the TDS Version was 72, but it should be leaved as TDS42. It took me a day to figure out that the 72 version is not supported right now, and also that the version can be simply change as a running value using SetEnvironmentVariable( PWideChar('TDSVER'), PWideChar('7.2') );
User avatar
EgonHugeist
Zeos Project Manager
Zeos Project Manager
Posts: 1936
Joined: 31.03.2011, 22:38

Post by EgonHugeist »

Hmm i'm not so shure if that runtime Protocol changes do work. But i'll try this.

Like i wrote before i'm not ready. But each help is always welcome. In my proposal i try to use the inheritence as best as possible. My first straight intention was it to simplify the whole Sybase and MsSQL units.

So this might be interesting for you too. I thought some override do mange everything as well where we've differences. Example are the constants which are a little bit different and some record changes.

btw. pm is comming again.

Michael
Best regards, Michael

You want to help? http://zeoslib.sourceforge.net/viewtopic.php?f=4&t=3671
You found a (possible) bug? Use the new bugtracker dude! http://sourceforge.net/p/zeoslib/tickets/

Image
Post Reply