Manual:$wgAllowSysopQueries

Details
Set this to true to allow sysop queries. This is dangerous if not configured properly.