3.18.2. AddQuery Previous topic Parent topic Child topic Next topic

This SQL statement is executed whenever a new user session starts (i.e. when an Accounting-Request Start message is received). It is expected to record the details of the new session in the SQL database. Special formatting characters may be used. %1 by the NAS IP address, %2 by the NAS-Port, %3 by the SQL quoted Acct-Session-Id. If AddQuery is defined as an empty string, then the query will not be executed.
%0 is replaced by the quoted original user name or rewritten user name, see Section 3.31.23. SessionDatabaseUseRewrittenName.
It defaults to:
insert into RADONLINE (USERNAME, NASIDENTIFIER, NASPORT, 
ACCTSESSIONID, TIME_STAMP, FRAMEDIPADDRESS, NASPORTTYPE, 
SERVICETYPE) values (%0, '%1', %2, %3, %{Timestamp}, 
'%{Framed-IP-Address}', '%{NAS-Port-Type}', '%{Service-Type}')