23 #include <drizzled/message/schema.pb.h>
35 cout <<
"CREATE SCHEMA `" << schema->name() <<
"` ";
36 if (schema->has_collation())
37 cout <<
"COLLATE `" << schema->collation() <<
"` ";
39 for (
int option_nr=0; option_nr < schema->engine().options_size(); option_nr++)
41 cout <<
" " << schema->engine().options(option_nr).name() <<
" = "
42 <<
"'" << schema->engine().options(option_nr).state() <<
"'";
48 int main(
int argc,
char* argv[])
50 GOOGLE_PROTOBUF_VERIFY_VERSION;
53 cerr <<
"Usage: " << argv[0] <<
" SCHEMA" << endl;
61 fstream input(argv[1], ios::in | ios::binary);
62 if (!schema.ParseFromIstream(&input))
64 cerr <<
"Failed to parse schema." << endl;
TODO: Rename this file - func.h is stupid.