Added conditional 'grave accents' outside capturing group to 'VAR_P1' regex matching variable name #3479

pull/3480/head
Javier Jaramago Fernández 5 years ago
parent 9f0caaaab0
commit 1f47834306

@ -34,7 +34,7 @@ std::map<std::string,std::vector<std::string>> SetParser::parse1() {
std::map<std::string,std::vector<std::string>> result;
#define SESSION_P1 "(?:|SESSION +|@@|@@session.)"
#define VAR_P1 "(@\\w+|\\w+)"
#define VAR_P1 "`?(@\\w+|\\w+)`?"
//#define VAR_VALUE "((?:[\\w/\\d:\\+\\-]|,)+)"
//#define VAR_VALUE "((?:CONCAT\\((?:(REPLACE|CONCAT)\\()+@@sql_mode,(?:(?:'|\\w|,| |\"|\\))+(?:\\)))|(?:[@\\w/\\d:\\+\\-]|,)+|(?:)))"
#define VAR_VALUE_P1 "((?:\\()*(?:SELECT)*(?: )*(?:CONCAT\\()*(?:(?:(?: )*REPLACE|IFNULL|CONCAT)\\()+(?: )*(?:NULL|@OLD_SQL_MODE|@@SQL_MODE),(?:(?:'|\\w|,| |\"|\\))+(?:\\))*)(?:\\))|(?:NULL)|(?:[@\\w/\\d:\\+\\-]|,)+|(?:(?:'{1}|\"{1})(?:)(?:'{1}|\"{1})))"

Loading…
Cancel
Save