Hello, I have a query that if I run in SQL Maestro for SQL Lite returns a result of 8976 records. This is the same count as if I query SQL Server or MySQL with the same data. When I run this query though in .NET against the same SQL Lite database I get a result returned of 76 records. It's only bringing back one of the items in my IN clause. I've included the query, it uses a between and an IN. Additionally, I wrapped this query without the where clause in a view, then applied the where clause originally and the same thing occurs, I get 8976 in Maestro, but only 76 records in .NET. Please advise.
SELECT FACT_POS.CALENDAR_DT AS CALENDAR,
'My Retailer' AS RETAILER,
DIM_ITEM.UPC AS ITEMNUMBER,
DIM_ITEM.PRIMEITEMDESC AS ITEMDESCRIPTION,
DIM_STORE.STORENUMBER AS STORENUMBER,
0 AS INVENTORY,
FACT_POS.SLS_SOLD_DOLLARS AS DOLLARS,
FACT_POS.SLS_SOLD_QTY AS QUANTITY
FROM FACT_POS, DIM_ITEM, DIM_STORE
WHERE FACT_POS.Calendar_Dt BETWEEN '2008-08-01' AND '2008-10-15'
AND FACT_POS.Item_Id IN ('71803710450','71803711260','71803711526','71803711725','71803711769','71803711770','71803711771','71803711772','71803711867','71803711872','71803711873','71803711905','71803711943') AND DIM_ITEM.ITEM_ID = FACT_POS.ITEM_ID
AND DIM_STORE.STORE_ID = FACT_POS.STORE_ID