From ikorot01 at gmail.com Sat Feb 6 17:49:25 2021 From: ikorot01 at gmail.com (Igor Korot) Date: Sat, 6 Feb 2021 16:49:25 -0600 Subject: [freetds] Can't connect with ODBC Message-ID: Hi, ALL, I have Sybase 16.0 installed on my Gentoo box and just installed freeTDS (version 1.00.558 from Gentoo repository). Next I modified odbc configuration as follows: [code] IgorReinCloud /etc/portage/package.use # cat /etc/unixODBC/odbcinst.ini [ODBC] Trace=yes TraceFile=/tmp/sql.log [freeTDS] Description=FreeTDS Driver Driver=/usr/lib64/libtdsodbc.so FileUsage=1 [/code] [code] IgorReinCloud /etc/portage/package.use # cat /etc/unixODBC/odbc.ini [freetds] Driver=freeTDS Description=FreeTDS driver Trace=Yes Server=IgorReinCloud Database=draft Port=5000 TDS_Version=5.0 [/code] [code] IgorReinCloud /etc/portage/package.use # hostname IgorReinCloud [/code] [code] igor at IgorReinCloud ~ $ isql freetds sa wasqra [ISQL]ERROR: Could not SQLConnect [/code] [code] ODBC][20736][1612650402.974333][/var/tmp/portage/dev-db/unixODBC-2.3.5-r1/work/unixODBC-2.3.5/DriverMa$ Entry: Connection = 0x55dcbc900b90 Server Name = [freetds][length = 7 (SQL_NTS)] User Name = [sa][length = 2 (SQL_NTS)] Authentication = [******][length = 6 (SQL_NTS)] UNICODE Using encoding ASCII 'UTF8' and UNICODE 'UTF16LE' DIAG [01000] [FreeTDS][SQL Server]Unknown host machine name. DIAG [S1000] [FreeTDS][SQL Server]Unable to connect to data source [/code] [code] igor at IgorReinCloud ~ $ cat /opt/sap/interfaces REINCLOUD master tcp ether localhost 5000 master tcp ether IgorReinCloud 5000 query tcp ether localhost 5000 query tcp ether IgorReinCloud 5000 REINCLOUD_BS master tcp ether localhost 5001 query tcp ether localhost 5001 REINCLOUD_XP master tcp ether localhost 5002 query tcp ether localhost 5002 REINCLOUD_JSAGENT master tcp ether localhost 4900 query tcp ether localhost 4900 [/code] What am I missing? Thank you. From ikorot01 at gmail.com Sun Feb 7 04:55:46 2021 From: ikorot01 at gmail.com (Igor Korot) Date: Sun, 7 Feb 2021 03:55:46 -0600 Subject: [freetds] Way to identify freetds. Message-ID: Hi, ALL, Is there a way to differentiate freetds from native Sybase/Microsoft driver/library? Thank you. From freddy77 at gmail.com Sun Feb 7 05:33:00 2021 From: freddy77 at gmail.com (Frediano Ziglio) Date: Sun, 7 Feb 2021 10:33:00 +0000 Subject: [freetds] Way to identify freetds. In-Reply-To: References: Message-ID: Il giorno dom 7 feb 2021 alle ore 09:57 Igor Korot ha scritto: > > Hi, ALL, > Is there a way to differentiate freetds from native Sybase/Microsoft > driver/library? > > Thank you. Hi, from the client side sure. For ODBC you can simply ask ODBC using SQLGetInfo. For other libraries they have different ABIs so you can check these or check some minor differences in headers/macros. >From the server side I'm not sure. Regards, Frediano From ikorot01 at gmail.com Sun Feb 7 13:22:53 2021 From: ikorot01 at gmail.com (Igor Korot) Date: Sun, 7 Feb 2021 12:22:53 -0600 Subject: [freetds] Way to identify freetds. In-Reply-To: References: Message-ID: Hi, Frediano, On Sun, Feb 7, 2021, 4:35 AM Frediano Ziglio wrote: > Il giorno dom 7 feb 2021 alle ore 09:57 Igor Korot > ha scritto: > > > > Hi, ALL, > > Is there a way to differentiate freetds from native Sybase/Microsoft > > driver/library? > > > > Thank you. > > Hi, > from the client side sure. For ODBC you can simply ask ODBC using > SQLGetInfo. > I presume I need SQL_DRIVER_NAME, right? For other libraries they have different ABIs so you can check these or > check some minor differences in headers/macros. > Could you provide some code, please? Or at least tell what to check... > From the server side I'm not sure. > Dont care about that. Thank you. > Regards, > Frediano > _______________________________________________ > FreeTDS mailing list > FreeTDS at lists.ibiblio.org > https://lists.ibiblio.org/mailman/listinfo/freetds > From ikorot01 at gmail.com Wed Feb 10 09:22:10 2021 From: ikorot01 at gmail.com (Igor Korot) Date: Wed, 10 Feb 2021 09:22:10 -0500 Subject: [freetds] Next release Message-ID: Hi, (Frediano), What are the plans for the next release of the freeTDS? Will it include the missing ODBC function? Or it will be postponed for the next one? Thank you. From freddy77 at gmail.com Sun Feb 21 03:41:33 2021 From: freddy77 at gmail.com (Frediano Ziglio) Date: Sun, 21 Feb 2021 08:41:33 +0000 Subject: [freetds] Can't connect with ODBC In-Reply-To: References: Message-ID: Il giorno sab 6 feb 2021 alle ore 22:46 Igor Korot ha scritto: > > Hi, ALL, > I have Sybase 16.0 installed on my Gentoo box and just installed freeTDS > (version 1.00.558 from Gentoo repository). > > Next I modified odbc configuration as follows: > > [code] > IgorReinCloud /etc/portage/package.use # cat /etc/unixODBC/odbcinst.ini > [ODBC] > Trace=yes > TraceFile=/tmp/sql.log > > [freeTDS] > Description=FreeTDS Driver > Driver=/usr/lib64/libtdsodbc.so > FileUsage=1 > [/code] > > [code] > IgorReinCloud /etc/portage/package.use # cat /etc/unixODBC/odbc.ini > [freetds] > Driver=freeTDS > Description=FreeTDS driver > Trace=Yes > Server=IgorReinCloud > Database=draft > Port=5000 > TDS_Version=5.0 > [/code] > > [code] > IgorReinCloud /etc/portage/package.use # hostname > IgorReinCloud > [/code] > > [code] > igor at IgorReinCloud ~ $ isql freetds sa wasqra > [ISQL]ERROR: Could not SQLConnect > [/code] > > [code] > ODBC][20736][1612650402.974333][/var/tmp/portage/dev-db/unixODBC-2.3.5-r1/work/unixODBC-2.3.5/DriverMa$ > Entry: > Connection = 0x55dcbc900b90 > Server Name = [freetds][length = 7 (SQL_NTS)] > User Name = [sa][length = 2 (SQL_NTS)] > Authentication = [******][length = 6 (SQL_NTS)] > UNICODE Using encoding ASCII 'UTF8' and UNICODE 'UTF16LE' > > DIAG [01000] [FreeTDS][SQL Server]Unknown host machine name. > This specific error should indicate that FreeTDS is not able to resolve the address, in this case should be "IgorReinCloud". Can you try something like "ping IgorReinCloud" ? > DIAG [S1000] [FreeTDS][SQL Server]Unable to connect to > data source > [/code] > > [code] > igor at IgorReinCloud ~ $ cat /opt/sap/interfaces > > REINCLOUD > master tcp ether localhost 5000 > master tcp ether IgorReinCloud 5000 > query tcp ether localhost 5000 > query tcp ether IgorReinCloud 5000 > Is the server listening to both addresses (localhost and machine address)? > > REINCLOUD_BS > master tcp ether localhost 5001 > query tcp ether localhost 5001 > > > REINCLOUD_XP > master tcp ether localhost 5002 > query tcp ether localhost 5002 > > > REINCLOUD_JSAGENT > master tcp ether localhost 4900 > query tcp ether localhost 4900 > > [/code] > > What am I missing? > > Thank you. Frediano From freddy77 at gmail.com Sun Feb 21 03:50:19 2021 From: freddy77 at gmail.com (Frediano Ziglio) Date: Sun, 21 Feb 2021 08:50:19 +0000 Subject: [freetds] Way to identify freetds. In-Reply-To: References: Message-ID: Il giorno dom 7 feb 2021 alle ore 18:24 Igor Korot ha scritto: > > Hi, Frediano, > > On Sun, Feb 7, 2021, 4:35 AM Frediano Ziglio wrote: > > > Il giorno dom 7 feb 2021 alle ore 09:57 Igor Korot > > ha scritto: > > > > > > Hi, ALL, > > > Is there a way to differentiate freetds from native Sybase/Microsoft > > > driver/library? > > > > > > Thank you. > > > > Hi, > > from the client side sure. For ODBC you can simply ask ODBC using > > SQLGetInfo. > > > > I presume I need SQL_DRIVER_NAME, right? > Yes > For other libraries they have different ABIs so you can check these or > > check some minor differences in headers/macros. > > > > Could you provide some code, please? > Or at least tell what to check... > > It should be automatic when you detect FreeTDS header (which are slightly different). So something in the "configure" like scripts (depending on the build system you are using). Otherwise you can check for specific extensions, like for dblib you can check presence of "DBTDS_7_4" macro or the presence of tdsdbopen function. For ctlib you can check presence of "CS_TDS_74". > > > From the server side I'm not sure. > > > > Dont care about that. > > Thank you. > > Regards, Frediano From freddy77 at gmail.com Sun Feb 21 03:52:19 2021 From: freddy77 at gmail.com (Frediano Ziglio) Date: Sun, 21 Feb 2021 08:52:19 +0000 Subject: [freetds] Next release In-Reply-To: References: Message-ID: Il giorno mer 10 feb 2021 alle ore 14:24 Igor Korot ha scritto: > > Hi, (Frediano), > What are the plans for the next release of the freeTDS? > Will it include the missing ODBC function? Or it will be postponed for > the next one? > > Thank you. Hi, the main change for the next version will be utf-8 support for mssql beside some improvements for Sybase (mostly BCP) which will bring library more close to Sybase one. The SQLDescribeParam is not planned. Patches welcome. Regards, Frediano