Re: [Rails] Select with an alias does not show alias column in "having".

2014-09-03 Thread Christian Kruse
^ Well, "doing it wrong" is not the phrase I would choose. In PostgreSQL, aliases are in a different scope than HAVING. HAVING may not access aliases, you have to repeat the aggregate (will be optimized to not be executed again). This is part of the SQL standard, AFAIK. Best regards, -- Christian Kruse http://ck.kennt-wayne.de/ pgpF3xT9TyZKb.pgp Description: OpenPGP Digital Signature

Re: [Rails] Multiple domains

2014-08-21 Thread Christian Kruse
27;example.com' and connect to localhost, thus the question. If the header value is the thing you're looking for: it is contained in `request.host`. Best regards, -- Christian Kruse http://ck.kennt-wayne.de/ pgpYmH00y3ENW.pgp Description: PGP signature

Re: [Rails] Re: "class Admin::UsersController < ApplicationController". What does the double colon do here?

2014-03-25 Thread Christian Kruse
t doesn't exist, yet while class Admin::UsersController end will not do this and error out. Best regards, - -- Christian Kruse http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services -BEGIN PGP SIGNATURE- Version: GnuPG v2.0.22