0
0 1
My database manages inventory for paint stores.
The mainform (frmStores) has two subforms. When the user selects a
paint brand in Subform A, a combo box on Subform B gets requeried and
shows only colors available for the selected brand.
I would like to further limit the combo box to show only colors (for
that brand) that have not already been added to the store's inventory
- i.e., the store/brand/color combination doesn't exist in
tblStoresBrandsColors.
tblStroresBrandsColors
------------------------
StoreID
BrandID
ColorID
The rowsource for the combo box is:
SELECT tblColors.ColorID, tblColors.ColorName, tblBrandsColors.BrandID
FROM tblColors
INNER JOIN tblBrandsColors
ON tblColors.ColorID = tblBrandsColors.ColorID
WHERE (((tblBrandsColors.BrandID)=[Forms]![frmStores]!
[fsubStoresBrands].[Form]![BrandID]));
Any idea how I can expand the WHERE clause to further limit the
values?
Thank you.
The mainform (frmStores) has two subforms. When the user selects a
paint brand in Subform A, a combo box on Subform B gets requeried and
shows only colors available for the selected brand.
I would like to further limit the combo box to show only colors (for
that brand) that have not already been added to the store's inventory
- i.e., the store/brand/color combination doesn't exist in
tblStoresBrandsColors.
tblStroresBrandsColors
------------------------
StoreID
BrandID
ColorID
The rowsource for the combo box is:
SELECT tblColors.ColorID, tblColors.ColorName, tblBrandsColors.BrandID
FROM tblColors
INNER JOIN tblBrandsColors
ON tblColors.ColorID = tblBrandsColors.ColorID
WHERE (((tblBrandsColors.BrandID)=[Forms]![frmStores]!
[fsubStoresBrands].[Form]![BrandID]));
Any idea how I can expand the WHERE clause to further limit the
values?
Thank you.