I have two tables:
Table 1:
centers machines
------- --------
center1 machine1
center2 machine2
center2 machine3
Table 2:
operation center1 center2 center3 ...
--------- ------- ------- ------- ...
oper1 ok ok
oper2 ok ok
oper3 ok
Selecting a machine (via combobox) from first table, puts me in a center. The operations from Table 2 are specific to each center as shown. So after selecting the machine from table one, passing the center value to a variable like "center" (by Executescalar() method) I want to do:
SELECT operation from dbo.operations where "center" != null
this should return the only the operations from table 2 which are specific to "center". Does anyone know how this can be achieved?