From 2fca1e9061f970e365a90f92d90d52f2ff9cdd8a Mon Sep 17 00:00:00 2001 From: Qiang Xue Date: Thu, 5 Dec 2013 10:09:44 -0500 Subject: [PATCH] Fixes #1433: added default DB connection to SqlDataProvider. --- framework/yii/data/SqlDataProvider.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/framework/yii/data/SqlDataProvider.php b/framework/yii/data/SqlDataProvider.php index d8f0cd1..5517aa1 100644 --- a/framework/yii/data/SqlDataProvider.php +++ b/framework/yii/data/SqlDataProvider.php @@ -64,9 +64,8 @@ class SqlDataProvider extends BaseDataProvider { /** * @var Connection|string the DB connection object or the application component ID of the DB connection. - * If not set, the default DB connection will be used. */ - public $db; + public $db = 'db'; /** * @var string the SQL statement to be used for fetching data rows. */