Sql: SQL_RENAME second try...

git-svn-id: svn://ultimatepp.org/upp/trunk@13963 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2020-02-01 10:49:50 +00:00
parent 74154d9dab
commit 3a70bbf65c
11 changed files with 96 additions and 75 deletions

View file

@ -53,21 +53,6 @@ String SqlId::Quoted() const
return id.ToString();
}
static SqlId *sLastSqlId;
SqlId::SqlId() { sLastSqlId = this; }
SqlId::SqlId(const char *s) : id(s) { sLastSqlId = this; }
SqlId::SqlId(const String& s) : id(s) { sLastSqlId = this; }
SqlId::SqlId(const Id& id) : id(id) { sLastSqlId = this; }
void SqlId::RenameLast(const char *s)
{
if(sLastSqlId) {
SqlId *h = sLastSqlId;
*h = s;
}
}
void SqlCompile(const char *&s, StringBuffer *r, byte dialect, Vector<SqlVal> *split)
{
char quote = dialect == MY_SQL ? '`' : '\"';