|
|
Hello from the address book and add a custom field called 'CAMPUS', then I went to the address book and the column appeared to me as 'CAMPUS', to click on this I get this message from the database and I no longer can see the address book but I could help.
Database error Invalid SQL: SELECT DISTINCT egw_addressbook.*,contact_value<>'' FROM egw_addressbook LEFT JOIN egw_addressbook_extra extra_order ON egw_addressbook.contact_id=extra_order.contact_id AND extra_order.contact_name='CAMPUS' WHERE contact_tid='n' AND (egw_addressbook.contact_owner=11 OR contact_private=0 AND egw_addressbook.contact_owner IN (-1,11,0) OR egw_addressbook.contact_owner IS NULL) ORDER BY extra_order.contact_value<>'' DESC,extra_order.contact_value ASC,org_name ASC,n_family ASC,n_given ASC: ERROR: for SELECT DISTINCT, ORDER BY expressions must appear in the list of results |
|
Leithoff, Klaus |
|
|
cannot reproduce that. recent trunk?
----------------ursprüngliche Nachricht----------------- Von: "Estrella9" [hidden email] An: [hidden email] Datum: Tue, 27 Apr 2010 08:48:23 -0700 (PDT) ------------------------------------------------- > > Hello from the address book and add a custom field called 'CAMPUS', then I > went to the address book and the column appeared to me as 'CAMPUS', to click > on this I get this message from the database and I no longer can see the > address book but I could help. > > > Database error > > Invalid SQL: SELECT DISTINCT egw_addressbook.*,contact_value<>'' FROM > egw_addressbook LEFT JOIN egw_addressbook_extra extra_order ON > egw_addressbook.contact_id=extra_order.contact_id AND > extra_order.contact_name='CAMPUS' WHERE contact_tid='n' AND > (egw_addressbook.contact_owner=11 OR contact_private=0 AND > egw_addressbook.contact_owner IN (-1,11,0) OR > egw_addressbook.contact_owner > IS NULL) ORDER BY extra_order.contact_value<>'' > DESC,extra_order.contact_value ASC,org_name ASC,n_family ASC,n_given > ASC: > ERROR: for SELECT DISTINCT, ORDER BY expressions must appear in the list > results > > -- > View this message in context: > http://egroupware.219119.n3.nabble.com/Error-for-SELECT-DISTINCT-add > ressbook-tp759672p759672.html > Sent from the egroupware-developers mailing list archive at Nabble.com. > > > -------------------------------------------------------------------- > ---------- > _______________________________________________ > eGroupWare-developers mailing list > [hidden email] > -- Stylite GmbH [ open style of IT ] Morschheimer Strasse 15 67292 Kirchheimbolanden fon 06352 . 70629-0 fax 06352 . 70629-30 www.stylite.de Geschäftsführer: Andre Keller, Gudrun Müller, Ralf Becker Handelsregister Kaiserslautern HRB 30575 USt-ID: DE214280951 ------------------------------------------------------------------------------ _______________________________________________ eGroupWare-developers mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/egroupware-developers |
|
Nathan Gray |
|
|
On Wed, Apr 28, 2010 at 5:00 AM, Klaus Leithoff <[hidden email]> wrote:
> cannot reproduce that. recent trunk? Postgres maybe? ------------------------------------------------------------------------------ _______________________________________________ eGroupWare-developers mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/egroupware-developers |
|
Leithoff, Klaus |
|
|
possible, i will try tomorrow.
----------------ursprüngliche Nachricht----------------- Von: "Nathan Gray" [hidden email] An: "development of eGroupWare,for active developers" [hidden email] Datum: Wed, 28 Apr 2010 07:46:25 -0600 ------------------------------------------------- > On Wed, Apr 28, 2010 at 5:00 AM, Klaus Leithoff [hidden email] wrote: >> cannot reproduce that. recent trunk? > > Postgres maybe? > > > -------------------------------------------------------------------- > ---------- > _______________________________________________ > eGroupWare-developers mailing list > [hidden email] > -- Stylite GmbH [ open style of IT ] Morschheimer Strasse 15 67292 Kirchheimbolanden fon 06352 . 70629-0 fax 06352 . 70629-30 www.stylite.de Geschäftsführer: Andre Keller, Gudrun Müller, Ralf Becker Handelsregister Kaiserslautern HRB 30575 USt-ID: DE214280951 ------------------------------------------------------------------------------ _______________________________________________ eGroupWare-developers mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/egroupware-developers |
|
Ralf Becker-2 |
|
|
In reply to this post by Estrella9
Problem is, after prepending the table-name in order by, it also needs
to be prepended to the colum list. Try: SELECT DISTINCT egw_addressbook.*,extra_order.contact_value<>'' ---------------------------------------^ I commited a fix to Trunk: http://dev.egroupware.org/viewvc/egroupware?view=rev&revision=30023 Ralf Am 27.04.2010 17:48, schrieb Estrella9: > > Hello from the address book and add a custom field called 'CAMPUS', then I > went to the address book and the column appeared to me as 'CAMPUS', to click > on this I get this message from the database and I no longer can see the > address book but I could help. > > > Database error > > Invalid SQL: SELECT DISTINCT egw_addressbook.*,contact_value<>'' FROM > egw_addressbook LEFT JOIN egw_addressbook_extra extra_order ON > egw_addressbook.contact_id=extra_order.contact_id AND > extra_order.contact_name='CAMPUS' WHERE contact_tid='n' AND > (egw_addressbook.contact_owner=11 OR contact_private=0 AND > egw_addressbook.contact_owner IN (-1,11,0) OR egw_addressbook.contact_owner > IS NULL) ORDER BY extra_order.contact_value<>'' > DESC,extra_order.contact_value ASC,org_name ASC,n_family ASC,n_given ASC: > ERROR: for SELECT DISTINCT, ORDER BY expressions must appear in the list of > results > -- Ralf Becker Director Software Development Stylite GmbH [open style of IT] Morschheimer Strasse 15 67292 Kirchheimbolanden fon +49 (0) 6352 70629-0 fax +49 (0) 6352 70629-30 mailto: [hidden email] www.stylite.de www.egroupware.org ________________________________________________ Geschäftsführer Andre Keller, Gudrun Müller, Ralf Becker Registergericht Kaiserslautern HRB 30575 Umsatzsteuer-Id / VAT-Id: DE214280951 ------------------------------------------------------------------------------ _______________________________________________ eGroupWare-developers mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/egroupware-developers |
|
|
The same error occurs in the calendar with the birthday messages. It would be nice if you could patch that also.
Thanks Erich |
|
Ralf Becker-2 |
|
|
Please send the error (best with the trace going into Apache error_log).
Makes it easier to fix. Thanks Ralf Am 04.05.2010 13:43, schrieb snotty77: > > The same error occurs in the calendar with the birthday messages. It would be > nice if you could patch that also. > Thanks > Erich -- Ralf Becker Director Software Development Stylite GmbH [open style of IT] Morschheimer Strasse 15 67292 Kirchheimbolanden fon +49 (0) 6352 70629-0 fax +49 (0) 6352 70629-30 mailto: [hidden email] www.stylite.de www.egroupware.org ________________________________________________ Geschäftsführer Andre Keller, Gudrun Müller, Ralf Becker Registergericht Kaiserslautern HRB 30575 Umsatzsteuer-Id / VAT-Id: DE214280951 ------------------------------------------------------------------------------ _______________________________________________ eGroupWare-developers mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/egroupware-developers |
|
|
OK, here is the error:
Invalid SQL: SELECT DISTINCT egw_addressbook.contact_id AS id,egw_addressbook.n_family AS n_family,egw_addressbook.n_given AS n_given,egw_addressbook.n_prefix AS n_prefix,egw_addressbook.n_middle AS n_middle,egw_addressbook.contact_bday AS bday FROM egw_addressbook LEFT JOIN egw_accounts ON egw_addressbook.account_id=egw_accounts.account_id WHERE contact_bday != '' AND n_family != '' AND contact_tid != 'D' AND (egw_addressbook.contact_owner=12 OR contact_private=0 AND egw_addressbook.contact_owner IN (-14,12,0) OR egw_addressbook.contact_owner IS NULL) AND (account_expires IS NULL OR account_expires = -1 OR account_expires > 1273009436) ORDER BY contact_bday ASC: FEHLER: bei SELECT DISTINCT müssen ORDER-BY-Ausdrücke in der Select-Liste erscheinen To get the error you have to go to the calendar administration and enable the feature to show the birthday in calendar from the addressbook. You have to logout and login again to get the error message. Here you also have the unqualified "contact_bday" in the ORDER-BY statement. |
| Powered by Nabble | Edit this page |