- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 908 for Where (0.03 sec)
-
tests/query_test.go
DB.Create(&user) var result User if DB.Where("").Where("").First(&result).Error != nil { t.Errorf("Should not raise any error if searching with empty strings") } result = User{} if DB.Where(&User{}).Where("name = ?", user.Name).First(&result).Error != nil { t.Errorf("Should not raise any error if searching with empty struct") } result = User{}
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Jun 24 09:42:59 UTC 2024 - 50.4K bytes - Viewed (0) -
docs/en/docs/how-to/conditional-openapi.md
* Implement and use well-known cryptographic tools, like Passlib and JWT tokens, etc. * Add more granular permission controls with OAuth2 scopes where needed. * ...etc. Nevertheless, you might have a very specific use case where you really need to disable the API docs for some environment (e.g. for production) or depending on configurations from environment variables. ## Conditional OpenAPI from settings and env vars
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Mon Oct 28 11:21:54 UTC 2024 - 2.3K bytes - Viewed (0) -
chainable_api.go
tx.Statement.ColumnMapping = m return } // Where add conditions // // See the [docs] for details on the various formats that where clauses can take. By default, where clauses chain with AND. // // // Find the first user with name jinzhu // db.Where("name = ?", "jinzhu").First(&user) // // Find the first user with name jinzhu and age 20 // db.Where(&User{Name: "jinzhu", Age: 20}).First(&user)
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Jun 24 09:42:59 UTC 2024 - 14.8K bytes - Viewed (0) -
tests/scan_test.go
Age int } var res result DB.Table("users").Select("id, name, age").Where("id = ?", user3.ID).Scan(&res) if res.ID != user3.ID || res.Name != user3.Name || res.Age != int(user3.Age) { t.Fatalf("Scan into struct should work, got %#v, should %#v", res, user3) } var resPointer *result if err := DB.Table("users").Select("id, name, age").Where("id = ?", user3.ID).Scan(&resPointer).Error; err != nil {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 12 10:57:36 UTC 2024 - 10.9K bytes - Viewed (0) -
docs/en/docs/how-to/custom-docs-ui-assets.md
* `openapi_url`: the URL where the HTML page for the docs can get the OpenAPI schema for your API. You can use here the attribute `app.openapi_url`. * `title`: the title of your API. * `oauth2_redirect_url`: you can use `app.swagger_ui_oauth2_redirect_url` here to use the default. * `swagger_js_url`: the URL where the HTML for your Swagger UI docs can get the **JavaScript** file. This is the custom CDN URL.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Mon Oct 28 10:42:34 UTC 2024 - 7.3K bytes - Viewed (0) -
tests/joins_test.go
DB.Save(&user) // test where var user1 User onQuery := DB.Where(&Pet{Name: "joins-args-db_pet_2"}) if err := DB.Joins("NamedPet", onQuery).Where("users.name = ?", user.Name).First(&user1).Error; err != nil { t.Fatalf("Failed to load with joins on, got error: %v", err) } AssertEqual(t, user1.NamedPet.Name, "joins-args-db_pet_2") // test where and omit
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Jun 17 03:58:13 UTC 2024 - 15K bytes - Viewed (0) -
docs/en/docs/advanced/openapi-webhooks.md
# OpenAPI Webhooks There are cases where you want to tell your API **users** that your app could call *their* app (sending a request) with some data, normally to **notify** of some type of **event**. This means that instead of the normal process of your users sending requests to your API, it's **your API** (or your app) that could **send requests to their system** (to their API, their app). This is normally called a **webhook**. ## Webhooks steps
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Mon Oct 28 10:38:23 UTC 2024 - 2.8K bytes - Viewed (0) -
internal/s3select/sql/statement.go
err = errQueryAnalysisFailure(err) return } // Analyze where clause if selectAST.Where != nil { whereQProp := selectAST.Where.analyze(&selectAST) if whereQProp.err != nil { err = errQueryAnalysisFailure(fmt.Errorf("Where clause error: %w", whereQProp.err)) return } if whereQProp.isAggregation { err = errQueryAnalysisFailure(errors.New("WHERE clause cannot have an aggregation")) return } }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Sep 23 19:35:41 UTC 2024 - 8.9K bytes - Viewed (0) -
guava-tests/benchmark/com/google/common/base/StopwatchBenchmark.java
Stopwatch s = Stopwatch.createStarted(); // here is where you would do something total += s.elapsed(NANOSECONDS); } return total; } @Benchmark long manual(int reps) { long total = 0; for (int i = 0; i < reps; i++) { long start = System.nanoTime(); // here is where you would do something total += (System.nanoTime() - start); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:26:48 UTC 2024 - 1.5K bytes - Viewed (0) -
finisher_api.go
}) if tx = queryTx.Find(dest, conds...); tx.RowsAffected == 0 { if c, ok := tx.Statement.Clauses["WHERE"]; ok { if where, ok := c.Expression.(clause.Where); ok { tx.assignInterfacesToValue(where.Exprs) } } // initialize with attrs, conds if len(tx.Statement.attrs) > 0 { tx.assignInterfacesToValue(tx.Statement.attrs...) } }
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Sat Sep 14 12:58:29 UTC 2024 - 22.8K bytes - Viewed (0)