Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

query para obtener todos los idiomas que habla un guia #68

Open
CarlosIrigoyen opened this issue May 7, 2024 · 0 comments
Open

query para obtener todos los idiomas que habla un guia #68

CarlosIrigoyen opened this issue May 7, 2024 · 0 comments

Comments

@CarlosIrigoyen
Copy link
Contributor

SELECT "Persona".*,
"Guia"."id" AS "Guia.id",
"Guia"."dias_trabaja" AS "Guia.dias_trabaja",
"Guia"."horario_trabaja" AS "Guia.horario_trabaja",
"Guia"."PersonaId" AS "Guia.PersonaId",
"Guia"."createdAt" AS "Guia.createdAt",
"Guia"."updatedAt" AS "Guia.updatedAt",
"Idiomas"."nombre" AS "Idiomas.nombre"
FROM (
SELECT "Persona"."id",
"Persona"."identificacion",
"Persona"."nombre",
"Persona"."apellido",
"Persona"."direccion",
"Persona"."localidad",
"Persona"."email",
"Persona"."fecha_nacimiento",
"Persona"."telefono",
"Persona"."createdAt",
"Persona"."updatedAt",
"Persona"."deletedAt"
FROM "Personas" AS "Persona"
WHERE "Persona"."identificacion" = '18236195'
AND "Persona"."deletedAt" IS NULL
ORDER BY "id" ASC
LIMIT 1
OFFSET 0
) AS "Persona"
LEFT OUTER JOIN "Guia" AS "Guia" ON "Persona"."id" = "Guia"."PersonaId"
AND "Guia"."deletedAt" IS NULL
LEFT OUTER JOIN "IdiomaGuia" AS "GuiaIdioma" ON "Guia"."id" = "GuiaIdioma"."GuiumId"
LEFT OUTER JOIN "Idiomas" AS "Idiomas" ON "GuiaIdioma"."IdiomaId" = "Idiomas"."id";

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant