Hello everyone,
I try to search across the forum but I didn’t find what I’m looking for.
I have an external collection plugged on a AWS RDS MySQL database. Everything’s on green on my SQL Connector. When I query the schemas with CURL my connector I has the json response below :
{
"id": "wix_reparations",
"displayName": "wix_reparations",
"allowedOperations": [
"get",
"find",
"count",
"update",
"insert",
"remove",
"bulkRemove",
"bulkInsert",
"bulkUp
]
[...]
"wrep_brand": {
"displayName": "wrep_brand",
"type": "text",
"queryOperators": [
"eq",
"ne",
"contains",
"startsWith",
"endsWith",
"hasSome",
"matches",
"gt",
"gte",
"lt",
"lte",
"urlized",
"isEmpty",
"isNotEmpty"
]
},
Everything sounds good for me on this part. Then I create a dummy page, with a repeater, a title and connect the title to the field ‘wrap_brand’. Everything’s works.
So why when I run :
import wixData from 'wix-data';
$w.onReady(function () {
wixData.query("wix_reparations")
.eq("wrep_brand", "Apple")
.find()
.then((results) => {
if(results.items.length > 0) {
console.log(results.items[0]); //see firstItem below
} else {
console.log("NO ITEM FOUND")
}
})
.catch((err) => {
console.log(err);
});
});
I have this output in my console :
Error: WDE0025: The wix_reparations collection does not exist. You cannot work with a collection using the Data API before it is created in the Editor.
Thanks a lot in advance for your help,
Julien