@nida123,
Please take a look at this example to render chart using data from the database in ASP.NET MVC.
Also, you can download this sample project for your reference, which uses ASP.NET and ORACLE as a database for rendering CanvasJS Chart.
___________
Indranil Deo,
Team CanvasJS