Coder Social home page Coder Social logo

java-sql-generator's Issues

Make SQLVendors more customizable

Currently SQLVendor provides read-only API for its services. It should be possible to customize it more by adding custom factories and processors.

LIMIT clause support outside of PgSQL interface

Seems odd that LIMIT would only be within the pgsql API, given that it's hardly the only database to support it -- e.g. MySQL has supported both LIMIT and OFFSET for years, and not having LIMIT support can result in some ridiculously inefficient queries.

Arithmetic statements

Currently there are no arithmetic expressions. Implement the API and implementation for these.

Create more tests, which actually test something

Currently the tests of Java-SQL-Generator mainly create some SQL statement and output it to log. Any exception raised during the test will fail it, however, the actual generated contents are never checked to hold. Make the tests actually validate the contents of the generated SQL string. Additionally, implement a lot more tests to cover all provided functionality.

More simple ways to create queries

Currently it is not very easy to create even really simple queries. Introduce some kind of "SimpleQueryBuilder", which provides light-weight support for building SIMPLE queries (ie, no need to support all kinds of complex features, just a sub-set of existing ones).

Add selectAll to SimpleQueryBuilder

Right now, in order to select all columns, one has to do 'select("*")' in the SimpleQueryBuilder. The builder should be extended with "selectAll()" method, which marks that the query should select all columns, without the need of using string literals.

Convert all enums to String for better extensibility.

Some things may seem really non-extensible in SQL 99 BNF document, yet some RDB vendors provide extensions to them. Currently, some things are defiend using enum keyword. Make all enum values into strings so that they may be extended more easily.

Provide construct to create database generated columns

Hi Stan,

I would like to create table columns with the following definition:

"my_pk_column BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY"

I did not found any way to do so in current version, tell me if I'm wrong.

/Paul

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.