SQL module question...
So, I know that there've been several changes to how the sql module loads. On one site, there is only one query, in a sql xlat, and the question is now about an error that the site is getting: (14) sql: EXPAND .query (14) sql: --> .query No such configuration item .query Granted, all table entries and the '$INCLUDE' for query.conf were commented out on the basis that only the sql xlat would be used, but why would the xlat still be looking for the 'post-auth.query' entry in the sql module (or the query.conf for that matter)? We've gotten around it by defining a 'post-auth { query = "select * from ..." }' line in the sql module to make it happy, but it seems to me that if you use a sql xlat, and there is no other call to 'sql' or '-sql' in the post-auth section, it shouldn't be looking for the post-auth.query string... Thoughts? Stefan Paetow Moonshot Industry & Research Liaison Coordinator t: +44 (0)1235 822 125 gpg: 0x3FCE5142 xmpp: stefanp@jabber.dev.ja.net skype: stefan.paetow.janet Lumen House, Library Avenue, Harwell Oxford, Didcot, OX11 0SG jisc.ac.uk Jisc is a registered charity (number 1149740) and a company limited by guarantee which is registered in England under Company No. 5747339, VAT No. GB 197 0632 86. Jisc’s registered office is: One Castlepark, Tower Hill, Bristol, BS2 0JA. T 0203 697 5800. Jisc Collections and Janet Ltd. is a wholly owned Jisc subsidiary and a company limited by guarantee which is registered in England under Company No. number 2881024, VAT No. GB 197 0632 86. The registered office is: Lumen House, Library Avenue, Harwell, Didcot, Oxfordshire, OX11 0SG. T 01235 822200.
On Apr 20, 2015, at 5:17 AM, Stefan Paetow <Stefan.Paetow@jisc.ac.uk> wrote:
I know that there've been several changes to how the sql module loads. On one site, there is only one query, in a sql xlat, and the question is now about an error that the site is getting:
(14) sql: EXPAND .query (14) sql: --> .query No such configuration item .query
Granted, all table entries and the '$INCLUDE' for query.conf were commented out on the basis that only the sql xlat would be used, but why would the xlat still be looking for the 'post-auth.query' entry in the sql module (or the query.conf for that matter)?
Because the module has no idea which sections it will be called from in the future. There's no "instantiate post-auth stuff" method. Just "instantiate everything".
We've gotten around it by defining a 'post-auth { query = "select * from ..." }' line in the sql module to make it happy, but it seems to me that if you use a sql xlat, and there is no other call to 'sql' or '-sql' in the post-auth section, it shouldn't be looking for the post-auth.query string...
Ideally, yes. That's hard to do without changing significant amounts of the server. Alan DeKok.
Because the module has no idea which sections it will be called from in the future. There's no "instantiate post-auth stuff" method. Just "instantiate everything".
Ok.
Ideally, yes. That's hard to do without changing significant amounts of the server.
Thanks, Alan. I'll feed that back. :-) Stefan Paetow Moonshot Industry & Research Liaison Coordinator t: +44 (0)1235 822 125 gpg: 0x3FCE5142 xmpp: stefanp@jabber.dev.ja.net skype: stefan.paetow.janet Lumen House, Library Avenue, Harwell Oxford, Didcot, OX11 0SG jisc.ac.uk Jisc is a registered charity (number 1149740) and a company limited by guarantee which is registered in England under Company No. 5747339, VAT No. GB 197 0632 86. Jisc’s registered office is: One Castlepark, Tower Hill, Bristol, BS2 0JA. T 0203 697 5800. Jisc Collections and Janet Ltd. is a wholly owned Jisc subsidiary and a company limited by guarantee which is registered in England under Company No. number 2881024, VAT No. GB 197 0632 86. The registered office is: Lumen House, Library Avenue, Harwell, Didcot, Oxfordshire, OX11 0SG. T 01235 822200.
participants (2)
-
Alan DeKok -
Stefan Paetow