You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: learn/getting_started/primary_key.mdx
+17-17Lines changed: 17 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -165,12 +165,12 @@ This error occurs when you add documents to an index for the first time and Meil
165
165
"indexUid": "books",
166
166
"status": "failed",
167
167
"type": "documentAdditionOrUpdate",
168
-
"canceledBy":null,
169
-
"details":{
170
-
"receivedDocuments":5,
171
-
"indexedDocuments":5
168
+
"canceledBy":null,
169
+
"details":{
170
+
"receivedDocuments":5,
171
+
"indexedDocuments":5
172
172
},
173
-
"error":{
173
+
"error":{
174
174
"message": "The primary key inference failed as the engine found 2 fields ending with `id` in their names: 'id' and 'author_id'. Please specify the primary key manually using the `primaryKey` query parameter.",
@@ -194,11 +194,11 @@ This error occurs when you add documents to an index for the first time and none
194
194
"status": "failed",
195
195
"type": "documentAdditionOrUpdate",
196
196
"canceledBy": null,
197
-
"details":{
197
+
"details":{
198
198
"receivedDocuments": 5,
199
199
"indexedDocuments": null
200
200
},
201
-
"error":{
201
+
"error":{
202
202
"message": "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.",
203
203
"code": "index_primary_key_no_candidate_found",
204
204
"type": "invalid_request",
@@ -217,16 +217,16 @@ This happens when your document id does not have the correct [format](#formattin
217
217
218
218
```json
219
219
{
220
-
"uid":1,
220
+
"uid":1,
221
221
"indexUid": "books",
222
222
"status": "failed",
223
223
"type": "documentAdditionOrUpdate",
224
224
"canceledBy": null,
225
-
"details":{
226
-
"receivedDocuments":5,
227
-
"indexedDocuments":null
225
+
"details":{
226
+
"receivedDocuments":5,
227
+
"indexedDocuments":null
228
228
},
229
-
"error":{
229
+
"error":{
230
230
"message": "Document identifier `1@` is invalid. A document identifier can be of type integer or string, only composed of alphanumeric characters (a-z A-Z 0-9), hyphens (-) and underscores (_).",
231
231
"code": "invalid_document_id",
232
232
"type": "invalid_request",
@@ -245,16 +245,16 @@ This error occurs when your index already has a primary key, but one of the docu
245
245
246
246
```json
247
247
{
248
-
"uid":1,
248
+
"uid":1,
249
249
"indexUid": "books",
250
250
"status": "failed",
251
251
"type": "documentAdditionOrUpdate",
252
252
"canceledBy": null,
253
-
"details":{
254
-
"receivedDocuments":1,
255
-
"indexedDocuments":null
253
+
"details":{
254
+
"receivedDocuments":1,
255
+
"indexedDocuments":null
256
256
},
257
-
"error":{
257
+
"error":{
258
258
"message": "Document doesn't have a `id` attribute: `{\"title\":\"Solaris\",\"author\":\"Stanislaw Lem\",\"genres\":[\"science fiction\"],\"price\":5.0.",
0 commit comments