mysql relay log參數匯總前言:MySQL進行主主複製或主從複製的時候會在home目錄下面產生相應的relay log,本文檔總結這些相關參數的定義及解釋1、什麼是relay logThe relay log, like the binary log, consists of a set of numbered files containing events that describe database changes, and an index file that
Oracle index unusable和invisible的區別摘錄自Oracle 11g的官方文檔:UNUSABLE Specify UNUSABLE to mark the index or index partition(s) or index subpartition(s) UNUSABLE. The space allocated for an index or index partition or subpartition is freed immediately when
shell 提取msyql指定資料庫下表建立語句為單檔案,dbcn="mysql -h172.16.1.194 -uroot -p123456";db=dsp_ad_center;ii=0;ct=`$dbcn -N -e " SELECT COUNT(1) FROM information_schema.TABLES AS t WHERE t.TABLE_SCHEMA = '$db' AND t.TABLE_TYPE = 'BASE
On the development of a new generation of large data distributed relational database initiative,relationalOn the development of a new generation of large data distributed relational database initiative
DB2查看執行計畫,db2執行計畫在DB2中查看sql的執行計畫沒有其它資料庫方便,需要經過好幾步,這裡我把步驟整理成shell指令碼以方便使用,如下:#!/bin/sh db2 connect to <db>db2 -tvf $HOME/sqllib/misc/EXPLAIN.DDLdb2 set current explain mode explain db2 "<sql>" db2 set current explain mode no
Mysql最佳化之BTree索引,mysqlbtree索引從一道題開始分析:假設某個表有一個聯合索引(c1,c2,c3,c4)一下——只能使用該聯合索引的c1,c2,c3部分A where c1=x and c2=x and c4>x and c3=xB where c1=x and c2=x and c4=x order by c3C where c1=x and c4= x group by c3,c2D where c1=? and c5=? order by c2,c3E
遊標的使用,遊標使用定義遊標: cursor calenderStatus_cur is select * from ut_calenderStatus ; vr_calenderStatus ut_calenderStatus % rowtype;開啟遊標,提取遊標中的資料到遊標行中: open calenderStatus_cur; loop fetch calenderStatus_cur into