Hello ,
I am using the Java/Android api. I am saving restaurant data, geo point and then linking them
GeoPoint geo = new GeoPoint();
geo.setLatitude(latValue);
geo.setLongitude(lngValue);
geo = Backendless.Geo.savePoint( geo );
ArrayList location = new ArrayList();
location.add( geo );try { Map ret1 = Backendless.Data.of("Restaurant").save(restaurentHM); if (ret1 == null) { return false; } int ret2 = Backendless.Data.of("Restaurant").setRelation(restaurentHM, "GeoLocation:GeoPoint:1", location); if (ret2 != 1) { return false; }
However I am receiving this error in the relation code. I verified on the server and the restaurant data and the geo point are there. They are not linked
The error I am getting is:
BackendlessException{ code: ‘Server.Processing’, message: ‘java.lang.RuntimeException: java.lang.NullPointerException’, extendedData: ‘{}’, detail: ‘java.lang.RuntimeException: java.lang.NullPointerException’ }