本文整理汇总了PHP中Varien_Db_Adapter_Interface::getIndexName方法的典型用法代码示例。如果您正苦于以下问题:PHP Varien_Db_Adapter_Interface::getIndexName方法的具体用法?PHP Varien_Db_Adapter_Interface::getIndexName怎么用?PHP Varien_Db_Adapter_Interface::getIndexName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Varien_Db_Adapter_Interface
的用法示例。
在下文中一共展示了Varien_Db_Adapter_Interface::getIndexName方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: _createTemporaryTable
/**
* Create temporary table
*/
protected function _createTemporaryTable()
{
$this->_connection->dropTemporaryTable($this->_getTemporaryTable());
$table = $this->_connection->newTable($this->_getTemporaryTable())->addColumn('grouped_id', Varien_Db_Ddl_Table::TYPE_VARCHAR, 80, array(), 'Grouped ID')->addColumn('product_id', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array('unsigned' => true), 'Product ID')->addColumn('customer_group_id', Varien_Db_Ddl_Table::TYPE_SMALLINT, 5, array('unsigned' => true), 'Customer Group ID')->addColumn('from_date', Varien_Db_Ddl_Table::TYPE_DATE, null, array(), 'From Date')->addColumn('to_date', Varien_Db_Ddl_Table::TYPE_DATE, null, array(), 'To Date')->addColumn('action_amount', Varien_Db_Ddl_Table::TYPE_DECIMAL, '12,4', array(), 'Action Amount')->addColumn('action_operator', Varien_Db_Ddl_Table::TYPE_VARCHAR, 10, array(), 'Action Operator')->addColumn('action_stop', Varien_Db_Ddl_Table::TYPE_SMALLINT, 6, array(), 'Action Stop')->addColumn('sort_order', Varien_Db_Ddl_Table::TYPE_INTEGER, 10, array('unsigned' => true), 'Sort Order')->addColumn('price', Varien_Db_Ddl_Table::TYPE_DECIMAL, '12,4', array(), 'Product Price')->addColumn('rule_product_id', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array('unsigned' => true), 'Rule Product ID')->addColumn('from_time', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array('unsigned' => true, 'nullable' => true, 'default' => 0), 'From Time')->addColumn('to_time', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array('unsigned' => true, 'nullable' => true, 'default' => 0), 'To Time')->addIndex($this->_connection->getIndexName($this->_getTemporaryTable(), 'grouped_id'), array('grouped_id'))->setComment('CatalogRule Price Temporary Table');
$this->_connection->createTemporaryTable($table);
}