Re: What does "expression" refer to in the Totals list in a Query?

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



The last sentence skipped an important point:

Expressions are fields in the SELECT clause
that are not in the GROUP BY clause,
and have no aggregation (such as First or Sum or Count.)

In addition to Allen's sage advice...

you can add a *subquery* as an expression
that contains aggregation within it.

small point, but good to know I think....




.



Relevant Pages

  • Re: What does "expression" refer to in the Totals list in a Query?
    ... Expressions are fields in the SELECT clause ... Sum means add up all values for the grouped by fields. ... Since the expression is tacked on after aggregation, ... You can therefore refer to that in your Expression. ...
    (microsoft.public.access.queries)
  • Re: UNION ALL
    ... I am assuming that you are talking about in the where clause. ... might better be represented by mulitple expressions connected by an OR? ... I believe that multiple CASE statements will ... > parse faster because you are only using one main query as ...
    (microsoft.public.sqlserver.programming)
  • Re: RE: I learned something today (.NET and VB6)
    ... wit "If testexpression matches an expressionlist clause in more than one Case ... expressions where C allows only constants explains VB's keep-it-simple ... even get a simple warning flag in VB9. ... Good languages will flag code ...
    (microsoft.public.dotnet.languages.vb)
  • Re: Conditional Select
    ... Here is how a SELECT works in SQL ... ... Start in the FROM clause and build a working table from all of the ... e) Go to the SELECT clause and construct the expressions in the list. ... the innermost queries can reference columns and tables in the ...
    (microsoft.public.sqlserver.programming)
  • Re: Excellent
    ... If you were writing SQL, ... would be treated as an abstract data type. ... Start in the FROM clause and build a working table from all of the ... e) Go to the SELECT clause and construct the expressions in the list. ...
    (microsoft.public.sqlserver.programming)