propel
データ更新後はマスタに接続する app.yml all: propel: force_master_flashes: [notice] frontendConfiguration.class.php dispatcher->connect('context.load_factories', array($this, 'loadFactoriesEvent')); } public function loadFactoriesEvent(sfEv…
http://github.com/aki77/Propel-Behavior/blob/master/AkPropelBehaviorInnodbCount.php デフォルト SELECT COUNT(*) FROM `article` propel behavior 設定後 SELECT COUNT(article.CREATED_AT) FROM `article`
http://github.com/aki77/Propel-Behavior タスク等で大量のレコードに対して処理をするとき、メモリアロケーションエラー防止の為に↓みたいに書いていたのが fetch(PDO::FETCH_NUM)) { $a = new Author(); $a->hydrate($row); // ... } こう書けるようにな…
symfony 1.3 + propel 1.4 が対象です。http://github.com/aki77/akWebDebugPanelPropel sfWebDebugPanelPropel に以下の表示を追加します。 Explain結果の表示・警告 指定回数以上のクエリが発行された場合の警告 参考サイト 開発環境で自動でSQLにExplain…
ProjectConfiguration.class.php dispatcher->connect( 'propel.filter_connection_config', array($this, 'filterConnectionConfigEvent') ); } public function filterConnectionConfigEvent($event, $arguments) { if ($slaves = $event['database']->get…
1.2 に上げたあたりから再構築のたびに、subversionで余計な更新が発生していたので設定見直し。 propel.ini propel.addTimeStamp = false schema.yml created_at: type: TIMESTAMP required: true default: '0000-00-00 00:00:00' # default: 0000-00-00 00…