{
  "id": 205777,
  "title": "UUID in Manticore: A Practical Guide",
  "url": "https://urgent.news/2026/08/06/uuid-in-manticore-a-practical-guide",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-08-06T05:20:04.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/sanikolaev/uuid-in-manticore-a-practical-guide-2foc"
  },
  "original_language": "en",
  "account": "In this article, we delve into the practical implementation of using UUIDs in Manticore Search, focusing on creating a table, executing SQL and JSON API operations, and loading documents through the /bulk endpoint. The examples provided are applicable to Manticore Search 28.5.0 or later.\n\nTo set UUID as the document ID, the field must be declared as id uuid in the table schema. The table definition for this example is CREATE TABLE products_uuid ( id uuid, title text, sku string, price int ).\n\nWhen working with UUID through SQL, inserting a product with a prebuilt UUID is done using the VALUES clause, enclosing the UUID in single quotes. The document can be retrieved using the SELECT statement with WHERE id = '...' condition. Manticore can also generate the UUID by omitting the id value during insertion. In this case, LAST_INSERT_ID() returns the UUID created by the request.\n\nTo insert multiple documents, use the @@session.last_insert_id variable. The example demonstrates adding a document with a known ID using IN condition and updating the price using UPDATE statement.\n\nChanging attributes through UPDATE does not affect the UUID itself. However, inserting a document with an already existing UUID results in a duplicate error. To create a new version of the document with the same UUID, REPLACE INTO clause can be used.\n\nDeleting a document is done by specifying the UUID in the WHERE clause of the DELETE statement. When performing SQL operations, the UUID is treated as a string, and it should be passed as a string parameter. The UUID is stored in lowercase, while Manticore returns it in lowercase in the response. Code written for a numeric document ID may require adjustment, as UUIDs are stored as strings.",
  "summary": "In the overview article we explained why it makes sense to use the same UUID in search and in the primary database, when one already exists. Here we will go straight to practice: create a table, run the core operations through SQL and the JSON API, and then load several documents through /bulk . All examples are for Manticore Search 28.5.0 or later. The <generated UUID> value in the responses…",
  "key_points": [],
  "editors_take": null,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}