SQLTeam.com | Weblogs | Forums

Column(SubCategoryID) was used in a CALC expression but is not defined in the rowset


Receiving the error in the Topic when using Access 2010 and 2003 SQL when viewing a form. Access2003 does not have the same problem.

I believe it is an issue with the following Query on the form:

SELECT PO_Part_SubCategory.SubCategoryID, PO_Part_Category.CategoryDesc + N' / ' + PO_Part_SubCategory.SubCategoryDesc AS d,
PO_Part_SubCategory ON PO_Part_Category.CategoryID = PO_Part_SubCategory.Category
ORDER BY PO_Part_Category.CategoryDesc, PO_Part_SubCategory.SubCategoryDesc


The error indicates that field SubCategoryID is not present in table (PO_Part_SubCategory as this is what you reference in select statement).

I'm guessing you want to display field CategoryID from either table, as this is the field you use when joining.