I would definitely appreciate any help with this problem as soon as possible. Thanks!
I have a report that should display the results of a query based on two tables (tblClient and tblResult, linked by ClientID).
When trying to open the report I receive the following error: "Data Type Mismatch in Criteria Expression"
The report worked before, so as an experiment I created a new table with a structure identical to tblResult (so I think). The data within is the only difference(it's actually the data that was in the table when I built the report). The report opens fine with this table.
So, my problem is why an error for one table and perfect operation for a splitting image? I've checked the fields, the data types, and the general table attributes - both tblResult's appear to be the same, yet one leads to an error and one leads to a report.
Thanks in advance.
3 6761
UPDATE: The cause of the error message is because I had several textboxes taking the average of certain fields from tblResults that are actually Text datatypes. BUT, my problem still exists - using one table as source, the report opens (with the averages calculating correctly), using another seemingly identical table, I get an error due to the average textboxes.
I would definitely appreciate any help with this problem as soon as possible. Thanks!
I have a report that should display the results of a query based on two tables (tblClient and tblResult, linked by ClientID).
When trying to open the report I receive the following error: "Data Type Mismatch in Criteria Expression"
The report worked before, so as an experiment I created a new table with a structure identical to tblResult (so I think). The data within is the only difference(it's actually the data that was in the table when I built the report). The report opens fine with this table.
So, my problem is why an error for one table and perfect operation for a splitting image? I've checked the fields, the data types, and the general table attributes - both tblResult's appear to be the same, yet one leads to an error and one leads to a report.
Thanks in advance.
To help clarify, here's what's going on:
1) I have an Excel spreadsheet with survey results data, some of which is "number stored as text" (responses are 1-5, N/A).
2) I imported this to Access as a new table (tblResults), then built the report I mentioned above.
3) The report opens fine.
4) I get a spreadsheet with new data but exact same format.
5) I imported this to Access as a new table (tblResults) to replace the old one.
6) The report doesn't open (giving a "Data Type Mismatch in Criteria Expression" error).
7) If I delete the textboxes taking the AVG of those fields whose data was "numbers stored as text" in Excel, the report opens.
8) Reimporting my original spreadsheet (old data) as tblResults, the report opens without having to delete the textboxes taking the AVG
9) I want to open the report with the textboxes taking the AVG!
Thanks, Martin
Problem solved.
The problem was due to the fact that my data had some null values and the functions I was using as control sources weren't set up to handle nulls.
Sometimes, it's the simple things in life.
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: mvargasp |
last post by:
Hi all,
I have a web form which contains a frame, (a form
containing a menu on the left and a web form containing a
datagrid on the right). Also there is a button (right
side) which transforms...
|
by: 21novembre |
last post by:
Hi all,
I made a question several days before to describe my strange trouble of
mysqldump. But I still can't figour it out. Well, I just want to ask
another question whether I could just backup...
|
by: s_gregory |
last post by:
The mdb is considerable size 70 +- mb. A complex union query was
working well, but when an additional union select... was added into
the query, selecting identical fields from a different source,...
|
by: RWC |
last post by:
Hello,
I'm getting the error "The field is too small to accept the amount of data
you attempted to add. Try inserting or pasting less data" when I run a
report. I'm simply trying to apply the...
|
by: David Reynolds |
last post by:
Hi Everybody,
I have a vb.net webform where I create the Excel
application/workbook/worksheet. On Windows 2000 server for some reason, I
keep getting an error("Bad variable type") when trying...
| |
by: rharding |
last post by:
I have a SQL database which contains a table (TblA) with a field (Fld1) defined as "bigint". When the SQL table is linked to Access the design view of the linked table shows this field as a data type...
|
by: jmarr02s |
last post by:
I am using MS Access 2003 and get the following error "Data type
mismatch in criteria expression"
Any suggestions on how to fix this?
This is my code:
SELECT IIf(=15 Or =19, "15 og 19",...
|
by: Davros9 |
last post by:
Trying to get Regular Expressions working.......
----------------
Public Function SepString(InField As String) As String
''seperates on space and comma
Dim RE As New RegExp
Dim Matches As...
|
by: dstorms |
last post by:
Hi,
I'm trying to create a button on a form that:
1. Takes the ComputerID from the form linked to Table 1,
2. Checks Table 2 for a matching ComputerID, and
3. Opens the query qryEditData, and...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...
| |