- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 146 for null (0.24 sec)
-
tests/sql_builder_test.go
}) assertEqualSQL(t, `INSERT INTO "users" ("created_at","updated_at","deleted_at","name","age","birthday","company_id","manager_id","active") VALUES ('2021-10-18 00:00:00','2021-10-18 00:00:00',NULL,'foo',20,NULL,NULL,NULL,false) RETURNING "id"`, sql) // save user = &User{Name: "foo", Age: 20} user.CreatedAt = date user.UpdatedAt = date sql = DB.ToSQL(func(tx *gorm.DB) *gorm.DB {
Go - Registered: Sun Apr 28 09:35:09 GMT 2024 - Last Modified: Fri Jan 12 08:42:21 GMT 2024 - 16.7K bytes - Viewed (0) -
tests/default_value_test.go
import ( "testing" "time" "gorm.io/gorm" ) func TestDefaultValue(t *testing.T) { type Harumph struct { gorm.Model Email string `gorm:"not null;index:,unique"` Name string `gorm:"notNull;default:foo"` Name2 string `gorm:"size:233;not null;default:'foo'"` Name3 string `gorm:"size:233;notNull;default:''"` Age int `gorm:"default:18"` Created time.Time `gorm:"default:2000-01-02"`
Go - Registered: Sun Apr 28 09:35:09 GMT 2024 - Last Modified: Mon Apr 08 03:29:55 GMT 2024 - 2.3K bytes - Viewed (0) -
tests/query_test.go
} type QueryResetNullValue struct { ID int Name string `gorm:"default:NULL"` Flag bool `gorm:"default:NULL"` Number1 int64 `gorm:"default:NULL"` Number2 uint64 `gorm:"default:NULL"` Number3 float64 `gorm:"default:NULL"` Now *time.Time `gorm:"defalut:NULL"` Item1Id string Item1 *QueryResetItem `gorm:"references:ID"` Item2Id string
Go - Registered: Sun Apr 28 09:35:09 GMT 2024 - Last Modified: Thu Apr 25 12:22:53 GMT 2024 - 49.8K bytes - Viewed (0) -
clause/expression_test.go
clause.Eq{Column: column, Value: (*bool)(nil)}, clause.Eq{Column: column, Value: (interface{})(nil)}, clause.Eq{Column: column, Value: sql.NullString{String: "", Valid: false}}, }, Result: "`column-name` IS NULL", }, { Expressions: []clause.Expression{ clause.Neq{Column: column, Value: "column-value"}, }, ExpectedVars: []interface{}{"column-value"}, Result: "`column-name` <> ?", }, {
Go - Registered: Sun Apr 28 09:35:09 GMT 2024 - Last Modified: Thu Aug 10 05:34:33 GMT 2023 - 8.4K bytes - Viewed (0) -
internal/bucket/replication/and.go
Tags []Tag `xml:"Tag,omitempty" json:"Tag,omitempty"` } var errDuplicateTagKey = Errorf("Duplicate Tag Keys are not allowed") // isEmpty returns true if Tags field is null func (a And) isEmpty() bool { return len(a.Tags) == 0 && a.Prefix == "" } // Validate - validates the And field func (a And) Validate() error { if a.ContainsDuplicateTag() { return errDuplicateTagKey }
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Tue Jun 01 21:59:40 GMT 2021 - 1.8K bytes - Viewed (0) -
tests/associations_test.go
t.Fatalf("should return errors for invalid association, but got nil") } } func TestAssociationNotNullClear(t *testing.T) { type Profile struct { gorm.Model Number string MemberID uint `gorm:"not null"` } type Member struct { gorm.Model Profiles []Profile } DB.Migrator().DropTable(&Member{}, &Profile{}) if err := DB.AutoMigrate(&Member{}, &Profile{}); err != nil {
Go - Registered: Sun Apr 28 09:35:09 GMT 2024 - Last Modified: Wed Feb 08 08:29:09 GMT 2023 - 10.9K bytes - Viewed (0) -
src/cmd/cgo/internal/test/issue24161e0/main.go
typedef CFStringRef SecKeyAlgorithm; static CFDataRef SecKeyCreateSignature(SecKeyRef key, SecKeyAlgorithm algorithm, CFDataRef dataToSign, CFErrorRef *error){return NULL;} #define kSecKeyAlgorithmECDSASignatureDigestX962SHA1 foo() static SecKeyAlgorithm foo(void){return NULL;} #endif */ import "C" import "testing" func f1() { C.SecKeyCreateSignature(0, C.kSecKeyAlgorithmECDSASignatureDigestX962SHA1, 0, nil) }
Go - Registered: Tue Mar 26 11:13:08 GMT 2024 - Last Modified: Fri May 12 12:00:02 GMT 2023 - 919 bytes - Viewed (0) -
cmd/xl-storage-free-version_test.go
"00000000-0000-0000-0000-0000000000f1", "00000000-0000-0000-0000-0000000000f2", } // Simulate overwrite of null version newtierfi := tierfi newtierfi.SetTierFreeVersionID(fvIDs[0]) fatalErr(xl.AddFreeVersion(newtierfi)) report() fatalErr(xl.AddVersion(newtierfi)) report() // Simulate removal of null version newtierfi.TransitionTier = "" newtierfi.TransitionedObjName = "" newtierfi.TransitionStatus = ""
Go - Registered: Sun Apr 28 19:28:10 GMT 2024 - Last Modified: Sat Mar 02 05:11:03 GMT 2024 - 7.8K bytes - Viewed (0) -
src/cmd/cgo/internal/test/issue1435.go
// t = calloc(nts, sizeof(pthread_t)); // pthread_mutex_init(&mu, NULL); // for (i = 0; i < nts; i++) { // pthread_create(&t[i], NULL, aFn, NULL); // } // } // // void cleanup(void) { // int i; // pthread_mutex_lock(&mu); // all_done = 1; // pthread_mutex_unlock(&mu); // for (i = 0; i < nts; i++) { // pthread_join(t[i], NULL); // } // pthread_mutex_destroy(&mu); // free(t); // } import "C"
Go - Registered: Tue Apr 23 11:13:09 GMT 2024 - Last Modified: Fri Jul 28 21:31:41 GMT 2023 - 7.5K bytes - Viewed (0) -
internal/s3select/sql/parser.go
Int *float64 `parser:" | @Int"` // To avoid value out of range, use float64 instead String *LiteralString `parser:" | @LitString"` Boolean *Boolean `parser:" | @(\"TRUE\" | \"FALSE\")"` Null bool `parser:" | @\"NULL\""` Missing bool `parser:" | @\"MISSING\")"` } // Identifier represents a parsed identifier type Identifier struct { Unquoted *string `parser:" @Ident"`
Go - Registered: Sun Apr 21 19:28:08 GMT 2024 - Last Modified: Thu Jan 18 07:03:17 GMT 2024 - 12.9K bytes - Viewed (0)