Documentation ¶
Index ¶
- type DB
- func (this DB) Connect() *sql.DB
- func (this DB) CreateTable(tableName string, columns []string)
- func (this DB) DropTable(tableName string)
- func (this DB) Exec(sqlQuery string)
- func (this DB) GetAvgRowCountPerDay(tableName, dateColumn string, startDate, endDate time.Time, dayCount int) (avgRowCountPerDay int)
- func (this DB) GetAvgRowParamsPerDay(tableName, dateColumn string, startDate, endDate time.Time, dayCount int, ...) []map[string]interface{}
- func (this DB) GetRowCountOnDate(tableName, dateColumn string, date time.Time) (yesterdayRowCount int)
- func (this DB) GetRowParamsOnDate(tableName, dateColumn string, date time.Time, quantityColumn string, ...) []map[string]interface{}
- func (this DB) InsertMultiple(tableName string, rows [][]interface{}, columns []string)
- func (this DB) QueryObjects(sqlQuery string, values ...interface{}) (objects []map[string]interface{})
- func (this DB) Quote(statement string) string
- func (this DB) QuoteMultiple(statements []string) (quotedStatements []string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DB ¶
type DB struct {
Driver, Host, Port, User, Password, Database string
}
func (DB) CreateTable ¶
func (DB) GetAvgRowCountPerDay ¶
func (DB) GetAvgRowParamsPerDay ¶ added in v0.1.2
func (DB) GetRowCountOnDate ¶
func (DB) GetRowParamsOnDate ¶ added in v0.1.2
func (DB) InsertMultiple ¶
func (DB) QueryObjects ¶ added in v0.1.2
func (DB) QuoteMultiple ¶
Click to show internal directories.
Click to hide internal directories.