1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Derived tables !

This commit is contained in:
Sinisa@sinisa.nasamreza.org
2002-03-26 15:06:05 +02:00
parent 8a7cd0e4df
commit 22d4f87e69
13 changed files with 208 additions and 12 deletions

View File

@ -659,15 +659,17 @@ class Table_ident :public Sql_alloc {
public:
LEX_STRING db;
LEX_STRING table;
SELECT_LEX *sel;
inline Table_ident(LEX_STRING db_arg,LEX_STRING table_arg,bool force)
:table(table_arg)
:table(table_arg), sel((SELECT_LEX *)0)
{
if (!force && (current_thd->client_capabilities & CLIENT_NO_SCHEMA))
db.str=0;
else
db= db_arg;
}
inline Table_ident(LEX_STRING table_arg) :table(table_arg) {db.str=0;}
inline Table_ident(LEX_STRING table_arg) :table(table_arg), sel((SELECT_LEX *)0) {db.str=0;}
inline Table_ident(SELECT_LEX *s) : sel(s) {db.str=0; table.str=(char *)""; table.length=0;}
inline void change_db(char *db_name)
{ db.str= db_name; db.length=(uint) strlen(db_name); }
};