I'm not sure if I was precise enought in my question so I'll explain the situation.
I got 2 tables in which I need to do an left outer join to get the data even where there's no match. I did a query which is working fine except for one discrimination in the where statement:
SELECT TableA.Type, SUM(TableB.HreReelles) AS HreReellesTotales, TableB.NoProjet_Short
FROM TableA
LEFT OUTER JOIN TableB ON TableA.IDType = TableB.IDType
WHERE TableA.Categorie = 'Electrique'
GROUP BY TableB.NoProjet_Short,TableA.Type
Now I realized I also needed to get only the record for a specific project BUT by keeping the all the "TableA.Type" from the OUTER JOIN even if there is no match in the other table. If I only add the "AND" statement, it removes them from the returned records. I'll post screenshot if necessary ;).
Oh and I'll need to put this in a OleDbCommand when finalized.
Thanks Simon
EDIT: Added picture. I don't need what's in red, but I need the rest including the empty cells (which comes from the LEFT OUTER JOIN).