nuttychick
Registered User.
- Local time
- Today, 23:17
- Joined
- Jan 16, 2004
- Messages
- 84
Good morning - hoping someone can shed some light on this one.
This is an Access 2003 database...
I have several queries that build up into one which I have then used to create a Crosstab Query.
All the sub queries run fine. But when I combine these with a crosstab I get the error
'The Microsoft Jet database engine does not recognize 'studies.study_id' as a valid field name or expression.
studies.study_id is a field in more than one of the sub queries, but is added just once in the final query.
The Crosstab part of the query works fine if I build it independant of other tables\queries etc...its when I start adding additional qry's in that it falls over...
Looking on the help I'm told to check that the Query Parameters are specified - but the study_id field does not have parameters set on any of the queries.
There is criteria set on other fields in the sub queries but these are permanent criteria to reduce the records retrieved...
Hoping someone has the answers, the only thing I can think of doing is making the crosstab section of the report export into a temporary table and use that in the final report...
Please help!
This is an Access 2003 database...
I have several queries that build up into one which I have then used to create a Crosstab Query.
All the sub queries run fine. But when I combine these with a crosstab I get the error
'The Microsoft Jet database engine does not recognize 'studies.study_id' as a valid field name or expression.
studies.study_id is a field in more than one of the sub queries, but is added just once in the final query.
The Crosstab part of the query works fine if I build it independant of other tables\queries etc...its when I start adding additional qry's in that it falls over...
Looking on the help I'm told to check that the Query Parameters are specified - but the study_id field does not have parameters set on any of the queries.

