• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 167
  • Last Modified:

Variable in an SQL query

Hi, i'm trying to do the following sql statement within a vb.net program:

Select ColumnName from Table where ColumnName = Variable

the Variable is the result of a combobox selection.
1 Solution
Dim varName as string="Value"

and then varName in a query as "@varName"

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now