New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mattbauer-vertica

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mattbauer-vertica

  • 0.7.3
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

h1. Vertica

by Matt Bauer

h2. Description

Vertica is a pure Ruby library for connecting to Vertica databases. You can learn more about Vertica at http://www.vertica.com. This library currently supports queries and prepared statements.

h2. Install

$ gem install mattbauer-vertica --source http://gems.github.com

h2. Source

Vertica's git repo is available on GitHub, which can be browsed at:

http://github.com/mattbauer/vertica

and cloned from:

git://github.com/mattbauer/vertica.git

h2. Usage

h4. Example Query


  c = Vertica::Connection.new(
    :user     => 'user',
    :password => 'password',
    :host     => 'db_server',
    :port     => '5433',
    :database => 'db
  )
  r = c.query("SELECT * FROM my_table")
  puts r.row_count
  puts r.columns[0].name
  puts r.rows
  c.close

h4. Example Prepared Statement


  c = Vertica::Connection.new(
    :user     => 'user',
    :password => 'password',
    :host     => 'db_server',
    :port     => '5433',
    :database => 'db
  )
  c.prepare("my_prepared_statement", "SELECT * FROM my_table WHERE id = ?", 1)
  r = c.execute_prepared("my_prepared_statement", 13)
  puts r.row_count
  puts r.columns[0].name
  puts r.rows
  c.close

h2. Running The Tests

To run the tests, change the values in test_helper.rb to match your db configuration. Then execute the create_schema.sql on the database. Then you may run the tests.

FAQs

Package last updated on 11 Aug 2014

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