Documentation ¶
Index ¶
- func Version() string
- type ArrayValue
- type Dialect
- func (d *Dialect) AppendSequence(b []byte, _ *schema.Table, _ *schema.Field) []byte
- func (d *Dialect) AppendUint32(b []byte, n uint32) []byte
- func (d *Dialect) AppendUint64(b []byte, n uint64) []byte
- func (d *Dialect) DefaultVarcharLen() int
- func (d *Dialect) Features() feature.Feature
- func (d *Dialect) IdentQuote() byte
- func (d *Dialect) Init(*sql.DB)
- func (d *Dialect) Name() dialect.Name
- func (d *Dialect) OnTable(table *schema.Table)
- func (d *Dialect) Tables() *schema.Tables
- type HStoreValue
- type MultiRange
- type Range
- type RangeBound
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ArrayValue ¶
type ArrayValue struct {
// contains filtered or unexported fields
}
func Array ¶
func Array(vi interface{}) *ArrayValue
Array accepts a slice and returns a wrapper for working with PostgreSQL array data type.
For struct fields you can use array tag:
Emails []string `bun:",array"`
func (*ArrayValue) AppendQuery ¶
func (*ArrayValue) Scan ¶
func (a *ArrayValue) Scan(src interface{}) error
func (*ArrayValue) Value ¶
func (a *ArrayValue) Value() interface{}
type Dialect ¶
type Dialect struct { schema.BaseDialect // contains filtered or unexported fields }
func (*Dialect) AppendSequence ¶ added in v1.1.17
func (*Dialect) AppendUint32 ¶ added in v1.0.14
func (*Dialect) AppendUint64 ¶ added in v1.0.14
func (*Dialect) DefaultVarcharLen ¶ added in v1.1.10
func (*Dialect) IdentQuote ¶
type HStoreValue ¶ added in v1.1.6
type HStoreValue struct {
// contains filtered or unexported fields
}
func HStore ¶ added in v1.1.6
func HStore(vi interface{}) *HStoreValue
HStore accepts a map[string]string and returns a wrapper for working with PostgreSQL hstore data type.
For struct fields you can use hstore tag:
Attrs map[string]string `bun:",hstore"`
func (*HStoreValue) AppendQuery ¶ added in v1.1.6
func (*HStoreValue) Scan ¶ added in v1.1.6
func (h *HStoreValue) Scan(src interface{}) error
func (*HStoreValue) Value ¶ added in v1.1.6
func (h *HStoreValue) Value() interface{}
type MultiRange ¶ added in v1.2.2
type Range ¶ added in v1.2.2
type Range[T any] struct { Lower, Upper T LowerBound, UpperBound RangeBound }
func (*Range[T]) AppendQuery ¶ added in v1.2.2
type RangeBound ¶ added in v1.2.2
type RangeBound byte
const ( RangeBoundInclusiveLeft RangeBound = '[' RangeBoundInclusiveRight RangeBound = ']' RangeBoundExclusiveLeft RangeBound = '(' RangeBoundExclusiveRight RangeBound = ')' )
Click to show internal directories.
Click to hide internal directories.