[freetds] locales.conf

Andrew J. Hutson andrewh at advfn.com
Thu Feb 12 10:19:17 EST 2004


Hi,

Have just upgraded PHP to 4.3.3, and consequently had to change from freetds0 0.53-7 to libct1 0.61-5. The upgrade has worked fine, apart from the fact that the date format returned from Sybase queries has changed. It used be in the following format (example):

May 14 2002 8:58AM

but is now in this format:

Tue May 14 08:58:00 2002

I have tried putting the following in /etc/freetds/locales.conf:

[default]
        date format = %b %d %Y %I:%M%p

[en_US]
        date format = %b %d %Y %I:%M%p
        language = us_english
        char set = iso_1

But nothing changes. It does appear to be paying any attention to the locales.conf file.

Running "strings" on the library suggests that it should be reading this file:
# strings libct.so.1* | grep conf
tds_read_config_info
ct_config
cs_config
tds_read_conf_file
tds_read_conf_section
tds_config_verstr
%L inside ct_config() action = %s property = %d
/tmp/tdsconfig.log.%d
.freetds.conf
(.freetds.conf)
/etc/freetds/freetds.conf
%L Attempting to read conf files.
%L Failed in reading conf file.  Trying interface files.
%L Found conf file '%s' %s. Reading section '%s'.
%L ...Error getting ~/.freetds.conf.  Trying %s.
%L Attempting to read locales.conf file
/etc/freetds/locales.conf
$Id: tds_configs.h,v 1.18 2002/11/21 16:53:43 freddy77 Exp $
$Id: config.c,v 1.64 2003/01/25 02:36:39 jklowden Exp $
$Id: tds_configs.h,v 1.18 2002/11/21 16:53:43 freddy77 Exp $
tds_read_config_info
ct_config
cs_config
tds_read_conf_file
tds_read_conf_section
tds_config_verstr
%L inside ct_config() action = %s property = %d
/tmp/tdsconfig.log.%d
.freetds.conf
(.freetds.conf)
/etc/freetds/freetds.conf
%L Attempting to read conf files.
%L Failed in reading conf file.  Trying interface files.
%L Found conf file '%s' %s. Reading section '%s'.
%L ...Error getting ~/.freetds.conf.  Trying %s.
%L Attempting to read locales.conf file
/etc/freetds/locales.conf
$Id: tds_configs.h,v 1.18 2002/11/21 16:53:43 freddy77 Exp $
$Id: config.c,v 1.64 2003/01/25 02:36:39 jklowden Exp $
$Id: tds_configs.h,v 1.18 2002/11/21 16:53:43 freddy77 Exp $

Any pointers would be much appreciated.

Regards,

Andrew Hutson
ADVFN PLC



More information about the FreeTDS mailing list