What good would a database be if you couldn't read data from it?? It's a SELECT query.
There's millions upon millions of examples on this out there and more than a few different ways to do it.
ASPX is just a page from an ASP.NET application. A .cs file is a C# code file. There is no difference between doing this operation in an ASP.NET app and a normal Windows Forms app, either of which is written in C#.
Let me get you started wit ha simple Google query ->
"C# get data from database"[
^]