c# - ASP.NET MVC RazorPDF save/download from database -


good time of day. i'm using asp.net mvc3 & razorpdf print view page in pdf example:

    // get: /razorpdf/pdf/     public actionresult pdf()     {         var model = repository.getstudents().tolist();          return new razorpdf.pdfresult(model, "pdf");     } 

it's print need exactly, don't understand best approach save/download pdf() into/from database (i'm use sql server 2012) in binding student. have ideas?

in general can use blob save binary data in db, i'm not sure if best approach. i'll save file on filesystem or external storage if using 1 , use link file downloads. think it'd easier , faster way, since don't need else download , server can serve pdf without app doing anything. easier implement caching, unique names (e.g guid). need string field in db store file name/path.


Comments