New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

knex-dialect-athena

Package Overview
Dependencies
Maintainers
0
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

knex-dialect-athena

A Knex dialect for AWS Athena

latest
Source
npmnpm
Version
0.0.12
Version published
Maintainers
0
Created
Source

knex-dialect-athena

A Knex dialect for AWS Athena.

Installation

Using your favorite package manager, install knex-dialect-athena, along with its peer dependencies (if you don't already have them installed):

npm install knex-dialect-athena knex @aws-sdk/client-athena

Usage

This package exports the createAthenaDialect function, the result of which can be passed to knex's client option:

import Knex from "knex";
import { createAthenaDialect } from "knex-dialect-athena";

const knex = Knex({
  client: createAthenaDialect({
    database: "my-database-name",
    outputLocation: "s3://my/output/location",
    // Additional `AthenaClient` options can go here:
    // region: "..."
  }),
});

interface User {
  id: number;
  name: string;
  age: number;
}

// Retrieves the data from the provided Athena database
const user = await knex<User>("users").where("id", 1).first();

Keywords

knex

FAQs

Package last updated on 14 Nov 2024

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