473,386 Members | 1,883 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Query Problem

trueadvantage
Hi... I have 1 little but critical (for me) problem regarding access query.

Problem Details: -

I have one table which includes Employee Name and Employee ID

Table:-

EmpName EmpID
A 11
B 12
C 11
D 13
E 12
F 14
G 14
H 15
I 16

If you look at above table, u will come to know that some employee has got same emp numbers.

I want to build a query which will help me to find out those emp names who got same empid.

if anybody understand my problem so please send me query.

Thnnx in advance
Feb 7 '08 #1
4 1473
MindBender77
234 100+
Hi... I have 1 little but critical (for me) problem regarding access query.

Problem Details: -

I have one table which includes Employee Name and Employee ID

Table:-

EmpName EmpID
A 11
B 12
C 11
D 13
E 12
F 14
G 14
H 15
I 16

Thnnx in advance
A "Find Duplicates" query like this might help.
Expand|Select|Wrap|Line Numbers
  1. SELECT YourTable.EmpID, YourTable.[Employee Name]
  2. FROM YourTable
  3. WHERE (((YourTable.EmpID) In (SELECT [EmpID] FROM [YourTable] As Tmp GROUP BY [EmpID] HAVING Count(*)>1 )))
  4. ORDER BY YourTable.EmpID;
  5.  
JS
Feb 7 '08 #2
NeoPa
32,556 Expert Mod 16PB
I'm sure you must be confused by the answers you're receiving, but please don't simply post the question again. Ask for clarification.

Most of our experts understand that not everyone can be Access or SQL experts. Just let us know what you don't understand and we can clarify further.

The Simple SQL Problem thread has pretty well the same question and a very similar answer in it.

Do you understand the answer now?
If not, what do you still need to know?
Feb 7 '08 #3
I'm sure you must be confused by the answers you're receiving, but please don't simply post the question again. Ask for clarification.

Most of our experts understand that not everyone can be Access or SQL experts. Just let us know what you don't understand and we can clarify further.

The Simple SQL Problem thread has pretty well the same question and a very similar answer in it.

Do you understand the answer now?
If not, what do you still need to know?

Hi,

I have run the query as per your and others suggesion. But still im not able to run this query. it shown same error. thats y i putted same threads with all details.

Thanks,
Feb 8 '08 #4
NeoPa
32,556 Expert Mod 16PB
OK.
But that won't help you much. All you'll get is irritated responses from the people trying to help you.

What I'd like to see in here now is the actual SQL code you're using, and a brief explanation of what's actually happening.
Does it run but give incorrect results for instance?
Does it throw up an Access Error Message of some sort (if so provide this of course)?

I suspect we can help you, but you need to co-operate with us ok.
Feb 8 '08 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

13
by: Wescotte | last post by:
Here is a small sample program I wrote in PHP (running off Apache 1.3.31 w/ PHP 5.0.1) to help illustrates problem I'm having. The data base is using DB2 V5R3M0. The client is WinXP machine using...
3
by: Brian Oster | last post by:
After applying security patch MS03-031 (Sql server ver 8.00.818) a query that used to execute in under 2 seconds, now takes over 8 Minutes to complete. Any ideas on what the heck might be going...
1
by: Jeff Blee | last post by:
I hope someone can help me get this graph outputing in proper order. After help from Tom, I got a graph to display output from the previous 12 months and include the average of that output all in...
8
by: Adam Louis | last post by:
I would like help resolving this problem. I'm a novice who's been hired to query a hospital database and extract useful information, available to me only in a dynamically generated, downloadable...
6
by: Martin Lacoste | last post by:
Ok, before I headbutt the computer... don't know why when I add criteria in a query, I get an 'invalid procedure call'. I also don't know why after searching the help in access, the various access...
4
by: Apple | last post by:
1. I want to create an autonumber, my requirement is : 2005/0001 (Year/autonumber), which year & autonumber no. both can auto run. 2. I had create a query by making relation to a table & query,...
11
by: Andy_Khosravi | last post by:
My problem: I'm having trouble with a query taking much too long to run; a query without any criteria evaluating only 650 records takes over 300 seconds to run (over the network. On local drive...
4
by: Konrad Hammerer | last post by:
Hi! I have the following problem: I have a query (a) using another query (b) to get the amount of records of this other query (b), means: select count(MNR) as Number from...
4
by: Stan | last post by:
I am using MS Office Access 2003 (11.5614). My basic question is can I run a query of a query datasheet. I want to use more that one criteria and can not get that query to work. I thought I...
2
by: existential.philosophy | last post by:
This is a new problem for me: I have some queries that open very slowly in design view. My benchmark query takes about 20 minutes to open in design view. That same query takes about 20 minutes...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
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...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
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,...
0
Oralloy
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,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.