Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for BuildQuerySQL (0.18 sec)

  1. callbacks/row.go

    package callbacks
    
    import (
    	"gorm.io/gorm"
    )
    
    func RowQuery(db *gorm.DB) {
    	if db.Error == nil {
    		BuildQuerySQL(db)
    		if db.DryRun || db.Error != nil {
    			return
    		}
    
    		if isRows, ok := db.Get("rows"); ok && isRows.(bool) {
    			db.Statement.Settings.Delete("rows")
    			db.Statement.Dest, db.Error = db.Statement.ConnPool.QueryContext(db.Statement.Context, db.Statement.SQL.String(), db.Statement.Vars...)
    		} else {
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Wed Feb 08 05:40:41 GMT 2023
    - 581 bytes
    - Viewed (0)
  2. callbacks/query.go

    package callbacks
    
    import (
    	"fmt"
    	"reflect"
    	"strings"
    
    	"gorm.io/gorm"
    	"gorm.io/gorm/clause"
    	"gorm.io/gorm/schema"
    	"gorm.io/gorm/utils"
    )
    
    func Query(db *gorm.DB) {
    	if db.Error == nil {
    		BuildQuerySQL(db)
    
    		if !db.DryRun && db.Error == nil {
    			rows, err := db.Statement.ConnPool.QueryContext(db.Statement.Context, db.Statement.SQL.String(), db.Statement.Vars...)
    			if err != nil {
    				db.AddError(err)
    				return
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Mon Jan 29 03:34:57 GMT 2024
    - 9.9K bytes
    - Viewed (0)
Back to top