Skip to main content
deleted 5 characters in body
Source Link
marc_s
  • 759.9k
  • 186
  • 1.4k
  • 1.5k

So I've been using the query builder in visual studio (visual basic) to search a local mdb file. I have a button that is clicked to make a prompt for a search, and it works fine except that is is not case sensitive. Here is what I have so far:

SELECT ID, LastName, FirstName, FullTime, HireDate, Salary

FROM SalesStaff

WHERE LastName like ? + '%'

SELECT ID, LastName, FirstName, FullTime, HireDate, Salary FROM SalesStaff WHERE LastName like ? + '%' 

My professor wants us to use the InStrInStr fuction, but how do I get that to work with a prompt?   

(InputBoxInputBox in my vb form code). FurthuremoreFurthermore, it doesn't seem to have case sensitivity either. This is the first time I am using SQL, so I hardly know what I'm doing.

Thanks in advance!

So I've been using the query builder in visual studio (visual basic) to search a local mdb file. I have a button that is clicked to make a prompt for a search, and it works fine except that is is not case sensitive. Here is what I have so far:

SELECT ID, LastName, FirstName, FullTime, HireDate, Salary

FROM SalesStaff

WHERE LastName like ? + '%'

My professor wants us to use the InStr fuction, but how do I get that to work with a prompt?  (InputBox in my vb form code). Furthuremore, it doesn't seem to have case sensitivity either. This is the first time I am using SQL, so I hardly know what I'm doing.

Thanks in advance!

So I've been using the query builder in visual studio (visual basic) to search a local mdb file. I have a button that is clicked to make a prompt for a search, and it works fine except that is is not case sensitive. Here is what I have so far:

SELECT ID, LastName, FirstName, FullTime, HireDate, Salary FROM SalesStaff WHERE LastName like ? + '%' 

My professor wants us to use the InStr fuction, but how do I get that to work with a prompt? 

(InputBox in my vb form code). Furthermore, it doesn't seem to have case sensitivity either. This is the first time I am using SQL, so I hardly know what I'm doing.

Thanks in advance!

Source Link
Genoe
  • 13
  • 5

case sensitive sql search in vb.net

So I've been using the query builder in visual studio (visual basic) to search a local mdb file. I have a button that is clicked to make a prompt for a search, and it works fine except that is is not case sensitive. Here is what I have so far:

SELECT ID, LastName, FirstName, FullTime, HireDate, Salary

FROM SalesStaff

WHERE LastName like ? + '%'

My professor wants us to use the InStr fuction, but how do I get that to work with a prompt? (InputBox in my vb form code). Furthuremore, it doesn't seem to have case sensitivity either. This is the first time I am using SQL, so I hardly know what I'm doing.

Thanks in advance!