PGメモ

非エンジニアの記録

2010-12-01から1ヶ月間の記事一覧

PDOではINが使えない。なぜか

symfonyで直接SQLを書く事は珍しい事ではない 今日もSQLを直接書くよ! $sql="select * from hoge where id in(?,?,?)"; $sth = $con->prepare($sql); $sth->execute(1,2,3);しかし、こう書いても返ってくるのはidが1のレコードのみ。 なぜか。 bindされた後…

::execute() must be compatible with that of sfComponent::execute() in の対処法

symfony1.1以上でactionsが長くなってきたので分けたいと思ったので分けてみた。すると hogeAction::execute() must be compatible with that of sfComponent::execute() inというのが出た。 hogeAction extends sfActions { public function execute() { } …