Go Back   Access World Forums > Microsoft Access Discussion > Reports

 
Reply
 
Thread Tools Rate Thread Display Modes
Old 08-13-2017, 03:22 AM   #1
Anticephalous
Newly Registered User
 
Join Date: Jun 2015
Location: Dubai, UAE
Posts: 29
Thanks: 4
Thanked 0 Times in 0 Posts
Anticephalous is on a distinguished road
Issue with Cross Tab Query

Dear Sirs,

I need your help please! I have an issue with report. Whenever the the field is empty the report won't open and will give me a message "The Microsoft office access database engine does not recognize 'fieldname' as a valid field name or expression"
Please refer to the attached screenshot of the report.
Attached Images
File Type: jpg Crosstab Report.jpg (100.0 KB, 16 views)

Anticephalous is offline   Reply With Quote
Old 08-13-2017, 03:31 AM   #2
ridders
AWF VIP
Gold Supporter
 
ridders's Avatar
 
Join Date: Jan 2017
Location: Somerset, UK
Posts: 2,034
Thanks: 36
Thanked 480 Times in 446 Posts
ridders will become famous soon enough ridders will become famous soon enough
Re: Issue with Cross Tab Query

Quote:
Originally Posted by Anticephalous View Post
Dear Sirs,

I need your help please! I have an issue with report. Whenever the the field is empty the report won't open and will give me a message "The Microsoft office access database engine does not recognize 'fieldname' as a valid field name or expression"
Please refer to the attached screenshot of the report.
There are lots of fields in your report & subreports.

You haven't said what you want to happen if 'the field' is empty e.g.
Open the report with that field blank?
Use a no data response?

The solution will depend on your requirements
__________________
Colin
Access 2010 32-bit, Access 2016 32-bit & 64-bit, SQL Server Express 2014, Windows 10,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
, Tapatalk


If this answer has helped, please click the Thanks button and/or click the 'reputation' scales symbol on the left and leave a comment. Cheers!
ridders is offline   Reply With Quote
Old 08-13-2017, 03:56 AM   #3
Anticephalous
Newly Registered User
 
Join Date: Jun 2015
Location: Dubai, UAE
Posts: 29
Thanks: 4
Thanked 0 Times in 0 Posts
Anticephalous is on a distinguished road
Re: Issue with Cross Tab Query

sorry.. do you have any idea why this is happening? If all the fields has data, the report opens up perfectly.

Anticephalous is offline   Reply With Quote
Old 08-13-2017, 04:00 AM   #4
ridders
AWF VIP
Gold Supporter
 
ridders's Avatar
 
Join Date: Jan 2017
Location: Somerset, UK
Posts: 2,034
Thanks: 36
Thanked 480 Times in 446 Posts
ridders will become famous soon enough ridders will become famous soon enough
Re: Issue with Cross Tab Query

You didn't answer the questions in my last post...

You're probably getting the error as there is no record in one or more of the record sources but without seeing the data all I can do is make an educated guess
__________________
Colin
Access 2010 32-bit, Access 2016 32-bit & 64-bit, SQL Server Express 2014, Windows 10,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
, Tapatalk


If this answer has helped, please click the Thanks button and/or click the 'reputation' scales symbol on the left and leave a comment. Cheers!
ridders is offline   Reply With Quote
Old 08-13-2017, 04:15 AM   #5
Anticephalous
Newly Registered User
 
Join Date: Jun 2015
Location: Dubai, UAE
Posts: 29
Thanks: 4
Thanked 0 Times in 0 Posts
Anticephalous is on a distinguished road
Re: Issue with Cross Tab Query

Is it possible to not include empty fields?
Anticephalous is offline   Reply With Quote
Old 08-13-2017, 05:01 AM   #6
ridders
AWF VIP
Gold Supporter
 
ridders's Avatar
 
Join Date: Jan 2017
Location: Somerset, UK
Posts: 2,034
Thanks: 36
Thanked 480 Times in 446 Posts
ridders will become famous soon enough ridders will become famous soon enough
Re: Issue with Cross Tab Query

You still haven't answered my questions....

But to answer yours, yes you can do that in one of two ways
1. Specify column headers in the report property sheet.
This works perfectly if the column headers are fixed e.g. Jan, Feb, Mar etc
2. Create a dynamic crosstab query where the column headers are assigned when the report is loaded

You will find info on both of these online or elsewhere in this forum.
I have posted more than one dynamic crosstabs report here including one in sample databases. Title is something like 'extended file properties using VBA'

Please note I am answering this on my phone and won't return to my computer for several hours.

If you need more assistance, you will need to supply more info.i

__________________
Colin
Access 2010 32-bit, Access 2016 32-bit & 64-bit, SQL Server Express 2014, Windows 10,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
,
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
, Tapatalk


If this answer has helped, please click the Thanks button and/or click the 'reputation' scales symbol on the left and leave a comment. Cheers!

Last edited by ridders; 08-13-2017 at 12:14 PM.
ridders is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Cross Tab Query - Cross Wired NauticalGent Queries 3 03-18-2016 09:21 AM
Cross tab query help deanaldo Queries 3 08-12-2009 02:15 AM
need help with cross tab query wilkob Queries 1 02-09-2005 07:33 AM
cross query referee Queries 2 01-04-2005 12:03 AM
Cross-tab Query and Report issue rosenn Reports 2 04-05-2003 08:34 AM




All times are GMT -8. The time now is 07:10 AM.


Microsoft Access Help
General
Tables
Queries
Forms
Reports
Macros
Modules & VBA
Theory & Practice
Access FAQs
Code Repository
Sample Databases
Video Tutorials

Sponsored Links

How to advertise

Media Kit


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World