Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 203 for savyje (0.07 sec)

  1. tests/embedded_struct_test.go

    		if !DB.Migrator().HasColumn(&HNPost{}, name) {
    			t.Errorf("should has prefixed column %v", name)
    		}
    	}
    
    	// save embedded struct
    	DB.Save(&HNPost{BasePost: BasePost{Title: "news"}})
    	DB.Save(&HNPost{BasePost: BasePost{Title: "hn_news"}})
    	var news HNPost
    	if err := DB.First(&news, "title = ?", "hn_news").Error; err != nil {
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Wed May 08 04:07:58 UTC 2024
    - 7.3K bytes
    - Viewed (0)
  2. docs_src/sql_databases_peewee/sql_app/crud.py

        db_user.save()
        return db_user
    
    
    def get_items(skip: int = 0, limit: int = 100):
        return list(models.Item.select().offset(skip).limit(limit))
    
    
    def create_user_item(item: schemas.ItemCreate, user_id: int):
        db_item = models.Item(**item.dict(), owner_id=user_id)
        db_item.save()
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Mar 26 19:09:53 UTC 2020
    - 843 bytes
    - Viewed (0)
  3. tests/sql_builder_test.go

    	. "gorm.io/gorm/utils/tests"
    )
    
    func TestRow(t *testing.T) {
    	user1 := User{Name: "RowUser1", Age: 1}
    	user2 := User{Name: "RowUser2", Age: 10}
    	user3 := User{Name: "RowUser3", Age: 20}
    	DB.Save(&user1).Save(&user2).Save(&user3)
    
    	row := DB.Table("users").Where("name = ?", user2.Name).Select("age").Row()
    
    	var age int64
    	if err := row.Scan(&age); err != nil {
    		t.Fatalf("Failed to scan age, got %v", err)
    	}
    
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Fri Jan 12 08:42:21 UTC 2024
    - 16.7K bytes
    - Viewed (0)
  4. callbacks/associations.go

    func SaveBeforeAssociations(create bool) func(db *gorm.DB) {
    	return func(db *gorm.DB) {
    		if db.Error == nil && db.Statement.Schema != nil {
    			selectColumns, restricted := db.Statement.SelectAndOmitColumns(create, !create)
    
    			// Save Belongs To associations
    			for _, rel := range db.Statement.Schema.Relationships.BelongsTo {
    				if v, ok := selectColumns[rel.Name]; (ok && !v) || (!ok && restricted) {
    					continue
    				}
    
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Tue Apr 11 03:06:13 UTC 2023
    - 14.3K bytes
    - Viewed (0)
  5. docs/debugging/pprofgoparser/main.go

    			if searchRE == nil || searchRE.MatchString(stackTrace) {
    				ret[t] = append(ret[t], stackTrace)
    			}
    		case record:
    			save(line)
    		default:
    			z := goroutinesRE.FindStringSubmatch(line)
    			if len(z) == 3 {
    				if z[2] != "" {
    					a, _ := strconv.Atoi(z[2])
    					t = time.Duration(a) * time.Minute
    					save(line)
    					record = true
    				} else {
    					skip = true
    				}
    			}
    		}
    	}
    
    	return ret, nil
    }
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed Mar 06 11:43:16 UTC 2024
    - 3.4K bytes
    - Viewed (0)
  6. README.md

    ## Overview
    
    * Full-Featured ORM
    * Associations (Has One, Has Many, Belongs To, Many To Many, Polymorphism, Single-table inheritance)
    * Hooks (Before/After Create/Save/Update/Delete/Find)
    * Eager loading with `Preload`, `Joins`
    * Transactions, Nested Transactions, Save Point, RollbackTo to Saved Point
    * Context, Prepared Statement Mode, DryRun Mode
    * Batch Insert, FindInBatches, Find To Map
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Tue Nov 07 02:20:06 UTC 2023
    - 1.8K bytes
    - Viewed (0)
  7. tests/gorm_test.go

    			t.Fatalf("rows affected expects: %v, got %v", 1, results.RowsAffected)
    		} else if got.ID != u1.ID {
    			t.Fatalf("select expects: %v, got %v", u1, got)
    		}
    
    		u1.Name = "jinzhu"
    		if results := DB.Save(&u1); results.Error != nil {
    			t.Fatalf("errors happened on update: %v", results.Error)
    		} else if results.RowsAffected != 1 {
    			t.Fatalf("rows affected expects: %v, got %v", 1, results.RowsAffected)
    		}
    
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Thu Jun 01 07:22:21 UTC 2023
    - 3.3K bytes
    - Viewed (0)
  8. compat/maven-embedder/src/main/java/org/apache/maven/cli/props/MavenProperties.java

            loadLayout(reader, false);
        }
    
        public void save() throws IOException {
            save(this.location);
        }
    
        public void save(Path location) throws IOException {
            try (OutputStream os = Files.newOutputStream(location)) {
                save(os);
            }
        }
    
        public void save(OutputStream os) throws IOException {
            save(new OutputStreamWriter(os, DEFAULT_ENCODING));
        }
    
    Registered: Sun Nov 03 03:35:11 UTC 2024
    - Last Modified: Fri Oct 25 12:31:46 UTC 2024
    - 38.2K bytes
    - Viewed (0)
  9. tests/joins_test.go

    	})
    
    	for idx, user := range users {
    		CheckUser(t, user, users2[idx])
    	}
    }
    
    func TestJoinConds(t *testing.T) {
    	user := *GetUser("joins-conds", Config{Account: true, Pets: 3})
    	DB.Save(&user)
    
    	var users1 []User
    	DB.Joins("inner join pets on pets.user_id = users.id").Where("users.name = ?", user.Name).Find(&users1)
    	if len(users1) != 3 {
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Mon Jun 17 03:58:13 UTC 2024
    - 15K bytes
    - Viewed (0)
  10. docs/sts/keycloak.md

        - Settings
        - Change `Access Type` to `confidential`.
        - Save
      - Click on credentials tab
        - Copy the `Secret` to clipboard.
        - This value is needed for `MINIO_IDENTITY_OPENID_CLIENT_SECRET` for MinIO.
    
    - Go to Users
      - Click on the user
      - Attribute, add a new attribute `Key` is `policy`, `Value` is name of the `policy` on MinIO (ex: `readwrite`)
      - Add and Save
    
    - Go to Clients
      - Click on `account`
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Sep 29 04:28:45 UTC 2022
    - 8.1K bytes
    - Viewed (0)
Back to top