Rlm_sql: dynamic queries

Alan DeKok aland at deployingradius.com
Tue Mar 2 16:24:57 CET 2010


Dan-Cristian Bogos wrote:
> I receive accounting records with more attributes with the same name
> (resulting into freeradius in attribute lists).
> I would like to run mysql multiple inserts in one query (possible with
> mysql by enumerating values between brackets, eg: insert into table
> (a, b) values (user-name[0], destination), (username[1], destination),
> (username[2], destination). ).

  Perl.

  i.e. The server doesn't include a generic programming language.  There
are already too many of them.

> Can anyone recommend me any better way of doing it (so I do not need
> to define a query for a number of attributes, but have the query
> generated in some automatic way, so I will only need one sql
> instance)?

  rlm_perl, and run a script.

  Alan DeKok.



More information about the Freeradius-Users mailing list