-
Notifications
You must be signed in to change notification settings - Fork 84
Description
Hello @wog48 ,
I am having an issue with the $expand query. It is giving the following error:
"message": "The attribute [maskedAttribute] is not present in the managed type [EntityTypeImpl@randomHashCode:MaskedEntity [ javaType: class com.example.model.MaskedEntity descriptor: RelationalDescriptor(com.example.model.MaskedEntity --> [DatabaseTable(MASKED_TABLE)]), mappings: 12]]."
I'm using orable Database and the following dependencies
<processor.version>2.1.3</processor.version>
<java.version>17</java.version>
<build.sourceEncoding>UTF-8</build.sourceEncoding>
<eclipselink.version>4.0.3</eclipselink.version>
<jpa.version>3.1.0</jpa.version>
my main entity having a relationship
@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "MASKED_ATTRIBUTE")
public MaskedType getMaskedType() {
return this.maskedType;
}
I'm trying to expand the http://localhost:9010/Trippin/v1/MaskedEntity(-8)?$expand=MaskedType
in metadata I'm missing ReferentialConstraint for the navigation property.
when i dedugged into the source file.
com.sap.olingo.jpa.metadata.core.edm.mapper.impl
class
IntermediateModelElement
method
private Optional<CsdlReferentialConstraint> determineReferentialConstraint(
final IntermediateJoinColumn intermediateColumn) throws ODataJPAModelException, ODataJPAModelIgnoreException
line
sourceType.getPropertyByDBField(intermediateColumn.getName());
is getting null. if the join column field is not in the current class