summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/sql/functions.py
diff options
context:
space:
mode:
authormike bayer <mike_mp@zzzcomputing.com>2019-01-12 23:22:47 +0000
committerGerrit Code Review <gerrit@bbpush.zzzcomputing.com>2019-01-12 23:22:47 +0000
commit8138e70d63216381b9b3cb7a64750a3add154ec6 (patch)
treeee798a4a4851af4431d738bce0c1b99b6b8267c7 /lib/sqlalchemy/sql/functions.py
parent55f930ef3d4e60bed02a2dad16e331fe42cfd12b (diff)
parenta6094d6682c956ce8a77fbec2a2700f901f3e75e (diff)
downloadsqlalchemy-8138e70d63216381b9b3cb7a64750a3add154ec6.tar.gz
Merge "use ..deprecated directive w/ version in all cases"
Diffstat (limited to 'lib/sqlalchemy/sql/functions.py')
-rw-r--r--lib/sqlalchemy/sql/functions.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/sqlalchemy/sql/functions.py b/lib/sqlalchemy/sql/functions.py
index cd2798dda..cc145cf51 100644
--- a/lib/sqlalchemy/sql/functions.py
+++ b/lib/sqlalchemy/sql/functions.py
@@ -756,6 +756,22 @@ class count(GenericFunction):
r"""The ANSI COUNT aggregate function. With no arguments,
emits COUNT \*.
+ E.g.::
+
+ from sqlalchemy import func
+ from sqlalchemy import select
+ from sqlalchemy import table, column
+
+ my_table = table('some_table', column('id'))
+
+ stmt = select([func.count()]).select_from(my_table)
+
+ Executing ``stmt`` would emit::
+
+ SELECT count(*) AS count_1
+ FROM some_table
+
+
"""
type = sqltypes.Integer