473,396 Members | 1,706 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,396 software developers and data experts.

Access doubt

Hi,

I am new to access but i have some sql experience. Can you guys please help me with this:

I have two tables t1 and t2. t1 has a column c1 and t2 has c2 . c1 and c2 are almost same.I want all the records in t1 where the values c1 and c2 are equal.
i.e select * from t1 where c1=(select c2 from t2). How can i do this in access. Can you guys please guide me.
Aug 15 '07 #1
3 1038
mlcampeau
296 Expert 100+
Hi,

I am new to access but i have some sql experience. Can you guys please help me with this:

I have two tables t1 and t2. t1 has a column c1 and t2 has c2 . c1 and c2 are almost same.I want all the records in t1 where the values c1 and c2 are equal.
i.e select * from t1 where c1=(select c2 from t2). How can i do this in access. Can you guys please guide me.
Create a new query. You can either go to design view or sql view to create the query, but since you have experience with sql, you may find it easier to use the sql view. You can try:
Expand|Select|Wrap|Line Numbers
  1. SELECT * 
  2. FROM T1 RIGHT JOIN T2 ON T1.C1 = T2.C2;
If that doesn't give the correct results try a LEFT join instead.
Aug 15 '07 #2
Rabbit
12,516 Expert Mod 8TB
Actually, I think they need an INNER JOIN. I don't think they want all records from any one table, only the ones where they match up. So INNER JOIN rather than an OUTER JOIN.

And this is all SQL, Access has nothing to do with it.
Aug 15 '07 #3
mlcampeau
296 Expert 100+
Actually, I think they need an INNER JOIN. I don't think they want all records from any one table, only the ones where they match up. So INNER JOIN rather than an OUTER JOIN.

And this is all SQL, Access has nothing to do with it.
I understood it that he wanted all the records from table 1. But if he wants only the records that match up, then yes, an INNER JOIN would be correct. Thanks for adding that Rabbit.
Aug 15 '07 #4

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

Similar topics

17
by: chicha | last post by:
Hey people, I have to convert MS Access 2000 database into mysql database, the whole thing being part of this project I'm doing for one of my faculty classes. My professor somehow presumed I...
7
by: Ronnie | last post by:
I'm curious if anyone has any insights into what Microsoft has in store for ACCESS in current or future releases? I'm currently working on Access 2000 and haven't seen the newer versions. I'm...
49
by: Yannick Turgeon | last post by:
Hello, We are in the process of examining our current main application. We have to do some major changes and, in the process, are questionning/validating the use of MS Access as front-end. The...
12
by: dht | last post by:
I want to use an Access web form for people to submit data on the company intranet. I currently have one table ("New PRoducts") that I am using for new products and once that person has...
1
by: Jaspreet | last post by:
I am working on a code which is similar to the following snippet: #include <iostream> using namespace std; class def; class abc {
21
by: Gary Bond | last post by:
Hi All, I am a bit stuck with a project: Specifically, when making a database like engine in 'the old days', I would have wrapped a record class with a stream class, so I could have a file of...
37
by: jasmith | last post by:
How will Access fair in a year? Two years? .... The new version of Access seems to service non programmers as a wizard interface to quickly create databases via a fancy wizard. Furthermore, why...
3
by: Paul H | last post by:
Most of my projects are developed in Access 2003. I have not even installed Office 2007 yet! I need to buy VSTO to get the run-time licence for Access 2003. No doubt I will soon need a run-time...
15
by: chaseexchange | last post by:
First, a brief explanation of why this has happened. I purchased, what I thought, was a fully functional program written in Access last year from a local programmer. This program was to be used as...
5
by: Mahendra Kumar Kutare | last post by:
I am trying to implement a webserver with boss-worker model thread pool implementation - I have a header declaration threadpool.h as - typedef struct threadpool_work { void (*routine) ();...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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?
0
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...
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...
0
tracyyun
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...
0
agi2029
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 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.