MXS-1043: Handle @@identity like @@last_insert_id
The type of @@identity, @@last_insert_id and last_insert_id() is now the same, that is, QUERY_TYPE_READ|QUERY_TYPE_MASTER_READ.
This commit is contained in:
@ -833,7 +833,15 @@ static void update_field_infos(QC_SQLITE_INFO* info,
|
||||
}
|
||||
else
|
||||
{
|
||||
info->types |= QUERY_TYPE_SYSVAR_READ;
|
||||
if ((strcasecmp(&zToken[2], "identity") == 0) ||
|
||||
(strcasecmp(&zToken[2], "last_insert_id") == 0))
|
||||
{
|
||||
info->types |= QUERY_TYPE_MASTER_READ;
|
||||
}
|
||||
else
|
||||
{
|
||||
info->types |= QUERY_TYPE_SYSVAR_READ;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
|
Reference in New Issue
Block a user