yiisoft/yii — Issue #429: findAllByPk() issue
Author: Koduc
Created: 2012-03-02 08:10:41+00:00
State: open

```php
// $input = '3,5,6,';
// $orders = explode(',', $input);
$orders = array('3', '');
$orders = Orders::model()->findAllByPk($orders);
```

Gives error:

SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1. The SQL statement executed was: SELECT * FROM `doors_orders` `t` WHERE `t`.`id` IN (3, )

I think, that there is no reason to include empty values to resulting sql