I have a classes
class Images: NSObject {
var delegate: ImagesChangeDelegate?
var createdPhotoDate: Date?
var address: String?
var title: String?
var imagePath: String?
var latitude: Double = 0.00
var longitude: Double = 0.00
var likes = [Likes()]
var comments = [Comments()]
var objectId: String?
var ownerId: String?
var created: Date?
var updated: Date?
var photoRecordState = PhotoRecordState.New
var image: UIImage?
}
class Comments: NSObject {
var comment: String?
var objectId: String?
var ownerId: String?
var created: Date?
var updated: Date?
}
and when I want get related comments I call
func getCommentsFor(image: Images) {
let relQureyBuilder = LoadRelationsQueryBuilder.init(with: Comments().ofClass())
relQureyBuilder!.setGetRelationName(“comments”)
imagesStore = API.sharedInstance.backendless.data.of(Images.ofClass())
imagesStore?.loadRelations(image.objectId, queryBuilder: relQureyBuilder,
response: { (result) -> () in
if let comments = result as? [Comments] {
for comment in comments {
print(comment.comment ?? "ДБК")
}
}
}, error: { (fault) in
print(fault ?? "НО")
})
}
in response I get error
FAULT = ‘1010’ [Column Users does not exist] <Column Users does not exist>
I tried another variant of function getCommentsForImage
But I always get an error
FAULT = ‘1010’ [Column Users does not exist] <Column Users does not exist>
please healp, whats wrong?