Documentation ¶
Index ¶
- type DefaultDao
- func (this *DefaultDao) DropNotExistsTable() error
- func (this *DefaultDao) ExecDML(sql string) error
- func (this *DefaultDao) FindTableColumnNames(sName string, tName string) ([]string, error)
- func (this *DefaultDao) FindTablePKColumnNames(sName string, tName string) ([]string, error)
- func (this *DefaultDao) FindTableUKColumnNames(sName string, tName string) ([]string, string, error)
- func (this *DefaultDao) FindTablesBySchema(sName string) ([]*models.DBTable, error)
- func (this *DefaultDao) GetOldestAndNewestPos() (*models.Position, *models.Position, error)
- func (this *DefaultDao) GetUKName(sName string, tName string) (string, error)
- func (this *DefaultDao) ShowBinaryLogs() ([]*models.BinaryLog, error)
- func (this *DefaultDao) ShowMasterStatus() (*models.Position, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DefaultDao ¶
func NewDefaultDao ¶
func NewDefaultDao() *DefaultDao
func (*DefaultDao) DropNotExistsTable ¶
func (this *DefaultDao) DropNotExistsTable() error
删除一个不存在的表
func (*DefaultDao) FindTableColumnNames ¶
func (this *DefaultDao) FindTableColumnNames(sName string, tName string) ([]string, error)
获取表中所有的字段
func (*DefaultDao) FindTablePKColumnNames ¶
func (this *DefaultDao) FindTablePKColumnNames(sName string, tName string) ([]string, error)
获取主键字段名
func (*DefaultDao) FindTableUKColumnNames ¶
func (this *DefaultDao) FindTableUKColumnNames(sName string, tName string) ([]string, string, error)
获取唯一键字段
func (*DefaultDao) FindTablesBySchema ¶
func (this *DefaultDao) FindTablesBySchema(sName string) ([]*models.DBTable, error)
获取表通过schema
func (*DefaultDao) GetOldestAndNewestPos ¶
获取最老和最新的日志位点
func (*DefaultDao) GetUKName ¶
func (this *DefaultDao) GetUKName(sName string, tName string) (string, error)
获取第一个唯一键
func (*DefaultDao) ShowBinaryLogs ¶
func (this *DefaultDao) ShowBinaryLogs() ([]*models.BinaryLog, error)
func (*DefaultDao) ShowMasterStatus ¶
func (this *DefaultDao) ShowMasterStatus() (*models.Position, error)
Click to show internal directories.
Click to hide internal directories.