Socket
Socket
Sign inDemoInstall

relational-schema

Package Overview
Dependencies
332
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.5.1 to 0.6.0

1

build/src/introspection/mysql-introspection.js

@@ -153,2 +153,3 @@ "use strict";

nullable: is_nullable === 'YES',
characterMaximumLength: null,
columnName: column_name,

@@ -155,0 +156,0 @@ tsType: this.getTsTypeForColumn(table, column_name, data_type, enumTypes[table]),

@@ -28,2 +28,3 @@ import { ColumnType, ConstraintDefinition, EnumDefinitions, LogLevel, RelationDefinition, TableColumnsDefinition, TableMap } from '../types';

* Bulk operation across many tables
*
* @param tables

@@ -30,0 +31,0 @@ * @returns

4

build/src/introspection/postgres-introspection.js

@@ -134,3 +134,3 @@ "use strict";

const rows = yield this.query(this.knex('information_schema.columns')
.select('table_name', 'column_name', 'udt_name', 'is_nullable', 'column_default')
.select('table_name', 'column_name', 'udt_name', 'is_nullable', 'character_maximum_length', 'column_default')
.where({ table_schema: this.schemaName })

@@ -148,2 +148,3 @@ .whereIn('table_name', tables));

nullable: schemaItem.is_nullable === 'YES',
characterMaximumLength: schemaItem.character_maximum_length,
columnName,

@@ -161,2 +162,3 @@ tsType: this.getTsTypeForColumn(table, columnName, dbType, enumTypes[table]),

* Bulk operation across many tables
*
* @param tables

@@ -163,0 +165,0 @@ * @returns

@@ -53,2 +53,3 @@ export declare type EnumType = string;

columnDefault: string | null;
characterMaximumLength: number | null;
tsType?: ColumnType;

@@ -55,0 +56,0 @@ columnName: string;

@@ -0,1 +1,8 @@

# [0.6.0](https://github.com/MattGson/relational-schema/compare/v0.5.1...v0.6.0) (2022-07-25)
### Features
* **postgres:** provides maximum char length for columns ([62c1e5c](https://github.com/MattGson/relational-schema/commit/62c1e5c7754f803366b523e9a61a16930e987d6e))
## [0.5.1](https://github.com/MattGson/relational-schema/compare/v0.5.0...v0.5.1) (2021-10-25)

@@ -2,0 +9,0 @@

{
"name": "relational-schema",
"version": "0.5.1",
"version": "0.6.0",
"description": "Generate a js schema for a relational database",

@@ -5,0 +5,0 @@ "keywords": [

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc