Documentation
¶
Index ¶
- func CheckDatabaseName(databaseName string) bool
- func CheckTableName(tableName string) bool
- func EscapeApostrophes(dataString string) string
- func EscapeDoubleQuotes(dataString string) string
- func EscapeMySQLString(dataString string) string
- func EscapePostgreSQLString(dataString string) string
- func NullStringToString(value sql.NullString) string
- type SQLdb
- func (conn *SQLdb) Close() error
- func (conn *SQLdb) Connect(checkENV ...bool) error
- func (conn *SQLdb) Exec(query string, args ...any) (sql.Result, error)
- func (conn *SQLdb) GetSQLTableInfo(tableName string) ([]struct{ ... }, map[string]string, error)
- func (conn *SQLdb) GetTableInfo(tableName string) ([]struct{ ... }, map[string]string, error)
- func (conn *SQLdb) Query(query string, args ...any) (*sql.Rows, error)
- func (conn *SQLdb) QueryRecords(query string, args ...any) ([]map[string]any, error)
- func (conn *SQLdb) QueryRow(query string, args ...any) *sql.Row
- func (conn *SQLdb) ShowDatabases() ([]string, error)
- func (conn *SQLdb) ShowTables() ([]string, error)
- func (conn *SQLdb) ShowTablesMap() (map[string]map[string]string, error)
- func (conn *SQLdb) TableExists(tableName string) (bool, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckDatabaseName ¶
func CheckTableName ¶
func EscapeApostrophes ¶
func EscapeDoubleQuotes ¶
func EscapeMySQLString ¶
func EscapePostgreSQLString ¶
func NullStringToString ¶
func NullStringToString(value sql.NullString) string
Types ¶
type SQLdb ¶
type SQLdb struct { //-------------------- DBType string //-------------------- Host string //-------------------- User string Password string //-------------------- AllowNativePasswords bool //-------------------- FilePath string DataPath string Database string DatabaseExt string //-------------------- AutoCreate bool //-------------------- DB *sql.DB // contains filtered or unexported fields }
func (*SQLdb) GetSQLTableInfo ¶
func (*SQLdb) GetTableInfo ¶
func (*SQLdb) QueryRecords ¶
func (*SQLdb) ShowDatabases ¶
func (*SQLdb) ShowTables ¶
func (*SQLdb) ShowTablesMap ¶
Click to show internal directories.
Click to hide internal directories.