feat: update medias
This commit is contained in:
20
test/main_test.go
Normal file
20
test/main_test.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"test/database/models/qvyun_v2/public/table"
|
||||
|
||||
. "github.com/go-jet/jet/v2/postgres"
|
||||
)
|
||||
|
||||
func Test_Join(t *testing.T) {
|
||||
t1 := table.Medias
|
||||
t2 := table.UserMedias
|
||||
|
||||
stmt := SELECT(t1.AllColumns).
|
||||
FROM(
|
||||
t1.RIGHT_JOIN(t2, t2.UserID.EQ(Int64(10)).AND(t2.TenantID.EQ(Int64(1)).AND(t2.MediaID.EQ(t1.ID)))),
|
||||
)
|
||||
t.Log(stmt.DebugSql())
|
||||
}
|
||||
Reference in New Issue
Block a user