diff --git a/lib/server-core/src/main/java/org/apache/olingo/server/core/serializer/json/MetadataDocumentJsonSerializer.java b/lib/server-core/src/main/java/org/apache/olingo/server/core/serializer/json/MetadataDocumentJsonSerializer.java index f3565403a..30efdf92a 100644 --- a/lib/server-core/src/main/java/org/apache/olingo/server/core/serializer/json/MetadataDocumentJsonSerializer.java +++ b/lib/server-core/src/main/java/org/apache/olingo/server/core/serializer/json/MetadataDocumentJsonSerializer.java @@ -851,7 +851,9 @@ public class MetadataDocumentJsonSerializer { private void appendDynamicExpression(JsonGenerator json, EdmDynamicExpression dynExp, String termName) throws SerializerException, IOException { - json.writeFieldName(termName); + if (termName != null) { + json.writeFieldName(termName); + } switch (dynExp.getExpressionType()) { // Logical case And: