Skip to content
This repository has been archived by the owner on Nov 13, 2024. It is now read-only.

Latest commit

 

History

History
149 lines (112 loc) · 2.87 KB

README.md

File metadata and controls

149 lines (112 loc) · 2.87 KB

python-string-parsing

Note: this repo is a demo to accompany this blog post. As such, it is not actively maintained.

Prerequisites

Verify that both python3 and git are installed and available:

python3 --version
git --version

Clone

Clone this repo using your method of choice:

HTTPS
git clone https://github.com/dbt-labs/demo-python-blog.git
cd demo-python-blog
SSH
git clone git@github.com:dbt-labs/demo-python-blog.git
cd demo-python-blog
GitHub CLI
gh repo clone dbt-labs/demo-python-blog
cd demo-python-blog

Install

Create a virtual environment and install dependencies:

POSIX bash/zsh
python3 -m venv env
source env/bin/activate
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements.txt --use-pep517
source env/bin/activate
POSIX fish
python3 -m venv env
source env/bin/activate.fish
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements.txt --use-pep517
source env/bin/activate.fish
POSIX csh/tcsh
python3 -m venv env
source env/bin/activate.csh
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements.txt --use-pep517
source env/bin/activate.csh
POSIX PowerShell Core
python3 -m venv env
env/bin/Activate.ps1
python3 -m pip install --upgrade pip
python3 -m pip install -r requirements.txt --use-pep517
env/bin/Activate.ps1
Windows cmd.exe
python -m venv env
env\Scripts\activate.bat
python -m pip install --upgrade pip
python -m pip install -r requirements.txt --use-pep517
env\Scripts\activate.bat
Windows PowerShell
python -m venv env
env\Scripts\Activate.ps1
python -m pip install --upgrade pip
python -m pip install -r requirements.txt --use-pep517
env\Scripts\Activate.ps1

Run

Build the project:

dbt build

Query

Examine the output:

duckcli demo.duckdb --table --execute "select id, transaction_time, parsed_transaction_time from transactions order by id"

Wrap up

Deactivate the virtual environment when finished:

deactivate

Credits

This initial version of this demo was powered by components built by Features & Labels.

You can check out their Loom demo and instructions.