Skip to main content

A pyparsing-based library for parsing SOQL statements

Project description

CONTRIBUTORS WANTED!!

Installation

pip install python-soql-parser

or, with poetry

poetry add python-soql-parser

Usage

from python_soql_parser import parse


parse_result = parse("SELECT Id FROM Account")

where parse_result is a ParseResults object from pyparsing.

Notable caveats

Unsupported features

  • Subqueries (e.g., SELECT Name, (SELECT LastName FROM Contacts) FROM Account)
  • Aggregate queries
  • SOQL specific WHERE-clause tokens (e.g., LAST_N_DAYS:<integer>)

Partially supported

These are either partially supported or weakly supported

  • Related attributes (e.g., SELECT Id, Account.Name FROM Contact). The object name is not yet parsed out on its own. This will simply parse out "Account.Name"

Contributing

A lot of work remains to be done. Practically no SOQL-specific features are supported as of yet. If you want to contribute, just open a PR! (and add a test for your new feature)

Setting up locally

First install poetry. Afterwards, to install the dependencies, run

poetry install

Running the tests

Simply execute

pytest

House cleaning

Please sort imports with isort and format the code with black (in that order).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

python-soql-parser-0.1.9.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

python_soql_parser-0.1.9-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file python-soql-parser-0.1.9.tar.gz.

File metadata

  • Download URL: python-soql-parser-0.1.9.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.4 CPython/3.8.7 Windows/10

File hashes

Hashes for python-soql-parser-0.1.9.tar.gz
Algorithm Hash digest
SHA256 d5c0b267fd572c2ce59f3622ad8bfc04ab71311c319da6770011e9c2072f358d
MD5 b84c68b83b49a74783f488d56973b798
BLAKE2b-256 f0c0f0afa566fdc5401424fd3e1ce420f7078909c8daa0a0b8073daf2d9d685e

See more details on using hashes here.

File details

Details for the file python_soql_parser-0.1.9-py3-none-any.whl.

File metadata

File hashes

Hashes for python_soql_parser-0.1.9-py3-none-any.whl
Algorithm Hash digest
SHA256 78522f4f0c7fd99a2d4722d5cce5200ca3a531b6d8ee637d2b8fb75a7d8496b1
MD5 dba0e70174228e5f391e034ec9fbc299
BLAKE2b-256 6b5e566a91cbe4a7ae6ebfaa0a9929de07aaf1250b644594cd2bf87835782543

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page