redundant SQL / WARNING: Unknown module "sql" in string expansion

Phil Mayers p.mayers at imperial.ac.uk
Tue Nov 9 22:10:46 CET 2010


On 11/09/2010 05:39 PM, Tom Teeuwen wrote:
> Do you have an example of how to achive this ?

You could maybe try something like:

update request {
   Tmp-String-0 := "%{sql1: ... query ...}"
}
if (Tmp-String-0 =~ /^$/) {
   # empty string; try 2nd sql
   update request {
     Tmp-String-0 := "%{sql2: ... query ...}"
   }
}

# now compare contents of Tmp-String-0

Obviously that won't work if you execute a query which has a valid 
result as "" (empty string)



More information about the Freeradius-Users mailing list