Creating a relation to an existing object - (iOS-Swift)

I am developing an iOS application with swift.
If I have one-to-one relation between classA and classB, and I create an instance of classA and want to create a relation to an existing instance of classB. I checked the documentation, it seems that I can’t do that.

say you have this class:

class classA : NSObject {

var b : classB?

}

Retrieve an instance of classB and do this:

let a = classA()
a.b = bObject;

then save “a”
backendless.data.save( a )

What’s the best approach for simply appending an object to a one-to-many relationship?
Thanks.

Hi Noahnrg22

See our documentation
https://backendless.com/documentation/data/ios/data_relations_save_update.htm

Regards, Vlad