I am using the following expression in an access query. The goal is to count from tblAttedance how many times a particular employee (eid) is present (present = yes) for a particular type of event (SDY). Can someone please help? All I keep getting is #Error!! -
-
DCount("tblAttendance_present","tblAttendance","tblAttendance_eID = " & [tblEmployees.tblEmployees_eID] & "AND tblAttendanceType = 'SDY' AND tblAttendance_present = 'Yes'")
-
-
Thank you!!!!
Looks to me that there are two problems in your WHERE clause: incorrect bracketing of the first field name (a dot in the middle of the bracketing), and a missing space before the first AND operator. Assuming that the field name in the first part is tblEMployees_eID the syntax should be: - DCount("tblAttendance_present","tblAttendance","tblAttendance_eID = " & [tblEmployees].[tblEmployees_eID] & " AND tblAttendanceType = 'SDY' AND tblAttendance_present = 'Yes'")
-Stewart
3 1655
Looks to me that there are two problems in your WHERE clause: incorrect bracketing of the first field name (a dot in the middle of the bracketing), and a missing space before the first AND operator. Assuming that the field name in the first part is tblEMployees_eID the syntax should be: - DCount("tblAttendance_present","tblAttendance","tblAttendance_eID = " & [tblEmployees].[tblEmployees_eID] & " AND tblAttendanceType = 'SDY' AND tblAttendance_present = 'Yes'")
-Stewart
I confused as to why you're using a DCount rather than a join.
Thank you! It is now working as -
DCount("tblAttendance_present","tblAttendance","tblAttendance_eID = " & [tblEmployees.tblEmployees_eID] & "AND tblAttendance_Type = 'SDY' AND tblAttendance_present = Yes")
-
This is working beautifully. I'm afraid I got a little too ahead of myself in asking this question before I was completely out of options. I'm sorry. Thank you for the help!
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Feverish |
last post by:
I am a bit confused with the two marked lines. I have never seen such syntax
even though I read a lot
of C++ codes.
Thanks for your suggestion...
BluetoothReceiver::BluetoothReceiver()
:...
|
by: ichor |
last post by:
hi i have nt come acroos this syntax in OOP .
can you plz explain what this means?
public FormsView(DataInstance dataInstance): base(dataInstance)
this is a constructor.
thnx
|
by: lovecreatesbea... |
last post by:
K&R2 sec 8.7 reads:
union header{
/*...*/
};
typedef union header Header;
/*...*/
Header *morecore(unsigned); /*?*/
|
by: avocado12 |
last post by:
Hi,
I'm sure this is very basic but it's difficult to google or search for because I'm searching for ":". Can anyone explain or point me to a reference for the ":" operator used in Javascript?...
|
by: Giuseppe:G: |
last post by:
Hi, the following piece of code is rather obscure for me
struct Foo
{
Foo( int _x ) : x(_x) {}
....
};
what's the meaning of that construct? I understand Foo() must be a
constructor,...
|
by: campyhapper |
last post by:
I've seen this in C++, not Objective C:
namespace bar {
struct foo {
foo (int a, int b) :
int a_,
int b_
{}
};
}
|
by: =?Utf-8?B?SmVzcGVyLCBEZW5tYXJr?= |
last post by:
double c = double.NaN;
Console.WriteLine(c = 10);
Console.WriteLine(c += 5);
Console.WriteLine(c);
output:
10
15
15
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
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: 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,...
| |