# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 3
#     language: python
#     name: python3
# ---

# Python notebook to demonstrate Vertica connection and simple queries and plots from Vertica system tables

# %matplotlib notebook
import vertica_python
# fill in your database info here
conn_info = {'host': '10.0.2.15', 
             'port' : 5433, 
             'user': 'dbadmin', 
             'password':'<PASSWORD>', 
             'database': 'VMart', 
             'read_timeout': 600, 'unicode_error': 'strict', 'ssl': False, 'connection_timeout': 5}
# quick connection test
with vertica_python.connect(**conn_info) as connection:
    cur = connection.cursor()
    cur.execute("SELECT VERSION();")
    for row in cur.iterate():
        print(row)



StarcoderdataJupyterScriptsDedupFiltered