Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 346 for database (0.99 sec)

  1. docs/en/docs/how-to/async-sql-encode-databases.md

    !!! tip
        You could adopt ideas from the section about SQLAlchemy ORM ([SQL (Relational) Databases](../tutorial/sql-databases.md){.internal-link target=_blank}), like using utility functions to perform operations in the database, independent of your **FastAPI** code.
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu Apr 18 19:53:19 UTC 2024
    - 5.3K bytes
    - Viewed (0)
  2. docs_src/async_sql_databases/tutorial001.py

    from typing import List
    
    import databases
    import sqlalchemy
    from fastapi import FastAPI
    from pydantic import BaseModel
    
    # SQLAlchemy specific code, as with any other app
    DATABASE_URL = "sqlite:///./test.db"
    # DATABASE_URL = "postgresql://user:password@postgresserver/db"
    
    database = databases.Database(DATABASE_URL)
    
    metadata = sqlalchemy.MetaData()
    
    notes = sqlalchemy.Table(
        "notes",
        metadata,
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu Mar 26 19:09:53 UTC 2020
    - 1.4K bytes
    - Viewed (0)
  3. docs/em/docs/how-to/sql-databases-peewee.md

    #### 🏒 🗳
    
    🚥 👆 ⚙️ <a href="https://docs.peewee-orm.com/en/latest/peewee/database.html#dynamically-defining-a-database" class="external-link" target="_blank">🏒 🗳</a>, ☑ 💽 `db.obj`.
    
    , 👆 🔜 ⏲ ⚫️ ⏮️:
    
    ```Python hl_lines="3-4"
    async def reset_db_state():
        database.db.obj._state._state.set(db_state_default.copy())
        database.db.obj._state.reset()
    ```
    
    ### ✍ 👆 **FastAPI** *➡ 🛠️*
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu Apr 18 19:53:19 UTC 2024
    - 19.2K bytes
    - Viewed (0)
  4. src/database/sql/doc.txt

      about every particular db's extension or quirk.
    
    * Separate out the basic implementation of a database driver
      (implementing the sql/driver interfaces) vs the implementation
      of all the user-level types and convenience methods.
      In a nutshell:
    
      User Code ---> sql package (concrete types) ---> sql/driver (interfaces)
      Database Driver -> sql (to register) + sql/driver (implement interfaces)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 22 06:48:08 UTC 2024
    - 2.1K bytes
    - Viewed (0)
  5. api/go1.8.txt

    pkg database/sql, const LevelDefault = 0
    pkg database/sql, const LevelDefault IsolationLevel
    pkg database/sql, const LevelLinearizable = 7
    pkg database/sql, const LevelLinearizable IsolationLevel
    pkg database/sql, const LevelReadCommitted = 2
    pkg database/sql, const LevelReadCommitted IsolationLevel
    pkg database/sql, const LevelReadUncommitted = 1
    pkg database/sql, const LevelReadUncommitted IsolationLevel
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Dec 21 05:25:57 UTC 2016
    - 16.3K bytes
    - Viewed (0)
  6. docs_src/sql_databases_peewee/sql_app/main.py

    from fastapi import Depends, FastAPI, HTTPException
    
    from . import crud, database, models, schemas
    from .database import db_state_default
    
    database.db.connect()
    database.db.create_tables([models.User, models.Item])
    database.db.close()
    
    app = FastAPI()
    
    sleep_time = 10
    
    
    async def reset_db_state():
        database.db._state._state.set(db_state_default.copy())
        database.db._state.reset()
    
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu Mar 26 19:09:53 UTC 2020
    - 2.2K bytes
    - Viewed (0)
  7. src/cmd/go/internal/modfetch/sumdb.go

    		return
    	}
    
    	// Try proxies in turn until we find out how to connect to this database.
    	//
    	// Before accessing any checksum database URL using a proxy, the proxy
    	// client should first fetch <proxyURL>/sumdb/<sumdb-name>/supported.
    	//
    	// If that request returns a successful (HTTP 200) response, then the proxy
    	// supports proxying checksum database requests. In that case, the client
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 20 15:02:47 UTC 2023
    - 9.1K bytes
    - Viewed (0)
  8. src/database/sql/driver/driver.go

    // Pinger is an optional interface that may be implemented by a [Conn].
    //
    // If a [Conn] does not implement Pinger, the [database/sql.DB.Ping] and
    // [database/sql.DB.PingContext] will check if there is at least one [Conn] available.
    //
    // If Conn.Ping returns [ErrBadConn], [database/sql.DB.Ping] and [database/sql.DB.PingContext] will remove
    // the [Conn] from pool.
    type Pinger interface {
    	Ping(ctx context.Context) error
    }
    
    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. docs_src/sql_databases_peewee/sql_app/models.py

    import peewee
    
    from .database import db
    
    
    class User(peewee.Model):
        email = peewee.CharField(unique=True, index=True)
        hashed_password = peewee.CharField()
        is_active = peewee.BooleanField(default=True)
    
        class Meta:
            database = db
    
    
    class Item(peewee.Model):
        title = peewee.CharField(index=True)
        description = peewee.CharField(index=True)
        owner = peewee.ForeignKeyField(User, backref="items")
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu Mar 26 19:09:53 UTC 2020
    - 465 bytes
    - Viewed (0)
  10. src/database/sql/example_cli_test.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package sql_test
    
    import (
    	"context"
    	"database/sql"
    	"flag"
    	"log"
    	"os"
    	"os/signal"
    	"time"
    )
    
    var pool *sql.DB // Database connection pool.
    
    func Example_openDBCLI() {
    	id := flag.Int64("id", 0, "person ID to find")
    	dsn := flag.String("dsn", os.Getenv("DSN"), "connection data source name")
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun May 08 17:27:54 UTC 2022
    - 2K bytes
    - Viewed (0)
Back to top