Inner Join Help

From: heboth (henrik_thystrup_at_hotmail.com)
Date: 10/31/04


Date: 31 Oct 2004 10:05:20 -0800

Hello,

Can someone help me with a SQL statement that returns either email
from Table A or email2 from Table B based on the following logic: if
the email is found in Table B then email2 is retuned/used from Table
B otherwise email is retuned/used from table A. I.E

Table A Table B
email="mail@mail.com" email="mail@mail.com"
email2="newmail@mail.com"

Here email2="newmail@mail.com" should be returned from query

Table A Table B
email="mail@mail.com" email="no@mail.com"
email2="newmail@mail.com"

Here email="mail@mail.com" from Tabel A should be returned from query

Thanks in advance

Cheers

Henrik



Relevant Pages

  • Re: Error using " in .open with ADODB.Recordset
    ... recordset but I'm getting hung up on the SQL statement. ... query that has a string as a condition. ... Dim mrk As String ...
    (microsoft.public.data.ado)
  • Re: expiration
    ... First what type of field are you applying the criteria against? ... You can try the following in a query. ... If you are trying to get just records with the License has expired within ... it is the actual SQL statement that is executed. ...
    (microsoft.public.access.queries)
  • Re: Same date range in main and sub form
    ... You need to concatenate together the parts to make up the SQL string ... it will look like the SQL statement you original ... Allen Browne - Microsoft MVP. ... well as the name of the query on which the form is based. ...
    (microsoft.public.access.forms)
  • Re: expiration
    ... If you are trying to get just records with the License has expired within ... In the Design view of the query ... This query is based off the existing employee database created by someone ... it is the actual SQL statement that is executed. ...
    (microsoft.public.access.queries)
  • Re: Scroll through records and get match
    ... Doug Steele, Microsoft Access MVP ... "User-defined type not defined" at Dim dbs As DAO.Database. ... that I posted is a select query. ... cannot use it to open an SQL statement that you generate via code. ...
    (microsoft.public.access.modulesdaovba)