can u tell me how to find a part of string using an sql..
Dim inp As String

inp = InputBox("Enter the Search Term")
exec ("select * from solution_database where search_term like '" + inp+ "' ")

i want to get the records whose search_trem contains the string "inp" which is a part of search_trem(a column in my table)

i'm not able to use inp*
can u plz tell me

Hi

open a Connection(Cn), and use this code:

dim RST As New ADODB.RecordSet
Dim sSQL As String
sSQL="Select * From MyTable Where UCASE(FName) Like '*" & ucase(text1.text)  & "*'"
Set RST =Nothing
RST.Open sSQl,Cn
IF RST.EOF Then
  MsgBox  "Records Not Found"
Else
  MsgBox "Record Found"
End IF

REgards
Veena

"select * from solution_database where ucase(search_term) like '*" + UCase(Text4.Text) + "*'"

itz not working

"select * from solution_database where ucase(search_term) like '*" + UCase(Text4.Text) + "*'"

itz not working

Hi,

what is ur back end..?
the above works for Access. Replace * with % for other db's

what is the field name ...? search_term..?
What is Solution_database...? table name..?


Regards
Veena

yeah.. i'm using access..
search_term is field name and solution_database is table name