summaryrefslogtreecommitdiff
path: root/storage/oqgraph
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mariadb.com>2019-08-14 20:27:00 +0400
committerAlexander Barkov <bar@mariadb.com>2019-08-14 20:27:00 +0400
commitafe6eb499d7d5d9b4ba9de5746e78b43f25e31a4 (patch)
tree8755d77c5aca99ddc5bafc874e5f550be85e6f45 /storage/oqgraph
parente86010f909fb6b8c4ffd9d6df92991ac079e67e7 (diff)
downloadmariadb-git-afe6eb499d7d5d9b4ba9de5746e78b43f25e31a4.tar.gz
Revert "MDEV-20342 Turn Field::flags from a member to a method"
This reverts commit e86010f909fb6b8c4ffd9d6df92991ac079e67e7. Reverting on Monty's request, as this change makes merging things from 10.5 to 10.2 much harder.
Diffstat (limited to 'storage/oqgraph')
-rw-r--r--storage/oqgraph/ha_oqgraph.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/storage/oqgraph/ha_oqgraph.cc b/storage/oqgraph/ha_oqgraph.cc
index f2a91b51663..20ebd49bd5d 100644
--- a/storage/oqgraph/ha_oqgraph.cc
+++ b/storage/oqgraph/ha_oqgraph.cc
@@ -335,13 +335,13 @@ int ha_oqgraph::oqgraph_check_table_structure (TABLE *table_arg)
if (!badColumn) if (skel[i].coltype != MYSQL_TYPE_DOUBLE && (!isLatchColumn || !isStringLatch)) {
/* Check Is UNSIGNED */
- if (!(*field)->is_unsigned()) {
+ if ( (!((*field)->flags & UNSIGNED_FLAG ))) {
badColumn = true;
push_warning_printf( current_thd, Sql_condition::WARN_LEVEL_WARN, HA_WRONG_CREATE_OPTION, "Column %d must be UNSIGNED.", i);
}
}
/* Check THAT NOT NULL isn't set */
- if (!badColumn) if ((*field)->flags() & NOT_NULL_FLAG) {
+ if (!badColumn) if ((*field)->flags & NOT_NULL_FLAG) {
badColumn = true;
push_warning_printf( current_thd, Sql_condition::WARN_LEVEL_WARN, HA_WRONG_CREATE_OPTION, "Column %d must be NULL.", i);
}
@@ -658,7 +658,7 @@ int ha_oqgraph::open(const char *name, int mode, uint test_if_locked)
if (strcmp(options->origid, (*field)->field_name.str))
continue;
if ((*field)->cmp_type() != INT_RESULT ||
- !((*field)->flags() & NOT_NULL_FLAG))
+ !((*field)->flags & NOT_NULL_FLAG))
{
fprint_error("Column '%s.%s' (origid) is not a not-null integer type",
options->table_name, options->origid);
@@ -683,7 +683,7 @@ int ha_oqgraph::open(const char *name, int mode, uint test_if_locked)
if (strcmp(options->destid, (*field)->field_name.str))
continue;
if ((*field)->type() != origid->type() ||
- !((*field)->flags() & NOT_NULL_FLAG))
+ !((*field)->flags & NOT_NULL_FLAG))
{
fprint_error("Column '%s.%s' (destid) is not a not-null integer type or is a different type to origid attribute.",
options->table_name, options->destid);
@@ -715,7 +715,7 @@ int ha_oqgraph::open(const char *name, int mode, uint test_if_locked)
if (strcmp(options->weight, (*field)->field_name.str))
continue;
if ((*field)->result_type() != REAL_RESULT ||
- !((*field)->flags() & NOT_NULL_FLAG))
+ !((*field)->flags & NOT_NULL_FLAG))
{
fprint_error("Column '%s.%s' (weight) is not a not-null real type",
options->table_name, options->weight);