Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 345 for raws (0.05 sec)

  1. tests/scan_test.go

    	DB.Save(&user1).Save(&user2).Save(&user3)
    
    	rows, err := DB.Table("users").Where("name = ? or name = ?", user2.Name, user3.Name).Select("name, age").Rows()
    	if err != nil {
    		t.Errorf("No error should happen, got %v", err)
    	}
    
    	type Result struct {
    		Name string
    		Age  int
    	}
    
    	var results []Result
    	for rows.Next() {
    		var result Result
    		if err := DB.ScanRows(rows, &result); err != nil {
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Wed Jun 12 10:57:36 UTC 2024
    - 10.9K bytes
    - Viewed (0)
  2. src/database/sql/convert_test.go

    			}
    		}
    		if !match {
    			t.Fatalf("%s: got %q (len %d); want %q (len %d)", name, buf, len(buf), want, len(want))
    		}
    	}
    
    	n := testing.AllocsPerRun(100, func() {
    		for _, tt := range tests {
    			rows.raw = rows.raw[:0]
    			test(tt.name, tt.in, tt.want)
    		}
    	})
    
    	// The numbers below are only valid for 64-bit interface word sizes,
    	// and gc. With 32-bit words there are more convT2E allocs, and
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 10 20:23:22 UTC 2024
    - 17K bytes
    - Viewed (0)
  3. finisher_api.go

    	tx := db.getInstance().Set("rows", false)
    	tx = tx.callbacks.Row().Execute(tx)
    	row, ok := tx.Statement.Dest.(*sql.Row)
    	if !ok && tx.DryRun {
    		db.Logger.Error(tx.Statement.Context, ErrDryRunModeUnsupported.Error())
    	}
    	return row
    }
    
    func (db *DB) Rows() (*sql.Rows, error) {
    	tx := db.getInstance().Set("rows", true)
    	tx = tx.callbacks.Row().Execute(tx)
    	rows, ok := tx.Statement.Dest.(*sql.Rows)
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Fri Jan 12 08:42:21 UTC 2024
    - 22.7K bytes
    - Viewed (0)
  4. tests/sql_builder_test.go

    		Email string
    	}
    
    	var results []result
    	DB.Raw("SELECT name, age FROM users WHERE name = ? or name = ?", user2.Name, user3.Name).Scan(&results)
    	if len(results) != 2 || results[0].Name != user2.Name || results[1].Name != user3.Name {
    		t.Errorf("Raw with scan")
    	}
    
    	rows, _ := DB.Raw("select name, age from users where name = ?", user3.Name).Rows()
    	count := 0
    	for rows.Next() {
    		count++
    	}
    	if count != 1 {
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Fri Jan 12 08:42:21 UTC 2024
    - 16.7K bytes
    - Viewed (0)
  5. src/database/sql/fakedb_test.go

    		}
    		if doInsert {
    			cols[colidx] = val
    		}
    	}
    
    	if doInsert {
    		t.rows = append(t.rows, &row{cols: cols})
    	}
    	return driver.RowsAffected(1), nil
    }
    
    // hook to simulate broken connections
    var hookQueryBadConn func() bool
    
    func (s *fakeStmt) Query(args []driver.Value) (driver.Rows, error) {
    	panic("Use QueryContext")
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 01 12:38:07 UTC 2024
    - 30.3K bytes
    - Viewed (0)
  6. cmd/signature-v2.go

    	"uploadId",
    	"uploads",
    	"versionId",
    	"versioning",
    	"versions",
    	"website",
    }
    
    // Signature and API related constants.
    const (
    	signV2Algorithm = "AWS"
    )
    
    // AWS S3 Signature V2 calculation rule is give here:
    // http://docs.aws.amazon.com/AmazonS3/latest/dev/RESTAuthentication.html#RESTAuthenticationStringToSign
    func doesPolicySignatureV2Match(formValues http.Header) (auth.Credentials, APIErrorCode) {
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu Jan 18 07:03:17 UTC 2024
    - 12.2K bytes
    - Viewed (0)
  7. api/go1.8.txt

    pkg database/sql, method (*DB) QueryContext(context.Context, string, ...interface{}) (*Rows, error)
    pkg database/sql, method (*DB) QueryRowContext(context.Context, string, ...interface{}) *Row
    pkg database/sql, method (*Rows) ColumnTypes() ([]*ColumnType, error)
    pkg database/sql, method (*Rows) NextResultSet() bool
    pkg database/sql, method (*Stmt) ExecContext(context.Context, ...interface{}) (Result, error)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Dec 21 05:25:57 UTC 2016
    - 16.3K bytes
    - Viewed (0)
  8. src/database/sql/driver/driver.go

    //	[]byte
    //	string
    //	time.Time
    //
    // If the driver supports cursors, a returned Value may also implement the [Rows] interface
    // in this package. This is used, for example, when a user selects a cursor
    // such as "select cursor(select * from my_table) from dual". If the [Rows]
    // from the select is closed, the cursor [Rows] will also be closed.
    type Value any
    
    // NamedValue holds both the value name and value.
    type NamedValue struct {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 23 09:04:12 UTC 2023
    - 20.9K bytes
    - Viewed (0)
  9. staging/src/k8s.io/apiextensions-apiserver/test/integration/table_test.go

    					}
    				}
    			}
    			if got, expected := len(tbl.Rows), 1; got != expected {
    				t.Errorf("expected %d rows, got %d", expected, got)
    			} else if got, expected := len(tbl.Rows[0].Cells), expectColumnNum; got != expected {
    				t.Errorf("expected %d cells, got %d", expected, got)
    			} else {
    				if got, expected := tbl.Rows[0].Cells[0], "foo"; got != expected {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Mar 02 19:34:41 UTC 2021
    - 18.9K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/tensorflow/transforms/unroll_batch_matmul.cc

      }
    
      const int64_t rows = lhs_shape[lhs_dims - 2];
      const int64_t cols = rhs_shape[rhs_dims - 1];
    
      if (lhs_shape[lhs_dims - 1] != rhs_shape[rhs_dims - 2]) {
        // Input dimensions must be compatible for multiplication.
        return failure();
      }
    
      const auto matmul_type = RankedTensorType::get({rows, cols}, element_type);
    
      if (lhs_dims == 2 && rhs_dims == 2) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 11.6K bytes
    - Viewed (0)
Back to top