Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

mysql-query-validator

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mysql-query-validator

This is just a simple wrapper over [this Golang executable](https://github.com/xwb1989/sqlparser) to validate SQL queries.

  • 0.0.4
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

mysql-query-validator

This is just a simple wrapper over this Golang executable to validate SQL queries.

Installation

yarn add mysql-query-validator

Example

import { validate } from 'mysql-query-validator'

try {
  validate(`
    create table test (
      id varchar(20) not null,
      created_at datetime(6),
      slug varbinary(255),
      enabled tinyint(1),
      labels json // missing comma
      url blob
    )
  `)
} catch (err) {
  console.error(err.message) // syntax error at position N near 'url'
}

Keywords

FAQs

Package last updated on 19 Dec 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc