The hssqlppp package
Sql parser, pretty printer and type checker, targets PostGreSQL SQL and PL/pgSQL, uses Parsec and UUAGC.
Overview:
see the module Ast for the ast types;
Parser for converting text to asts;
PrettyPrinter for converting asts to text;
AnnotateSource for pretty printing annotations inline with original source;
Annotator for annotating asts (this does the type checking); and working with annotated trees;
SqlTypes for the data types which represent SQL types, the data type for type errors, and some support functions;
Annotation for the annotation data types and utilities, this also contains the data types for SQL types;
Environment to read a catalog from a database to type check against, or to generate catalog information;
DatabaseLoader for the beginnings of a routine to load SQL into a database (e.g. to generate an ast then load it into a database without loading it via psql). The loader just about does the job but error handling is a bit crap at the moment.
Comes with a HUnit test suite which you can run using the HsSqlPppTests executable, and command line access to some functions via a exe called HsSqlSystem, run this file with no arguments to get some help. See the project page https://launchpad.net/hssqlppp for more information and documentation links.
Properties
| Versions | 0.0.4, 0.0.5, 0.0.6, 0.0.7, 0.0.8, 0.0.9, 0.0.10, 0.1.0, 0.2.0, 0.3.0, 0.3.1, 0.4.0 |
|---|---|
| Dependencies | base (≥3 & <5), containers, directory, haskell98, HDBC, HDBC-postgresql, HUnit, mtl, parsec (≥3), pretty, regex-posix, test-framework, test-framework-hunit |
| License | BSD3 |
| Copyright | Copyright 2009 Jake Wheat |
| Author | Jake Wheat |
| Maintainer | jakewheatmail@gmail.com |
| Stability | pre-alpha |
| Category | Database |
| Home page | https://launchpad.net/hssqlppp |
| Bug tracker | mailto:jakewheatmail@gmail.com |
| Executables | HsSqlPppTests, HsSqlSystem |
| Upload date | Mon Sep 28 22:14:53 UTC 2009 |
| Uploaded by | JakeWheat |
| Build failure | ghc-6.12 (log) |
Modules
- Database
- HsSqlPpp
- Ast
- Database.HsSqlPpp.Ast.Annotation
- Database.HsSqlPpp.Ast.Annotator
- Database.HsSqlPpp.Ast.Ast
- Database.HsSqlPpp.Ast.Environment
- Database.HsSqlPpp.Ast.SqlTypes
- Dbms
- Database.HsSqlPpp.Dbms.DatabaseLoader
- Parsing
- Database.HsSqlPpp.Parsing.Parser
- PrettyPrinter
- Database.HsSqlPpp.PrettyPrinter.AnnotateSource
- Database.HsSqlPpp.PrettyPrinter.PrettyPrinter
- Ast
- HsSqlPpp
Downloads
- hssqlppp-0.0.7.tar.gz (Cabal source package)
- package description (included in the package)