{"id":43864,"library":"speedt-mysql","title":"speedt-mysql","description":"A lightweight MySQL client library for Node.js, version 0.1.65. Provides basic database connection and query functionality with a simple API. Release cadence is irregular with limited maintenance. Differentiators: minimal dependencies and straightforward usage for small projects, but lacks advanced features like connection pooling or prepared statements found in more mature libraries like mysql2 or knex.","status":"active","version":"0.1.65","language":"javascript","source_language":"en","source_url":"https://github.com/speedt/speedt-mysql","tags":["javascript","mysql"],"install":[{"cmd":"npm install speedt-mysql","lang":"bash","label":"npm"},{"cmd":"yarn add speedt-mysql","lang":"bash","label":"yarn"},{"cmd":"pnpm add speedt-mysql","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Core MySQL driver for Node.js","package":"mysql","optional":false}],"imports":[{"note":"Library uses ESM default export. In CommonJS, use dynamic import: const mysql = await import('speedt-mysql')","wrong":"const mysql = require('speedt-mysql')","symbol":"default","correct":"import mysql from 'speedt-mysql'"},{"note":"Named export for query function, not available in CommonJS require","wrong":"const { query } = require('speedt-mysql')","symbol":"query","correct":"import { query } from 'speedt-mysql'"},{"note":"Export is 'connection' not 'connect'. Use to create a connection object.","wrong":"import { connect } from 'speedt-mysql'","symbol":"connection","correct":"import { connection } from 'speedt-mysql'"}],"quickstart":{"code":"import mysql from 'speedt-mysql';\n\nconst connection = mysql.createConnection({\n  host: 'localhost',\n  user: 'root',\n  password: process.env.DB_PASS ?? '',\n  database: 'test'\n});\n\nconnection.query('SELECT * FROM users', (err, results) => {\n  if (err) throw err;\n  console.log(results);\n});","lang":"javascript","description":"Creates a MySQL connection and executes a simple SELECT query using callbacks."},"warnings":[{"fix":"Use a connection pooling library like mysql2 with pool, or manage connections manually.","message":"No built-in connection pooling; creating many connections will exhaust resources.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Wrap queries in Promise: new Promise((resolve, reject) => connection.query(sql, (err, res) => err ? reject(err) : resolve(res))).","message":"Callback-based API; no Promise support by default. Query results require callbacks.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Check documentation for alternative method or migrate to mysql2.","message":"The createConnection method may be deprecated in future versions.","severity":"deprecated","affected_versions":"0.1.60-0.1.65"}],"env_vars":null,"search_vec":"'0.1.65':12 'advanc':42 'api':23 'basic':14 'cadenc':25 'client':7 'connect':16,45 'databas':15 'depend':33 'differenti':31 'featur':43 'found':50 'function':19 'irregular':27 'javascript':59 'knex':58 'lack':41 'librari':8,54 'lightweight':5 'like':44,55 'limit':29 'mainten':30 'matur':53 'minim':32 'mysql':3,6,60 'mysql2':56 'node.js':10 'pool':46 'prepar':48 'project':39 'provid':13 'queri':18 'releas':24 'simpl':22 'small':38 'speedt':2 'speedt-mysql':1 'statement':49 'straightforward':35 'usag':36 'version':11","created_at":"2026-06-05T17:01:50.836580+00:00","updated_at":"2026-06-05T17:01:50.836580+00:00","problems":[{"fix":"Install with 'npm install speedt-mysql' and ensure your Node.js version supports ESM (>=13.2) or use dynamic import.","cause":"Package not installed or incorrect import path.","error":"Error: Cannot find module 'speedt-mysql'"},{"fix":"Use default import: 'import mysql from 'speedt-mysql'' or 'const mysql = await import('speedt-mysql')'.","cause":"Wrong import style: using require in CJS or destructuring incorrectly.","error":"TypeError: mysql.createConnection is not a function"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/speedt/speedt-mysql","github":"https://github.com/speedt/speedt-mysql","docs":null,"changelog":null,"pypi":null,"npm":"speedt-mysql","openapi_spec":null,"status_page":null,"smithery":null,"categories":["database"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-05","next_check":"2026-09-03","install_tag":null}}