8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-22 16:43:03 +01:00

Fixed #8253 : Incorrect handling of non-ASCII object names in CREATE MAPPING statement

This commit is contained in:
Vlad Khorsun 2024-09-20 17:28:59 +03:00
parent a244ce67c9
commit c75b160dc0
3 changed files with 3 additions and 2 deletions

View File

@ -10870,6 +10870,7 @@ void MappingNode::runInSecurityDb(SecDbContext* secDbContext)
ddl += ' '; ddl += ' ';
if (from) if (from)
{ {
ddl += "_utf8 ";
addItem(ddl, fromUtf8.c_str(), '\''); addItem(ddl, fromUtf8.c_str(), '\'');
ddl += ' '; ddl += ' ';
} }

View File

@ -7804,7 +7804,7 @@ map_from_symbol_name
%type <intlStringPtr> map_logoninfo %type <intlStringPtr> map_logoninfo
map_logoninfo map_logoninfo
: sql_string : sql_string
| valid_symbol_name { $$ = newNode<IntlString>($1->c_str()); } | valid_symbol_name { $$ = newIntlString($1->c_str(), metadataCharSet->getName()); }
; ;
%type map_using(<mappingNode>) %type map_using(<mappingNode>)

View File

@ -5091,7 +5091,7 @@ static void printMap(bool extract, bool global, char* name, char* usng, char* pl
isqlGlob.printf("FROM %s", anyObj ? "ANY " : ""); isqlGlob.printf("FROM %s", anyObj ? "ANY " : "");
printIdent(extract, fromType, "%s "); printIdent(extract, fromType, "%s ");
if (!anyObj) if (!anyObj)
printIdent(extract, from, "%s "); isqlGlob.printf("\'%s\' ", from);
isqlGlob.printf("TO %s ", toType ? "ROLE" : "USER"); isqlGlob.printf("TO %s ", toType ? "ROLE" : "USER");
if (to) if (to)