42
40
#include <drizzled/data_home.h>
43
41
#include <drizzled/error.h>
44
42
#include <drizzled/table.h>
43
#include <drizzled/field/timestamp.h>
45
44
#include <drizzled/plugin/transactional_storage_engine.h>
47
46
#define my_strdup(a,b) strdup(a)
116
115
int doCommit(Session *, bool);
117
116
int doRollback(Session *, bool);
118
117
Cursor *create(Table& table);
119
bool doDropSchema(const drizzled::identifier::Schema&);
118
bool doDropSchema(const drizzled::SchemaIdentifier&);
122
121
* Indicates to a storage engine the start of a
140
int doCreateTable(Session&, Table&, const identifier::Table& ident, drizzled::message::Table& );
141
int doDropTable(Session &, const identifier::Table& );
143
int doRenameTable(Session&, const identifier::Table &from, const identifier::Table &to);
145
void doGetTableIdentifiers(drizzled::CachedDirectory &dir,
146
const drizzled::identifier::Schema &schema,
147
drizzled::identifier::Table::vector &set_of_identifiers)
139
int doCreateTable(Session&, Table&, const TableIdentifier& ident, drizzled::message::Table& );
140
int doDropTable(Session &, const TableIdentifier& );
142
int doRenameTable(Session&, const TableIdentifier &from, const TableIdentifier &to);
144
void doGetTableIdentifiers(drizzled::CachedDirectory &dir,
145
const drizzled::SchemaIdentifier &schema,
146
drizzled::TableIdentifiers &set_of_identifiers)
149
148
std::set<std::string> set_of_names;
151
150
doGetTableNames(dir, schema, set_of_names);
152
151
for (std::set<std::string>::iterator set_iter = set_of_names.begin(); set_iter != set_of_names.end(); ++set_iter)
154
set_of_identifiers.push_back(identifier::Table(schema, *set_iter));
153
set_of_identifiers.push_back(TableIdentifier(schema, *set_iter));
158
157
void doGetTableNames(CachedDirectory&,
159
const identifier::Schema &schema,
158
const SchemaIdentifier &schema,
160
159
std::set<std::string> &set_of_names)
162
161
bool isPBMS = schema.compare("PBMS");
170
169
int doReleaseSavepoint(Session *session, NamedSavepoint &savepoint);
171
170
const char **bas_ext() const;
173
int doGetTableDefinition(Session&, const identifier::Table &identifier,
172
int doGetTableDefinition(Session&, const TableIdentifier &identifier,
174
173
drizzled::message::Table &table_proto)
191
bool doDoesTableExist(Session&, const identifier::Table &identifier)
190
bool doDoesTableExist(Session&, const TableIdentifier &identifier)
193
192
const char *tab_name = identifier.getTableName().c_str();
194
193
const char *db_name = identifier.getSchemaName().c_str();
1047
1046
#ifdef DRIZZLED
1048
int PBMSStorageEngine::doCreateTable(Session&, Table&, const identifier::Table& , drizzled::message::Table& )
1047
int PBMSStorageEngine::doCreateTable(Session&, Table&, const TableIdentifier& , drizzled::message::Table& )
1050
1049
/* You cannot create PBMS tables. */
1051
1050
return( HA_ERR_WRONG_COMMAND );
1054
int PBMSStorageEngine::doDropTable(Session &, const identifier::Table& )
1053
int PBMSStorageEngine::doDropTable(Session &, const TableIdentifier& )
1056
1055
/* You cannot delete PBMS tables. */
1060
int PBMSStorageEngine::doRenameTable(Session&, const identifier::Table &, const identifier::Table &)
1059
int PBMSStorageEngine::doRenameTable(Session&, const TableIdentifier &, const TableIdentifier &)
1062
1061
/* You cannot rename PBMS tables. */
1063
1062
return( HA_ERR_WRONG_COMMAND );