Last active
December 12, 2015 04:28
-
-
Save dgellow/4714023 to your computer and use it in GitHub Desktop.
Microsoft Access database - Multiple inner join syntax - Module 151
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$query->SQL = "select a.id as id, a.prenom as prenom, a.nom as nom, a.pseudo as pseudo, a.email as email, | |
a.password as password, a.password_salt as password_salt, a.date_naissance as date_naissance, a.adresse as adresse, | |
a.date_inscription as date_inscription, a.date_modification, | |
b.nom as pays, b.indicatif as indicatif, | |
c.nom as ville, | |
d.nom as role, | |
e.num as npa, | |
f.nom as canton | |
from ((((t_utilisateur as a | |
inner join t_pays as b on a.fk_pays = b.id) | |
inner join (select t.id, t.nom from t_privilege as t) as d on a.fk_privilege = d.id) | |
inner join (select t.id, t.nom from t_ville as t) as c on a.fk_ville = c.id) | |
inner join (select t.id, t.num from t_npa as t) as e on a.fk_npa = e.id) | |
inner join (select t.id, t.nom from t_canton as t) as f on a.fk_canton = f.id"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment