public static VideoCollection SelectAll(SqlConnection con) { VideoCollection List = new VideoCollection(); using (IDataReader rd = SqlHelper.ExecuteReader(con, CommandType.StoredProcedure, "tblRss_sp_tblRssVideo_Select_SelectAll_linhnx")) { while (rd.Read()) { List.Add(getFromReader(rd)); } } return(List); }
public static VideoCollection SelectHome(SqlConnection con, int Top) { VideoCollection List = new VideoCollection(); SqlParameter[] obj = new SqlParameter[1]; obj[0] = new SqlParameter("Top", Top); using (IDataReader rd = SqlHelper.ExecuteReader(con, CommandType.StoredProcedure, "tblRss_sp_tblRssVideo_Select_SelectHome_linhnx", obj)) { while (rd.Read()) { List.Add(getFromReader(rd)); } } return(List); }
public static VideoCollection SelectByIdList(string V_ID, int Top) { VideoCollection List = new VideoCollection(); SqlParameter[] obj = new SqlParameter[2]; obj[0] = new SqlParameter("V_ID", V_ID); obj[1] = new SqlParameter("Top", Top); using (IDataReader rd = SqlHelper.ExecuteReader(DAL.con(), CommandType.StoredProcedure, "tblRss_sp_tblRssVideo_Select_SelectByIdList_linhnx", obj)) { while (rd.Read()) { List.Add(getFromReader(rd)); } } return(List); }