[tarantool-patches] Re: [PATCH v1 1/2] sql: introduce pragma sql_default_engine
Kirill Shcherbatov
kshcherbatov at tarantool.org
Wed Jun 27 18:59:59 MSK 2018
> Hello. Thanks for the fixes!
Thank you for review,
> Please, put _strs here as extern and declare it in schema_def.c
> like it is done for other enum + _strs pairs (enum + extern strs in
> a header and declaration in source).
diff --git a/src/box/schema_def.c b/src/box/schema_def.c
index 97c074a..cbfad47 100644
--- a/src/box/schema_def.c
+++ b/src/box/schema_def.c
@@ -30,6 +30,11 @@
*/
#include "schema_def.h"
+const char *sql_storage_engine_strs[] = {
+ [SQL_STORAGE_ENGINE_MEMTX] = "memtx",
+ [SQL_STORAGE_ENGINE_VINYL] = "vinyl",
+};
+
static const char *object_type_strs[] = {
/* [SC_UKNNOWN] = */ "unknown",
/* [SC_UNIVERSE] = */ "universe",
diff --git a/src/box/schema_def.h b/src/box/schema_def.h
index e6a7206..5ab4bb0 100644
--- a/src/box/schema_def.h
+++ b/src/box/schema_def.h
@@ -250,6 +250,8 @@ enum sql_storage_engine {
sql_storage_engine_MAX = 2
};
+extern const char *sql_storage_engine_strs[];
> On the branch I got these errors:
This is non-related problem of trigger's branch (that is my HEAD).
believe, I've already fixed it there. Rebased.
More information about the Tarantool-patches
mailing list