---
lang: en
title: 'API docs: sequelize.sequelizedatasource'
keywords: LoopBack 4.0, LoopBack 4, Node.js, TypeScript, OpenAPI
sidebar: lb4_sidebar
editurl: https://github.com/loopbackio/loopback-next/tree/master/extensions/sequelize
permalink: /doc/en/lb4/apidocs.sequelize.sequelizedatasource.html
---

<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [@loopback/sequelize](./sequelize.md) &gt; [SequelizeDataSource](./sequelize.sequelizedatasource.md)

## SequelizeDataSource class

Sequelize DataSource Class

**Signature:**

```typescript
export declare class SequelizeDataSource implements LifeCycleObserver 
```
**Implements:** [LifeCycleObserver](./core.lifecycleobserver.md)

## Constructors

<table><thead><tr><th>

Constructor


</th><th>

Modifiers


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

[(constructor)(config)](./sequelize.sequelizedatasource._constructor_.md)


</td><td>


</td><td>

Constructs a new instance of the `SequelizeDataSource` class


</td></tr>
</tbody></table>

## Properties

<table><thead><tr><th>

Property


</th><th>

Modifiers


</th><th>

Type


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

[config](./sequelize.sequelizedatasource.config.md)


</td><td>


</td><td>

[SequelizeDataSourceConfig](./sequelize.sequelizedatasourceconfig.md)


</td><td>


</td></tr>
<tr><td>

[name](./sequelize.sequelizedatasource.name.md)


</td><td>


</td><td>

string


</td><td>


</td></tr>
<tr><td>

[parseJsonColumns](./sequelize.sequelizedatasource.parsejsoncolumns.md)


</td><td>

`readonly`


</td><td>

boolean


</td><td>

Gets the flag indicating whether to parse JSON columns. If the `parseJsonColumns` property is set in the configuration, its value will be returned. Otherwise, it returns `true` if the dialect is MySQL, `false` otherwise.


</td></tr>
<tr><td>

[sequelize](./sequelize.sequelizedatasource.sequelize.md)


</td><td>


</td><td>

Sequelize


</td><td>


</td></tr>
<tr><td>

[sequelizeConfig](./sequelize.sequelizedatasource.sequelizeconfig.md)


</td><td>


</td><td>

SequelizeOptions


</td><td>


</td></tr>
<tr><td>

[settings](./sequelize.sequelizedatasource.settings.md)


</td><td>


</td><td>

{}


</td><td>


</td></tr>
</tbody></table>

## Methods

<table><thead><tr><th>

Method


</th><th>

Modifiers


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

[automigrate()](./sequelize.sequelizedatasource.automigrate.md)


</td><td>


</td><td>


</td></tr>
<tr><td>

[autoupdate()](./sequelize.sequelizedatasource.autoupdate.md)


</td><td>


</td><td>


</td></tr>
<tr><td>

[beginTransaction(options)](./sequelize.sequelizedatasource.begintransaction.md)


</td><td>


</td><td>

Begin a new transaction.


</td></tr>
<tr><td>

[execute(command, parameters, options)](./sequelize.sequelizedatasource.execute.md)


</td><td>


</td><td>

Execute a SQL command.

\*\*WARNING:\*\* In general, it is always better to perform database actions through repository methods. Directly executing SQL may lead to unexpected results, corrupted data, security vulnerabilities and other issues.


</td></tr>
<tr><td>

[getPoolOptions()](./sequelize.sequelizedatasource.getpooloptions.md)


</td><td>


</td><td>


</td></tr>
<tr><td>

[init()](./sequelize.sequelizedatasource.init.md)


</td><td>


</td><td>


</td></tr>
<tr><td>

[start(\_injectedArgs)](./sequelize.sequelizedatasource.start.md)


</td><td>


</td><td>


</td></tr>
<tr><td>

[stop()](./sequelize.sequelizedatasource.stop.md)


</td><td>


</td><td>


</td></tr>
</tbody></table>

