Moved limit-related assertions to SQL functions
SQL functions a will raise exeption if given limit is invalid
Type of _LIMIT has to be changed, so exception messages generated by SQL, matches theese in patterns
SQL functions a will raise exeption if given limit is invalid
Type of _LIMIT has to be changed, so exception messages generated by SQL, matches theese in patterns