I have a weird issue which I totally not understand. Maybe I'm missing something.
var excel = new ExcelQueryFactory("products.xlsx");
//get all products with discount
var discounts = from s in excel.Worksheet() where
s["Discount/Premium"].Cast<string>().StartsWith("-") select s;
//Select products with a YTM higher than 3
var applicable = from b in discounts where
b["YTM"].Cast<double>() > 3.0 select b;
MessageBox.Show(discounts.Count().ToString()); //<- returns 51
MessageBox.Show(applicable.Count().ToString()); //<- returns 14826
products.xlsx got around 50'000 Rows/Products
There are 51 products with discounts
There are 14'000 products with "YTM > 3.0" - HOW can this be?
To my my knowledge, I'm searching YTM products in discounts. How can I get 14'000 products from 51?!? Am I missing something?
I have a weird issue which I totally not understand. Maybe I'm missing something.
products.xlsx
got around50'000
Rows/Products51
products with discounts14'000
products with "YTM > 3.0" - HOW can this be?To my my knowledge, I'm searching YTM products in discounts. How can I get 14'000 products from 51?!? Am I missing something?
Best regards, Julian