Is FULLTEXT Search Possible in MySQL via FULLTEXT Index?

Hello everyone,

I am currently working on a project using Drizzle ORM with a MySQL database, and I'm looking to implement full-text search capabilities. While I am aware that MySQL supports FULLTEXT indexes (as detailed in their documentation: https://dev.mysql.com/doc/refman/8.0/en/fulltext-natural-language.html), I am uncertain about the integration of these features with Drizzle ORM.

My questions are as follows:

  1. Does Drizzle ORM support the creation of FULLTEXT indexes in line with MySQL's native capabilities? How can I define a FULLTEXT index on a column in my entity model using Drizzle ORM?
  2. If Drizzle ORM does not directly support FULLTEXT indexes, what are the recommended best practices or workarounds for implementing full-text search functionality with MySQL in a Drizzle ORM setup?
Any insights, code examples, or references to documentation would be immensely helpful. Additionally, I'm open to suggestions for alternative methods within the Drizzle ORM and MySQL framework if direct support for FULLTEXT indexes is not available.

Thank you for your assistance!
Was this page helpful?