Closed Laganer closed 4 years ago
I've just tested the example you're probably referring to (https://cpp.objectbox.io/getting-started) and it worked for me - I've got no error.
Could you maybe zip the whole directory you've tried this in and attach it to the issue? So I can try to run the exact same code.
Also, what platform and compiler are you using? uname -a
and g++ --version
Thanks for your reply !
I've just tested the example you're probably referring to (https://cpp.objectbox.io/getting-started) and it worked for me - I've got no error.
Could you maybe zip the whole directory you've tried this in and attach it to the issue? So I can try to run the exact same code? Also, what platform and compiler are you using? uname -a and g++ --version
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
Looks like the getting-started page answered the questions. Feel free to follow-up in case there's still an issue.
when I compile the example by running: g++ main.cpp -I. -std=c++11 -lobjectbox error:no matching function for call to 'obx::Box::put()
obx_id id = box.put({.text = "Buy milk"}) ^
int main() { obx::Store store(create_obx_model()); obx::Box box(store);
std::unique_ptr task = box.get(id); // Read
if (task) {
task->text += " & some bread";
box.put(*task); // Update
box.remove(id); // Delete
}
return 0;
}