mardi 23 mai 2017

ASP + C# How to display Checkboxes has value from DB using Search Parameter

ASP + C# + PostgreSQL

I have a checklist item where the user can select multiple checkbox.

The value of each checkbox is saved in the database separately.

I was able to successfully save this part in my DB.

My problem is.

For example in my db these are my checkboxes data.

checkbox_1 = 1;
checkbox_2 = 0;
checkbox_3 = 0;

[checkbox with value 1 is a checked checkbox]

Now I want to create a search query that if in my dropdown parameter I selected the name of checkbox_1

It should list all the items that has checkbox_1 - value = 1.

Thank you for your help!




Aucun commentaire:

Enregistrer un commentaire