I want to create list for get data form database because I have to select data with condition 600+ time form multiple table
and choose type form check box to show data form list to gridview
exe mydatabase
id name qty sale year type
1 a 2 4 2018 1
2 a 3 3 2019 1
3 a 1 1 2020 1
4 b 2 8 2028 2
5 b 3 7 2019 2
6 b 2 7 2020 2
7 c 6 4 2018 1
8 c 1 2 2019 1
9 c 8 4 2020 1
exe mysql
select qty form mydatabase where year 2018
select qty form mydatabase where year 2019
select qty form mydatabase where year 2020
select sale form mydatabase where year 2018
select sale form mydatabase where year 2019
select sale form mydatabase where year 2020
I want to create list for get like this
name qty2018 qty2019 qty2020 sale2018 sale2019 sale2020
a 2 3 1 4 3 1
b 2 3 2 8 7 7
c 6 1 8 4 2 4