Help us shape the future of Go! Take the 2026 Go Developer Survey

dbc

package module
v0.3.0-rc Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 16, 2026 License: Apache-2.0 Imports: 28 Imported by: 0

README

dbc dbc Logo

License GitHub release (latest SemVer) Release dbc

dbc is the command-line tool for installing and managing ADBC drivers.

Install dbc

Shell (Linux/macOS)
curl -LsSf https://dbc.columnar.tech/install.sh | sh
Homebrew
brew install columnar-tech/tap/dbc
uv
uv tool install dbc
pipx
pipx install dbc
PowerShell (Windows)
powershell -ExecutionPolicy ByPass -c irm https://dbc.columnar.tech/install.ps1 | iex
WinGet
winget install dbc
Windows MSI

Download the MSI installer

For more installation options, see the installation docs.

Getting Started

Search for available drivers:

dbc search

Install a driver:

dbc install snowflake

Use it with Python:

pip install "adbc-driver-manager>=1.8.0"
import adbc_driver_manager.dbapi as adbc

with adbc.connect(
    driver="snowflake",
    db_kwargs={
        "username": "USER",
        "password": "PASS",
        "adbc.snowflake.sql.account": "ACCOUNT-IDENT",
        # ... other connection options
    },
) as con, con.cursor() as cursor:
    cursor.execute("SELECT * FROM CUSTOMER LIMIT 5")
    print(cursor.fetch_arrow_table())

You can also manage drivers in a project using a driver list. And you can store connection options in a connection profile instead of in your code.

For more details, see the dbc documentation and the ADBC Quickstarts.

Communications

Code of Conduct

By contributing to dbc, you agree to follow our Code of Conduct.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnauthorized         = errors.New("not authorized")
	ErrUnauthorizedColumnar = errors.New("not authorized to access")
)
View Source
var (
	Version = "unknown"

	// use this default client for all requests,
	// it will add the dbc user-agent to all requests
	DefaultClient = http.DefaultClient
)

Functions

func SignedByColumnar

func SignedByColumnar(lib, sig io.Reader) error

SignedByColumnar returns nil if the library was signed by the columnar public key (embedded in the CLI) or an error otherwise.

Types

type Driver

type Driver struct {
	Registry *Registry `yaml:"-"`

	Title   string    `yaml:"name"`
	Desc    string    `yaml:"description"`
	License string    `yaml:"license"`
	Path    string    `yaml:"path"`
	URLs    []string  `yaml:"urls"`
	DocsUrl string    `yaml:"docs_url"`
	PkgInfo []pkginfo `yaml:"pkginfo"`
}

func GetDriverList

func GetDriverList() ([]Driver, error)

func (Driver) GetPackage

func (d Driver) GetPackage(version *semver.Version, platformTuple string, allowPrerelease bool) (PkgInfo, error)

func (Driver) GetWithConstraint

func (d Driver) GetWithConstraint(c *semver.Constraints, platformTuple string) (PkgInfo, error)

func (Driver) HasNonPrerelease added in v0.2.0

func (d Driver) HasNonPrerelease() bool

func (Driver) MaxVersion

func (d Driver) MaxVersion() pkginfo

func (Driver) Versions

func (d Driver) Versions(platformTuple string) semver.Collection

type FileProgressModel

type FileProgressModel struct {
	progress.Model
	// contains filtered or unexported fields
}

func NewFileProgress

func NewFileProgress(opts ...progress.Option) FileProgressModel

func (FileProgressModel) Init

func (m FileProgressModel) Init() tea.Cmd

func (FileProgressModel) Percent

func (m FileProgressModel) Percent() int

func (*FileProgressModel) SetPercent

func (m *FileProgressModel) SetPercent(written, total int64) tea.Cmd

func (FileProgressModel) Update

func (m FileProgressModel) Update(msg tea.Msg) (FileProgressModel, tea.Cmd)

func (FileProgressModel) View

func (m FileProgressModel) View() string

type PkgInfo

type PkgInfo struct {
	Driver        Driver
	Version       *semver.Version
	PlatformTuple string

	Path *url.URL
}

func (PkgInfo) DownloadPackage

func (p PkgInfo) DownloadPackage(prog ProgressFunc) (*os.File, error)

type ProgressFunc

type ProgressFunc func(written, total int64)

type Registry added in v0.2.0

type Registry struct {
	Name    string
	Drivers []Driver
	BaseURL *url.URL
}

type SimpleItemDelegate

type SimpleItemDelegate struct {
	Prompt string
}

func (SimpleItemDelegate) Height

func (d SimpleItemDelegate) Height() int

func (SimpleItemDelegate) Render

func (d SimpleItemDelegate) Render(w io.Writer, m list.Model, index int, listItem list.Item)

func (SimpleItemDelegate) Spacing

func (d SimpleItemDelegate) Spacing() int

func (SimpleItemDelegate) Update

func (d SimpleItemDelegate) Update(tea.Msg, *list.Model) tea.Cmd

Directories

Path Synopsis
cmd
dbc command

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL