On Jun 26, 2015, at 12:54 PM, Adam Hammond <adam.hammond@wicoms.com> wrote:
On 26 Jun 2015, at 17:33, Arran Cudbard-Bell wrote:
My production server uses several sql instances, mainly so I can use different queries on different virtual servers that authenticate access in different ways.
Use multiple queries.conf files and include them in the different SQL instances?
Yep - that's what I do.
Up till now (well - up till 3.0.4) 'Sql-Group' has always just worked for me in the configuration included in each instance. I'll make sure I set it properly from now on.
Which was wrong and broken, yes.
Should I apply the same formatting to '%{SQL-User-Name}' as well, to reference the sql instance name?
No. Different internal mechanism for managing the attributes. The lifetime of SQL-User-Name is only as long as the call to rlm_sql lasts. Using SQL-Group triggers a callback, which does the group comparisons. -Arran