Skip to content

Commit

Permalink
Add Last(last string) (#69)
Browse files Browse the repository at this point in the history
  • Loading branch information
sim-wangyan committed Feb 1, 2024
1 parent 7881bf4 commit 058635a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions builder_x.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ type BuilderX struct {
havings []Bb
groupBys []string
aggs []Bb
last string
isDistinct bool
isWithoutOptimization bool

alia string
Expand Down Expand Up @@ -239,6 +241,11 @@ func (x *BuilderX) Paged(page func(pb *PageBuilder)) *BuilderX {
return x
}

func (x *BuilderX) Last(last string) *BuilderX {
x.last = last
return x
}

func (x *BuilderX) Build() *Built {
if x == nil {
panic("sqlxb.Builder is nil")
Expand Down

0 comments on commit 058635a

Please sign in to comment.