14 Mar
2009
14 Mar
'09
1:26 a.m.
On Fri, 2009-03-13 at 16:18 -0700, Shane W wrote:
The problem may be the shane@ bit. If I delete the sql entry, the lookup just shows 'shane'. I'm not loging in with @ but my query does use the username,domain syntax for instances of virtual users which don't use passwd userdb: select username,domain,password from users WHERE username = '%n' AND domain = '%d'
Does the domain field contain an empty string instead of NULL? If so, I think the behavior is correct. Maybe change the query to:
where username = '%n' and (domain = '%d' or ('%d' = '' and domain is null))
And change all the domain='' to domain=NULL.