R: Sql Counter reads only the first 4 digits

2009-05-21 Thread Mauro Iorio - Smart Soft s.r.l.
Uh... no. If it works for Ivan, then the problem is most likely in the unixodbc drivers. Alan DeKok. But when I run the same query in both isql and tsql the result is correct. So I think that unixodbc and freetds are ok. I'll try to recompile them anyway... Other ideas?

Re: R: Sql Counter reads only the first 4 digits

2009-05-21 Thread Alan DeKok
Mauro Iorio - Smart Soft s.r.l. wrote: But when I run the same query in both isql and tsql the result is correct. So I think that unixodbc and freetds are ok. I'll try to recompile them anyway... Other ideas? Instrument the FreeRADIUS source code. Follow the data from SQL, through the

Sql Counter reads only the first 4 digits

2009-05-20 Thread Mauro Iorio - Smart Soft s.r.l.
Hi all, I've a strange problem with sql counter on freeradius both 1.1.7 and 2.1.5 versions. Actually executing SELECT SUM(AcctSessionTime) FROM radacct WHERE UserName='mauro' from SQL Server Management Studio gives me 294841 (Yes, that's a lot of seconds, is a test user) while the

Re: Sql Counter reads only the first 4 digits

2009-05-20 Thread Alan DeKok
Mauro Iorio - Smart Soft s.r.l. wrote: I’ve a strange problem with sql counter on freeradius both 1.1.7 and 2.1.5 versions. Actually executing SELECT SUM(AcctSessionTime) FROM radacct WHERE UserName='mauro' What happens when you replace that SELECT statement with a hard-coded number,

R: Sql Counter reads only the first 4 digits

2009-05-20 Thread Mauro Iorio - Smart Soft s.r.l.
What happens when you replace that SELECT statement with a hard-coded number, like 123456? Does it still truncate the result? Alan DeKok. Yes, it does. Check the following output: - rlm_sqlcounter: Entering module authorize code

Re: R: Sql Counter reads only the first 4 digits

2009-05-20 Thread Marinko Tarlac
select 123456 from radacct where username = 'mauro' LIMIT 1 On Wed, May 20, 2009 at 2:44 PM, Mauro Iorio - Smart Soft s.r.l. m.io...@smartsoft.it wrote: What happens when you replace that SELECT statement with a hard-coded number, like 123456? Does it still truncate the result?

Re: Sql Counter reads only the first 4 digits

2009-05-20 Thread Ivan Kalik
Mauro Iorio - Smart Soft s.r.l. wrote: I’ve a strange problem with sql counter on freeradius both 1.1.7 and 2.1.5 versions. Actually executing SELECT SUM(AcctSessionTime) FROM radacct WHERE UserName='mauro' What happens when you replace that SELECT statement with a hard-coded number,

Re: R: Sql Counter reads only the first 4 digits

2009-05-20 Thread Ivan Kalik
select 123456 from radacct where username = 'mauro' LIMIT 1 Don't bother with all that. Hardcode just: SELECT 123456 Ivan Kalik Kalik Informatika ISP - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Re: R: Sql Counter reads only the first 4 digits

2009-05-20 Thread Alan DeKok
Mauro Iorio - Smart Soft s.r.l. wrote: Yes, it does. Check the following output: ... [sessioncounter]expand: %{sql:SELECT 123456 FROM radacct WHERE UserName='mauro'} - 1234 Hmm... I don't use the unixodbc drivers, so I can't test it here. I don't see anything in the code that would

R: R: Sql Counter reads only the first 4 digits

2009-05-20 Thread Mauro Iorio - Smart Soft s.r.l.
Don't bother with all that. Hardcode just: SELECT 123456 Ivan Kalik Kalik Informatika ISP Done. Same result: 1234. Mauro Iorio. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Sql Counter reads only the first 4 digits

2009-05-20 Thread Mauro Iorio - Smart Soft s.r.l.
Don't bother with all that. Hardcode just: SELECT 123456 Ivan Kalik Kalik Informatika ISP Done. Same result: 1234. Mauro Iorio. Any configuration parameter hidden somewhere which limits result lenght to 4 digits??? Mauro Iorio. - List info/subscribe/unsubscribe? See

Re: Sql Counter reads only the first 4 digits

2009-05-20 Thread Alan DeKok
Mauro Iorio - Smart Soft s.r.l. wrote: Any configuration parameter hidden somewhere which limits result lenght to 4 digits??? Uh... no. If it works for Ivan, then the problem is most likely in the unixodbc drivers. Alan DeKok. - List info/subscribe/unsubscribe? See