I am working with Spring MongoDB, and now I am faced with the problem of inserting values ββinto arraylist. Here is my POJO class class ...
public class Search implements Serializable { private static final long serialVersionUID = 1L; @Id private String id; private String searchkey; private ArrayList<Lead> leads; }
Lead is another POJO class that looks like ...
public class Lead implements Serializable { private static final long serialVersionUID = 1L; private String leadtext; private String address; private ArrayList<History> trackrecords; }
"History" is a POJO class that is similar to.
public class History implements Serializable { private static final long serialVersionUID = 1L; private String id; private String changedfield; private String oldvalue; private String newvalue; }
and the problem is that I want to insert data into the tracks while updating one of them. is this possible in Spring mongotemplate .. ?? if possible then please help me. Thank you in advance
source share