PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → Etats & Requêtes → AIDE SUR UNE REQUETTE
AIDE SUR UNE REQUETTE
Débuté par Noel, 16 déc. 2014 15:46 - 1 réponse
Posté le 16 décembre 2014 - 15:46
Select DISTINCT (a.nom_commune),a.nom_sect ,a.nom_pharma ,a.Numero,a.location from (SELECT CONCAT(Date_debut,'',Date_Fin) as DATE from garde ,semaine WHERE IDSemaine = 1 and garde.IDSemaine =semaine.IDSemaine)g left OUTER JOIN ( SELECT pharmacie.id_pharma,pharmacie.nom_pharma,commune.id_cummune,secteur.nom_sect from pharmacie,commune,secteur WHERE pharmacie.idcommune = commune.id_commune and secteur.idcommune = commune.id_commune ORDER BY pharmacie.idcommune) ON a.idpharma = g.IDPharmacie

je reçois comme erreur
#1248 - Every derived table must have its own alias
Posté le 10 mars 2015 - 15:53
y a pas un espace entre Alias g ?:
SELECT CONCAT(Date_debut,'',Date_Fin) as DATE from garde ,semaine WHERE IDSemaine = 1 and garde.IDSemaine =semaine.IDSemaine)g