it would help alot if you dump the table structure for us
  ----- Original Message ----- 
  From: Elisenda 
  To: [EMAIL PROTECTED] 
  Sent: Tuesday, November 11, 2003 7:10 PM
  Subject: Some help with a complex query


  I have a query which tries to select different fields from 5 different
  tables. 

  In WHERE part I have write all the conditions and relationships. Perhaps two
  many.....

  The main table for me is FASE. From this table I try to find all the other
  information.

  I guess I'm doing something wrong but I don't know what.

  SELECT 

  CE.CE_CENTRO, 
  CE.CE_DOMICILIO, 
  CE.CE_CP,
  CE.CE_POBLACION, 
  CE.CE_PROV, 
  PP.PP_CONTACTO, 
  PP.PP_CARGO, 
  CA.CA_HORARIO,
  AU.AU_A_M, 
  AU.AU_A_F, 
  FASE.PR_DATE_VISITA_1

  FROM AU, CA, CE,FASE,PP

  WHERE

  FASE.SQL_ID_PY='P081' AND
  FASE.PR_FLAG= '1' AND
  CA.CA_ID_IDIOMA_A= '6' AND
  AU.AU_NIVEL= '13.14' AND
  AU.AU_Aula= fase.AU_PR_Aula AND
  AU.AU_ID_CE = CA.CA_ID_CE AND
  CE.CE_ID_CE = CA.CA_ID_CE AND
  CE.CE_ID_CE = Fase.SQL_ID_CE AND
  CE.CE_ID_CE = PP.PP_ID_CE AND
  Fase.PR_PP_ID_Coord = PP.PP_ID_PP


  Thank you fro your help in advanced.

  Eli


  -- 
  MySQL General Mailing List
  For list archives: http://lists.mysql.com/mysql
  To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]


Reply via email to