Changeset 18790 for branches/version-2_5-dev/data/class/SC_Query.php
- Timestamp:
- 2010/08/24 14:58:32 (14 years ago)
- bzr:base-revision:
- ohkouchi@loop-az.jp-20100820090626-dkyj2ngdh7vklaow
- bzr:committer:
- Kentaro Ohkouchi <ohkouchi@loop-az.jp>
- bzr:file-ids:
data/class/SC_Query.php 15078@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2FSC_Query.php
data/class/db/SC_DB_DBFactory.php 15123@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Fdb%2FSC_DB_DBFactory.php
data/class/db/dbfactory/SC_DB_DBFactory_MYSQL.php 15123@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Fdb%2Fdbfactory%2FSC_DB_DBFactory_MYSQL.php
data/class/db/dbfactory/SC_DB_DBFactory_PGSQL.php 15123@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Fdb%2Fdbfactory%2FSC_DB_DBFactory_PGSQL.php
data/class/helper/SC_Helper_DB.php 15176@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Fhelper%2FSC_Helper_DB.php
data/class/helper/SC_Helper_Session.php 15277@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Fhelper%2FSC_Helper_Session.php
html/install/index.php 16809@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fhtml%2Finstall%2Findex.php
test/class/SC_Query_Test.php sc_query_test.php-20100803024127-ljzonih8f5jpan9o-1
test/class/helper/SC_Helper_DB_Test.php 15242@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Ftest%2Fclass%2Fhelper%2FSC_Helper_DB_Test.php- bzr:mapping-version:
- v4
- bzr:repository-uuid:
- 1e3b908f-19a9-db11-a64c-001125224ba8
- bzr:revision-id:
- ohkouchi@loop-az.jp-20100824055828-2oy1qb3wcp85i76l
- bzr:revno:
- 2273
- bzr:revprop:branch-nick:
- branches/version-2_5-dev
- bzr:root:
- branches/version-2_5-dev
- bzr:text-parents:
data/class/SC_Query.php ohkouchi@loop-az.jp-20100819104758-beubop5hq0pwdqhx
data/class/helper/SC_Helper_Session.php ohkouchi@loop-az.jp-20100614082857-g3n9wn9zakpc7a0m
html/install/index.php ohkouchi@loop-az.jp-20100819104758-beubop5hq0pwdqhx
test/class/SC_Query_Test.php ohkouchi@loop-az.jp-20100803111301-u8ph4za35y4il0dh
test/class/helper/SC_Helper_DB_Test.php ohkouchi@loop-az.jp-20100726081655-tqxqwy02bxqhswcu- bzr:timestamp:
- 2010-08-24 14:58:28.038000107 +0900
- bzr:user-agent:
- bzr2.1.2+bzr-svn1.0.2
- svn:original-date:
- 2010-08-24T05:58:28.038000Z
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/version-2_5-dev/data/class/SC_Query.php
r18788 r18790 687 687 688 688 /** 689 * auto_incrementを取得する. 690 * 691 * XXX MDB2 の sequence 関数を使用する 692 * 693 * @param string $table_name テーブル名 694 * @return integer 695 */ 696 function get_auto_increment($table_name){ 697 // ロックする 698 $this->conn->exec("LOCK TABLES $table_name WRITE"); 699 700 // 次のIncrementを取得 701 $arrRet = $this->getAll("SHOW TABLE STATUS LIKE ". $this->quote($table_name)); 702 $auto_inc_no = $arrRet[0]["Auto_increment"]; 703 704 // 値をカウントアップしておく 705 $this->conn->exec("ALTER TABLE $table_name AUTO_INCREMENT=" . $this->quote($auto_inc_no + 1)); 706 707 // 解除する 708 $this->conn->exec('UNLOCK TABLES'); 709 710 return $auto_inc_no; 689 * シーケンスの一覧を取得する. 690 * 691 * @return array シーケンス名の配列 692 */ 693 function listSequences() { 694 $this->conn->loadModule('Manager'); 695 return $this->conn->listSequences(); 696 } 697 698 /** 699 * テーブル一覧を取得する. 700 * 701 * @return array テーブル名の配列 702 */ 703 function listTables() { 704 $this->conn->loadModule('Manager'); 705 return $this->conn->listTables(); 706 } 707 708 /** 709 * テーブルのカラム一覧を取得する. 710 * 711 * @param string $table テーブル名 712 * @return array 指定のテーブルのカラム名の配列 713 */ 714 function listTableFields($table) { 715 $this->conn->loadModule('Manager'); 716 return $this->conn->listTableFields($table); 717 } 718 719 /** 720 * テーブルのインデックス一覧を取得する. 721 * 722 * @param string $table テーブル名 723 * @return array 指定のテーブルのインデックス一覧 724 */ 725 function listTableIndexes($table) { 726 $this->conn->loadModule('Manager'); 727 return $this->conn->listTableIndexes($table); 711 728 } 712 729
Note: See TracChangeset
for help on using the changeset viewer.