Hi all.my first post here and hope to solve this problem before i lose it :-)I'm really struggling with CONTAINSTABLE.I have it working and Ranking as it should in MS SQL Query, but i want to be able to search on words, partial words and phrases. Help!This is the sql which works in ms sql querySELECT FT_TBL.ProductID, FT_TBL.Product, FT_TBL.Image, FT_TBL.Price, KEY_TBL.RANK, dbo.ClientProducts.ClientIDFROM dbo.Products AS FT_TBL INNER JOINCONTAINSTABLE(dbo.Products, Product, '"seaw*"') AS KEY_TBL ON FT_TBL.ProductID = KEY_TBL.[KEY] INNER JOINdbo.ClientProducts ON FT_TBL.ProductID = dbo.ClientProducts.ProductIDWHERE (dbo.ClientProducts.ClientID = 0) AND (KEY_TBL.RANK > 10)ORDER BY KEY_TBL.RANK DESC
This is the code in my classic ASP application.<%Dim RSResults__param5RSResults__param5 = "xxx"If (Request("searchme") <> "") Then RSResults__param5 = Request("searchme") End If%><%Dim RSResults__param6RSResults__param6 = "0"If (Application("ClientID") <> "") Then RSResults__param6 = Application("ClientID") End If%><%Set RSResults_cmd = Server.CreateObject ("ADODB.Command")RSResults_cmd.ActiveConnection = MM_shoppingcart_STRINGRSResults_cmd.CommandText = "SELECT FT_TBL.ProductID, FT_TBL.Product, FT_TBL.Image, FT_TBL.Price, KEY_TBL.RANK, dbo.ClientProducts.ClientID FROM dbo.Products AS FT_TBL INNER JOIN CONTAINSTABLE(dbo.Products, Product, ?) AS KEY_TBL ON FT_TBL.ProductID = KEY_TBL.[KEY] INNER JOIN dbo.ClientProducts ON FT_TBL.ProductID = dbo.ClientProducts.ProductID WHERE (dbo.ClientProducts.ClientID = ?) AND (KEY_TBL.RANK > 10) ORDER BY KEY_TBL.RANK DESC" RSResults_cmd.Prepared = trueRSResults_cmd.Parameters.Append RSResults_cmd.CreateParameter("param1", 200, 1, 255, RSResults__param5) ' adVarCharRSResults_cmd.Parameters.Append RSResults_cmd.CreateParameter("param2", 5, 1, -1, RSResults__param6) ' adDoubleSet RSResults = RSResults_cmd.ExecuteRSResults_numRows = 0%>How do i add the wildcard * to my search variable?I've tried everything i can think of.Hope someone can advise pleaseAndyPS Just to add to that, if i enter two words to search on, the apllication crashes with the error belowMicrosoft OLE DB Provider for SQL Server error '80040e14' Syntax error near 'book' in the full-text search condition 'recipe book'.