There is criteria set on other fields in the sub queries but these are permanent criteria to reduce the records retrieved...
Hoping someone has the answers, the only thing I can think of doing is making the crosstab section of the report export into a temporary table and use that in the final report...
Please help!
Code:
TRANSFORM Last(QryDataDump2.StatusDate) AS LastOfStatusDate
SELECT QryDataDump2.StudyID, QryDataDump2.[Study Code], QryDataDump2.[Business Unit], QryDataDump2.JDBCreationDate, QryDataDump2.study_title, QryDataDump2.study_description, QryDataDump2.OGD, QryDataDump2.LeadSupplier, QryDataDump2.[SDD Involvement], QryDataDump2.[Study Progress], QryDataDump2.PLine, QryDataDump2.SLine, QryDataDump2.Other, QryDataDump2.P01Value, QryDataDump2.ApprovedOBCCost, QryDataDump2.Rework, QryDataDump2.IMSPortfolioAreaName, QryDataDump2.[Current Status], QryDataDump2.[Current Status Date], QryDataDump2.QryDDStudyData.Working, QryDataDump2.StudyTypeApp, QryDataDump2.[Current RAG], QryDataDump2.[RAG Updated Date], QryDataDump2.[HMRC Program Area], QryDataDump2.Description, QryDataDump2.LastOfVRFDateID, QryDataDump2.LastOfVRFdate, QryDataDump2.LastOfLandingSlotID, QryDataDump2.LastOfLandingSlotDate, QryDataDump2.LastOfViabilityEndDateID, QryDataDump2.LastOfViabilityEndDate, QryDataDump2.LastOfITSuppPropIssDateID, QryDataDump2.LastOfITSuppPropIssDate, QryDataDump2.LastOfSellByDateID, QryDataDump2.LastOfSellByDate, QryDataDump2.LastOfIAGAppDateID, QryDataDump2.LastOfIAGAppDate, QryDataDump2.LastOfCommercialReviewId, QryDataDump2.LastOfCommercialReviewDate, QryDataDump2.LastOfProjectedImplementationID, QryDataDump2.LastOfProjectedImplementationDate, QryDataDump2.FirstOfVRFDateID, QryDataDump2.FirstOfVRFdate, QryDataDump2.FirstOfLandingSlotID, QryDataDump2.FirstOfLandingSlotDate, QryDataDump2.FirstOfViabilityEndDateID, QryDataDump2.FirstOfViabilityEndDate, QryDataDump2.FirstOfITSuppPropIssDateID, QryDataDump2.FirstOfITSuppPropIssDate, QryDataDump2.FirstOfSellByDateID, QryDataDump2.FirstOfSellByDate, QryDataDump2.FirstOfIAGAppDateID, QryDataDump2.FirstOfIAGAppDate, QryDataDump2.FirstOfCommercialReviewId, QryDataDump2.FirstOfCommercialReviewDate, QryDataDump2.FirstOfProjectedImplementationID, QryDataDump2.FirstOfProjectedImplementationDate, QryDataDump2.[First Proposal Issued], QryDataDump2.[First Proposal Issued Date], QryDataDump2.[Aspire Viability Study Manager], QryDataDump2.[HMRC Viability Study Manager], QryDataDump2.[SDD Bid Manager], QryDataDump2.LastOfOverall, QryDataDump2.LastOfDateRAGamended
FROM QryDataDump2
GROUP BY QryDataDump2.StudyID, QryDataDump2.[Study Code], QryDataDump2.[Business Unit], QryDataDump2.JDBCreationDate, QryDataDump2.study_title, QryDataDump2.study_description, QryDataDump2.OGD, QryDataDump2.LeadSupplier, QryDataDump2.[SDD Involvement], QryDataDump2.[Study Progress], QryDataDump2.PLine, QryDataDump2.SLine, QryDataDump2.Other, QryDataDump2.P01Value, QryDataDump2.ApprovedOBCCost, QryDataDump2.Rework, QryDataDump2.IMSPortfolioAreaName, QryDataDump2.[Current Status], QryDataDump2.[Current Status Date], QryDataDump2.QryDDStudyData.Working, QryDataDump2.StudyTypeApp, QryDataDump2.[Current RAG], QryDataDump2.[RAG Updated Date], QryDataDump2.[HMRC Program Area], QryDataDump2.Description, QryDataDump2.LastOfVRFDateID, QryDataDump2.LastOfVRFdate, QryDataDump2.LastOfLandingSlotID, QryDataDump2.LastOfLandingSlotDate, QryDataDump2.LastOfViabilityEndDateID, QryDataDump2.LastOfViabilityEndDate, QryDataDump2.LastOfITSuppPropIssDateID, QryDataDump2.LastOfITSuppPropIssDate, QryDataDump2.LastOfSellByDateID, QryDataDump2.LastOfSellByDate, QryDataDump2.LastOfIAGAppDateID, QryDataDump2.LastOfIAGAppDate, QryDataDump2.LastOfCommercialReviewId, QryDataDump2.LastOfCommercialReviewDate, QryDataDump2.LastOfProjectedImplementationID, QryDataDump2.LastOfProjectedImplementationDate, QryDataDump2.FirstOfVRFDateID, QryDataDump2.FirstOfVRFdate, QryDataDump2.FirstOfLandingSlotID, QryDataDump2.FirstOfLandingSlotDate, QryDataDump2.FirstOfViabilityEndDateID, QryDataDump2.FirstOfViabilityEndDate, QryDataDump2.FirstOfITSuppPropIssDateID, QryDataDump2.FirstOfITSuppPropIssDate, QryDataDump2.FirstOfSellByDateID, QryDataDump2.FirstOfSellByDate, QryDataDump2.FirstOfIAGAppDateID, QryDataDump2.FirstOfIAGAppDate, QryDataDump2.FirstOfCommercialReviewId, QryDataDump2.FirstOfCommercialReviewDate, QryDataDump2.FirstOfProjectedImplementationID, QryDataDump2.FirstOfProjectedImplementationDate, QryDataDump2.[First Proposal Issued], QryDataDump2.[First Proposal Issued Date], QryDataDump2.[Aspire Viability Study Manager], QryDataDump2.[HMRC Viability Study Manager], QryDataDump2.[SDD Bid Manager], QryDataDump2.LastOfOverall, QryDataDump2.LastOfDateRAGamended
PIVOT QryDataDump2.Status;