J
JDias5
Guest
I have created a form with a DataSet, which I connected to my database (.xsd). I confirmed that my database is well connected (in the .xsd, it is possible to fetch the table).
Then, I call, in my form code, the following routine:
public static List<AppDataModel> RetrieveTable(MY_DB_1DataSet dbDataSet, int month, int year, int[] rubricasQuery, int[] colaboratorsQuery)
{
IEnumerable<vDespesasExcelRow> ds = dbDataSet.vDespesasExcel.Where(l =>
l.Ano == year && l.Mes == month &&
colaboratorsQuery.Contains(l.colID) &&
rubricasQuery.Contains(l.ddDrID));
return ds.Select(l => new AppDataModel(l)).ToList();
}
However, this code didn't get any row from the table (which is vDespesasExcel). Is it missing something?
Even, when I set ds like
ds = dbDataSet.vDespesasExcel.Where(l => true);
the returning table has 0 rows...
Continue reading...
Then, I call, in my form code, the following routine:
public static List<AppDataModel> RetrieveTable(MY_DB_1DataSet dbDataSet, int month, int year, int[] rubricasQuery, int[] colaboratorsQuery)
{
IEnumerable<vDespesasExcelRow> ds = dbDataSet.vDespesasExcel.Where(l =>
l.Ano == year && l.Mes == month &&
colaboratorsQuery.Contains(l.colID) &&
rubricasQuery.Contains(l.ddDrID));
return ds.Select(l => new AppDataModel(l)).ToList();
}
However, this code didn't get any row from the table (which is vDespesasExcel). Is it missing something?
Even, when I set ds like
ds = dbDataSet.vDespesasExcel.Where(l => true);
the returning table has 0 rows...
Continue reading...