From 7c5fcf32b404e64581f34d04291031234a51e7b2 Mon Sep 17 00:00:00 2001 From: flight643 <39926401+flight643@users.noreply.github.com> Date: Mon, 7 Dec 2020 18:48:24 +0300 Subject: [PATCH] Add int return type queryScalar and scalar method docs --- framework/db/Command.php | 2 +- framework/db/Query.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/db/Command.php b/framework/db/Command.php index 3d61e93a7e..1dcfb5b5e9 100644 --- a/framework/db/Command.php +++ b/framework/db/Command.php @@ -424,7 +424,7 @@ class Command extends Component /** * Executes the SQL statement and returns the value of the first column in the first row of data. * This method is best used when only a single value is needed for a query. - * @return string|null|false the value of the first column in the first row of the query result. + * @return string|int|null|false the value of the first column in the first row of the query result. * False is returned if there is no value. * @throws Exception execution failed */ diff --git a/framework/db/Query.php b/framework/db/Query.php index 59dcb8382a..ba0a103b8e 100644 --- a/framework/db/Query.php +++ b/framework/db/Query.php @@ -290,7 +290,7 @@ class Query extends Component implements QueryInterface, ExpressionInterface * The value returned will be the first column in the first row of the query results. * @param Connection $db the database connection used to generate the SQL statement. * If this parameter is not given, the `db` application component will be used. - * @return string|null|false the value of the first column in the first row of the query result. + * @return string|int|null|false the value of the first column in the first row of the query result. * False is returned if the query result is empty. */ public function scalar($db = null)