Is there any Microsoft SQL Server native driver for Zope?
I'll like to migrate my JDBC driver source code to Zope in order to use a native Microsoft SQL Server connection (using TCP/IP) but I don't want to start from scratch. Is there any Microsoft SQL Server native driver for Zope (pre-alpha, alpha, beta, etc)? I looked in Zope website and the only thing I found is a ODBC Database Adapter. TIA, Nicolas.-
If your Zope is running on Windows, I think your best option is to use ODBC. If Zope is running on another platform, the only solution I have seen is to get FreeTDS compiled on your system (www.freetds.org), then you will need to compile Firstworks' (www.firstworks.com) SQLRelay (excellent product for load balancing databases, anyhow) and compile it with FreeTDS support. Set up SQLRelay to connect to MS SQL Server, you can test this connection directly with SQLRelay. The Zope package for SQLRelay comes with SQLRelay. It is not very direct as you have to define your SQL server connection in three different places. In FreeTDS, in SQLRelay and in Zope. I have not tried this setup, but I can say that I have only heard good things from those who have. Nicolas Rodriguez wrote:
I'll like to migrate my JDBC driver source code to Zope in order to use a native Microsoft SQL Server connection (using TCP/IP) but I don't want to start from scratch. Is there any Microsoft SQL Server native driver for Zope (pre-alpha, alpha, beta, etc)? I looked in Zope website and the only thing I found is a ODBC Database Adapter.
TIA, Nicolas.-
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Tim Hawes]
If your Zope is running on Windows, I think your best option is to use ODBC. If Zope is running on another platform, the only solution I have seen is to get FreeTDS compiled on your system (www.freetds.org), then you will need to compile Firstworks' (www.firstworks.com) SQLRelay (excellent product for load balancing databases, anyhow) and compile it with FreeTDS support. Set up SQLRelay to connect to MS SQL Server, you can test this connection directly with SQLRelay. The Zope package for SQLRelay comes with SQLRelay. It is not very direct as you have to define your SQL server connection in three different places. In FreeTDS, in SQLRelay and in Zope. I have not tried this setup, but I can say that I have only heard good things from those who have.
You could also look at using JPE python extensions for Java - which work with C-Python (i.e., ought to work with Zope) - and keep using your existing code. Tom P
Nicolas Rodriguez wrote:
I'll like to migrate my JDBC driver source code to Zope in order to use a native Microsoft SQL Server connection (using TCP/IP) but I don't want to start from scratch. Is there any Microsoft SQL Server native driver for Zope (pre-alpha, alpha, beta, etc)? I looked in Zope website and the only thing I found is a ODBC Database Adapter.
On Wed, 6 Mar 2002, Tim Hawes wrote:
with FreeTDS support. Set up SQLRelay to connect to MS SQL Server, you can test this connection directly with SQLRelay. The Zope package for SQLRelay comes with SQLRelay. It is not very direct as you have to define your SQL server connection in three different places. In FreeTDS, in SQLRelay and in Zope. I have not tried this setup, but I can say that I have only heard good things from those who have. Once I tried this way and I was able to connect to MS-SQL server by using the FreeTDS tools. SO I was able to verify that FreeTDS works.
Unfortunately I do not understand the (currently quite sparse) documentation of the SQLRelay configuration file for accessing MS SQL server. I did not found any hint how to specify the database on the MS-SQL server I want have access to. If someone could provide a working example (perhaps in private mail) I would be very happy. Kind regards Andreas.
Tille, Andreas writes:
Once I tried this way and I was able to connect to MS-SQL server by using the FreeTDS tools. SO I was able to verify that FreeTDS works.
Unfortunately I do not understand the (currently quite sparse) documentation of the SQLRelay configuration file for accessing MS SQL server. I did not found any hint how to specify the database on the MS-SQL server I want have access to.
If someone could provide a working example (perhaps in private mail) I would be very happy.
SQLRelay config file <?xml version="1.0"?> <instances> <instance id="ID" port="PORT" unixport="" dbase="freetds" connections="4" maxconnections="8" maxqueuelength="4" growby="" ttl="60" endofsession="rollback" sessiontimeout="" socket="" runasuser="" runasgroup="" cursors="" authtier="connection"> <users> <user user="SQLRELAY-USER" password="SQLRELAY-PASSWORD"/> </users> <connections> <connection connectionid="CONNECTION-ID" string="user=MS-SQL-USER;password=HIS-PASSWORD;server=FREETDS-SERVER-NAME" metric="1"/> </connections> </instance> </instances> Corresponding freetds config file: .... [FREETDS-SERVER-NAME] host = MS-SQL-SERVER-NAME-OR-IP port = 1433 tds version = 7.0 Watch out for ALL UPPERCASE names above. You need to adapt them (consistently) to your needs. When you use an older MS SQL server, your "tds version" should be "4.2" rather than "7.0". You will start SQLRelay with "sqlr-start id=ID" ("ID" what you defined above). You will connect to SQLRelay with the "SQLRELAY-USER" and "SQLRELAY-PASSWORD" above. SQLRelay in turn will connect to your SQL server with the "MS-SQL-USER" and "HIS-PASSWORD" above. There are more options for the connection string than shown above, e.g. to control language and charset. They are documented in the configuration section of the SQLRelay documentation. Documentation is terse but complete... Dieter
NOTE: If you are still having problems with SQLRelay after this, be sure to check out the yahoo group dedicated to SQLRelay. The mailing list is usually very responsive and willing to assist. Dieter Maurer wrote:
Tille, Andreas writes:
Once I tried this way and I was able to connect to MS-SQL server by using the FreeTDS tools. SO I was able to verify that FreeTDS works.
Unfortunately I do not understand the (currently quite sparse) documentation of the SQLRelay configuration file for accessing MS SQL server. I did not found any hint how to specify the database on the MS-SQL server I want have access to.
If someone could provide a working example (perhaps in private mail) I would be very happy.
SQLRelay config file <?xml version="1.0"?> <instances> <instance id="ID" port="PORT" unixport="" dbase="freetds" connections="4" maxconnections="8" maxqueuelength="4" growby="" ttl="60" endofsession="rollback" sessiontimeout="" socket="" runasuser="" runasgroup="" cursors="" authtier="connection"> <users> <user user="SQLRELAY-USER" password="SQLRELAY-PASSWORD"/> </users> <connections> <connection connectionid="CONNECTION-ID" string="user=MS-SQL-USER;password=HIS-PASSWORD;server=FREETDS-SERVER-NAME" metric="1"/> </connections> </instance> </instances>
Corresponding freetds config file: .... [FREETDS-SERVER-NAME] host = MS-SQL-SERVER-NAME-OR-IP port = 1433 tds version = 7.0
Watch out for ALL UPPERCASE names above. You need to adapt them (consistently) to your needs. When you use an older MS SQL server, your "tds version" should be "4.2" rather than "7.0".
You will start SQLRelay with "sqlr-start id=ID" ("ID" what you defined above).
You will connect to SQLRelay with the "SQLRELAY-USER" and "SQLRELAY-PASSWORD" above. SQLRelay in turn will connect to your SQL server with the "MS-SQL-USER" and "HIS-PASSWORD" above.
There are more options for the connection string than shown above, e.g. to control language and charset. They are documented in the configuration section of the SQLRelay documentation. Documentation is terse but complete...
Dieter
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Nicolas Rodriguez writes:
I'll like to migrate my JDBC driver source code to Zope in order to use a native Microsoft SQL Server connection (using TCP/IP) but I don't want to start from scratch. Is there any Microsoft SQL Server native driver for Zope (pre-alpha, alpha, beta, etc)? I looked in Zope website and the only thing I found is a ODBC Database Adapter. You can use a Sybase database adapter over FreeTDS (<http://www.freetds.org>).
Dieter
participants (6)
-
Dieter Maurer -
Nicolas Rodriguez -
Thomas B. Passin -
Tille, Andreas -
Tim Hawes -
Tim Hawes