n = folder.foldConstants(n);
// Set nullability of TInstance if it hasn't been given explicitly
// At the same time, update the node's DataTypeDescriptor to match its TInstance
TPreptimeValue tpv = n.getPreptimeValue();
if (tpv != null) {
TInstance type = tpv.type();
if ((n.getSQLtype() != null) &&
(n.getSQLtype().getCharacterAttributes() != null) &&
(n.getSQLtype().getCharacterAttributes().getCollationDerivation() ==
CharacterTypeAttributes.CollationDerivation.EXPLICIT)) {
// Apply result of explicit COLLATE, which will otherwise get lost.