questions regarding sql xlat

Arran Cudbard-Bell a.cudbard-bell at sussex.ac.uk
Mon Apr 20 10:08:48 CEST 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Uwe Kastens wrote:
> Hello list,
>
> I am trying to use some internal database function to calculate the
> Session-Timeout.
>
> If I set the value for Session-Timeout to a integer like 123, its
> correctly delivered as answer to my request.
>
> If I try to use sql xlat I will get the answer:
> Error: rlm_sql: Failed to create the pair: Unknown value %{sql:SELECT
> disctime.time FROM `disctime` WHERE disctime.user = %{User-Name}}   for
> attribute Session-Timeout
> Sun Apr 19 20:11:03 2009 : Error: rlm_sql (sql): Error getting data from
> database
>
> I tried several different things: Use a select statement to query the
> integer directly. I ends up in the same error. I am using:
>
*sigh* single quotation marks around %{User-Name}, it's still a string
remember....
> - freeradius: FreeRADIUS Version 2.0.4, for host i486-pc-linux-gnu,
> built on Sep  7 2008 at 23:35:34
> - Debian GNU/Linux 5.0 (lenny)
> -  postgresql 8.3.7-0lenny1
>
> BR
>
> Uwe
>
>
>

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAknsLZAACgkQcaklux5oVKJICwCdGQ8po+i46xN3uXUyp0GGDwOr
xWIAn22YpKHnqtJse1rCGRFow+KHc6hq
=1D2m
-----END PGP SIGNATURE-----




More information about the Freeradius-Users mailing list