Locations of visitors to this page


Onteora Software - MySql

Onteora Software

Ken Tucker's Blog

About the author

Author Name is someone.
E-mail me Send mail

Recent comments

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2008

MySql Full Text searches

MySql Full Text searches



You must create a table that uses the MyISAM engine to support full text searches in MySql. Here is an example on how to create the table.



        conn = New MySqlConnection(strConn)

        conn.Open()
        Dim sbCmd As New System.Text.StringBuilder

        sbCmd.Append("Create Table If Not Exists MyBlog ")
        sbCmd.Append("(PostDate DateTime NOT NULL PRIMARY KEY, ")
        sbCmd.Append("BlogEntry Text, FullText(BlogText))")
        sbCmd.Append(" Engine = MyISAM")
        cmd = New MySqlCommand(sbCmd.ToString, conn)
        cmd.ExecuteNonQuery()
        conn.Close()

Use the MySql Match Against query to preform a full text search


Match Against Query Info

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Categories: MySql
Posted by Ken Tucker on Wednesday, July 27, 2005 12:25 PM
Permalink | Comments (0) | Post RSSRSS comment feed