I have a Visual Studio Form Called Form1
It is conencted to the Query_BuilderDataSet1 which retrive data from a Table tbl_Resources
On the Form1 i have the Grid from the Data set with contains the collumn ID_Resource , Name , Region, Town , Employer
From the Table adpter tbl_ResourceTableAdpter i have Open the Query Bulder and design a Query : SELECT ID_Resources , Name , Region , Town , Employer
FROM tbl_Resources
WHERE (Region=@Region OR @Region IS NULL ) AND (Emplyer =@Employer OR @Employer IS NULL )
For example i have inserted IS NULL thinking to have the possibility to Optionally insert only one of the 2 Parameters
But it is Not Working ,
When i Go on the Form1 and Fill only one of the 2 Text Box created by the VS designer
the Return into the Grid on Form1 is an Empty Grid
Any one that can help to write the SQL code or the Visual Basic code behing the Form1 to handle the Opition to have declared only 1 of the 2 Crtieria
For Clarity i have also u Button that on Click will remove the Query and will show again all the records
Thanks fro Help
it should read
Open in new window