Hi Nisha,
I am just giving an example. In my case, I am trying show student name along with their exam result.
Create 1 non persistable entity for barchart. In my case, I have named it as BarChart. For stacked, select the bar mode as stacked.
In your page, Add dataview widget and select the Barchart entity.
Inside dataview, add bar chart widget.
In chart properties, I know that my data is from database and it is static. So I am defining my data like this
X- Axis will take Marks whereas Y axis will take student names.
I have defined my data series like this
Pass student data:
Similarly I have defined it for Fail result as well.
Final Result will be like this