Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

287
Vistas
Execute queries on Amazon Redshift using the AWS SDK for JavaScript

I have been following aws-sdk for javascript to execute sql queries on redshift cluster but haven't been able to connect.

Can someone guide me regarding module to use for redshift connection in javascript (except node-redshift) or share a skeleton code with proper parameter names?

Using @aws-sdk/client-redshift

const RedShiftClient = new RedshiftClient({region:'us-west-2'});
const params = {
  ClusterIdentified:'clustername-xxx-aws.com',
  NodeType: 'nodetype',
  MasterUsername:'user',
  MasterPassword:'password',
  ClusterType:'clustertype'
};

const command = new AcceptReservedNodeExchangeCommand(params);
redshiftClient.send(command)
.then(res=>{
//dosomething
})
.catch(err=>{
console.log(err);
});

Receiving error : 2 validation errors found: Value null at 'targeReservedNodeOfferingId' failed to satisfy constraint. Member cannot be null. Value null at 'reserverNodeId' failed to satify constraint. Member cannot be null.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

To execute queries on Amazon Redshift using JavaScript, use RedshiftDataClient (not RedShiftClient ). There are examples in the previous link. This is part of the AWS SDK for JavaScript v3.

To use a RedshiftDataClient object to query data, you can use the following Amazon Redshift values:

  • The name of the database (for example, dev)
  • The name of the database user that you configured
  • The name of the Amazon Redshift cluster (for example, redshift-cluster-1)

These values are used when creating an ExecuteStatementCommand as discussed here:

https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-redshift-data/classes/executestatementcommand.html

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda