public ActionResult Index() { try { var a = new Artistas { Nom_Artista = "artista", Dat_IniCarreira = new DateTime(1992, 01, 01), Num_SeqlGenero = 1, Cod_UsuaCad = 1, Dat_Cad = new DateTime(2015, 01, 01) }; var teste = new ArtistasRepository(); teste.PostArtista(a); return(View()); } catch (Exception e) { throw e; } }