mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-22 16:43:03 +01:00
* Fix both parts of #7924 * STL-compatible empty() method used * Get back to isEmpty()
This commit is contained in:
parent
541d4fe9da
commit
11dec10f9f
@ -8339,6 +8339,18 @@ void AlterRelationNode::modifyField(thread_db* tdbb, DsqlCompilerScratch* dsqlSc
|
||||
FLD.RDB$SEGMENT_LENGTH.NULL, FLD.RDB$SEGMENT_LENGTH);
|
||||
END_MODIFY
|
||||
|
||||
MODIFY RFR USING
|
||||
if (field->explicitCollation)
|
||||
{
|
||||
RFR.RDB$COLLATION_ID.NULL = FALSE;
|
||||
RFR.RDB$COLLATION_ID = field->collationId;
|
||||
}
|
||||
else
|
||||
{
|
||||
RFR.RDB$COLLATION_ID.NULL = TRUE; // CORE-2426 and Issue #7924
|
||||
}
|
||||
END_MODIFY
|
||||
|
||||
newDom.dyn_fld_source = origDom.dyn_fld_source;
|
||||
}
|
||||
else // Case b2: Domain -> internal domain.
|
||||
|
@ -276,8 +276,9 @@ void DDL_resolve_intl_type(DsqlCompilerScratch* dsqlScratch, dsql_fld* field,
|
||||
return;
|
||||
}
|
||||
|
||||
if (modifying)
|
||||
if (modifying && field->charSet.isEmpty() && field->collate.isEmpty())
|
||||
{
|
||||
// Use charset and collation from already existing field if any
|
||||
const dsql_fld* afield = field->fld_next;
|
||||
USHORT bpc = 0;
|
||||
|
||||
@ -310,10 +311,10 @@ void DDL_resolve_intl_type(DsqlCompilerScratch* dsqlScratch, dsql_fld* field,
|
||||
}
|
||||
}
|
||||
|
||||
if (!(field->charSet.hasData() || field->charSetId.has_value() || // set if a domain
|
||||
if (!modifying && !(field->charSet.hasData() || field->charSetId.has_value() || // set if a domain
|
||||
(field->flags & FLD_national)))
|
||||
{
|
||||
// Attach the database default character set, if not otherwise specified
|
||||
// Attach the database default character set to the new field, if not otherwise specified
|
||||
|
||||
MetaName defaultCharSet;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user