I have many-to-many relationship between User and Poll. While creating the relating class below I'm getting this warning on compile time:
warning: The column pollId in the junction entity com.example.appproject.model.user.UserPollCrossRef is being used to resolve a relationship but it is not covered by any index. This might cause a full table scan when resolving the relationship, it is highly advised to create an index that covers this column.
@Entity(primaryKeys = {"uid","pollId"})
public class UserPollCrossRef {
@NonNull
public String uid;
@NonNull
public String pollId;
public UserPollCrossRef(@NonNull String uid, @NonNull String pollId) {
this.uid = uid;
this.pollId = pollId;
}
}
I wanted to ask what does it mean and how can I fix it?