书栈网 · BookStack 本次搜索耗时 0.034 秒,为您找到 469 个相关结果.
  • Getting Started

    Installation Setting up a connection Your first model Application wide model options Promises Installation Sequelize is available via NPM. $ npm install -- save sequeliz...
  • 介绍

    Sequelize Docs 中文版 版本 v6 中文文档 v5 中文文档 v4 中文文档 (停止更新) 文档(v4) 使用示例 赞赏支持 Sequelize Docs 中文版 此项目同步自 sequelize / sequelize 项目中的 docs. 除特殊情况, 将保持每月一次的同步频率. 更新日志请...
  • 第一章 搭建环境

    1286 2020-01-12 《Sequelize ORM 实践》
    搭建环境 搭建环境 本书所有的例子都将使用 TypeScript 语言进行编写,因为这样我们不仅可以得到代码提示,而且还可以使用 async/await 特性 1.创建项目文件夹 mkdir myApp && cd myApp 2.初始化我们的项目 这样我们会得到一个package.json ,来保存我们所有安装的依赖库。 ...
  • Migrations

    The CLI Skeleton Functions createTable(tableName, attributes, options) dropTable(tableName, options) dropAllTables(options) renameTable(before, after, options) showAllTables(...
  • Transactions

    Managed transaction (auto-callback) Throw errors to rollback Automatically pass transactions to all queries Concurrent/Partial transactions Without CLS enabled Isolation level...
  • Model definition

    Model definition Model definition To define mappings between a model and a table, use the define method. Each column must have a datatype, see more about datatypes . class ...
  • TypeScript

    TypeScript Installation Usage Usage without strict types for attributes Usage of sequelize.define TypeScript Since v5, Sequelize provides its own TypeScript definitions. P...
  • 表建模

    表建模 更改默认模型参数 表建模 模型是一个扩展 Sequelize.Model 的类. 模型可以用两种等效方式定义. 第一个是Sequelize.Model.init(属性,参数): const Model = Sequelize . Model ; class User extends Model {} Use...
  • Dialect-Specific Things

    Dialect-Specific Things Underlying Connector Libraries MySQL MariaDB SQLite PostgreSQL MSSQL MSSQL Domain Account Data type: TIMESTAMP WITHOUT TIME ZONE - PostgreSQL only D...
  • Model Basics

    Model Basics Concept Model Definition Using sequelize.define : Extending Model Table name inference Enforcing the table name to be equal to the model name Providing the tab...