I use hardly the column prefix, so my query are always aliased.....
this obviously cause a lot of problem whith the order_by clause (that
NOT use the same aliases)
Is there some solution or mus wait for the new relase?
This is a tipical Example ...
the anagrafica.nome ORDER_BY column don't work.... bu SA know how to use
correclty the alias... beacause the ProgrammingError is correct.
SQLError: (ProgrammingError) invalid reference to FROM-clause entry for
table "anagrafica"
HINT: Perhaps you meant to reference the table alias "anon_f3fb".
SELECT
operatore.data_inizio_attivita AS operatore_data_inizio_attivita,
operatore.password AS operatore_password,
operatore.logname AS operatore_logname,
operatore.id_anagrafica AS operatore_id_anagrafica,
operatore.data_fine_attivita AS operatore_data_fine_attivita,
operatore.zoperoles AS operatore_zoperoles,
anon_4877.ts_ultima_modifica AS anon_4877_ts_ultima_modifica,
anon_4877.id AS anon_4877_id,
anon_4877.id_anagrafica AS anon_4877_id_anagrafica,
anon_4877.id_operatore AS anon_4877_id_operatore,
anon_4877.data_inizio AS anon_4877_data_inizio,
anon_4877.bdn_data_ultima_modifica AS anon_4877_bdn_data_ultima_modifica,
anon_4877.bdn_id AS anon_4877_bdn_id,
anon_4877.codice_struttura AS anon_4877_codice_struttura,
anon_4877.id_azienda AS anon_4877_id_azienda,
anon_4877.stato_record AS anon_4877_stato_record,
anon_4877.bdn_specie AS anon_4877_bdn_specie, anon_4877.id_precedente AS
anon_4877_id_precedente, anon_4877.bdn_flag_carne_latte AS
anon_4877_bdn_flag_carne_latte,
anon_4877.data_fine AS anon_4877_data_fine, operatore.id AS operatore_id,
anon_a2d6.codice AS anon_a2d6_codice,
anon_a2d6.descrizione AS anon_a2d6_descrizione,
anon_a2d6.group_id AS anon_a2d6_group_id,
anon_f3fb.cod_nazionalita AS anon_f3fb_cod_nazionalita,
anon_f3fb.id AS anon_f3fb_id, anon_f3fb.id_comune AS anon_f3fb_id_comune,
anon_f3fb.cod_professione AS anon_f3fb_cod_professione,
anon_f3fb.dato_fiscale AS anon_f3fb_dato_fiscale,
anon_f3fb.localita AS anon_f3fb_localita,
anon_f3fb.telefono AS anon_f3fb_telefono,
anon_f3fb.email AS anon_f3fb_email,
anon_f3fb.nome AS anon_f3fb_nome,
anon_f3fb.tipo AS anon_f3fb_tipo,
anon_f3fb.cod_titolo_studio AS anon_f3fb_cod_titolo_studio,
anon_f3fb.indirizzo AS anon_f3fb_indirizzo,
anon_f3fb.id_precedente AS anon_f3fb_id_precedente,
anon_f3fb.cod_nazione_nascita AS anon_f3fb_cod_nazione_nascita,
anon_f3fb.id_comune_nascita AS anon_f3fb_id_comune_nascita,
anon_f3fb.stato_record AS anon_f3fb_stato_record,
anon_f3fb.id_operatore AS anon_f3fb_id_operatore,
anon_f3fb.cap AS anon_f3fb_cap,
anon_f3fb.ts_ultima_modifica AS anon_f3fb_ts_ultima_modifica,
anon_f3fb.data_nascita AS anon_f3fb_data_nascita
FROM operatore LEFT OUTER JOIN azienda_veterinario AS anon_28bf ON
anon_28bf.id_veterinario = operatore.id
LEFT OUTER JOIN unita_aziendale AS anon_4877 ON anon_4877.id =
anon_28bf.id_unita_aziendale
LEFT OUTER JOIN acl AS anon_e91a ON operatore.id = anon_e91a.id_operatore
LEFT OUTER JOIN ruolo AS anon_a2d6 ON anon_a2d6.codice =
anon_e91a.cod_ruolo
LEFT OUTER JOIN anagrafica AS anon_f3fb ON anon_f3fb.id =
operatore.id_anagrafica
ORDER BY *_anagrafica.nome_*, anon_28bf.id, anon_e91a.id, anon_f3fb.id'
--
+------------------------------------------------------------+
Glauco Uri - Programmatore
glauco(at)allevatori.com
Sfera Carta Software(r) [EMAIL PROTECTED]
Via Bazzanese,69 Casalecchio di Reno(BO) - Tel. 051591054
+------------------------------------------------------------+
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---