hoonsbara / octalforty-wizardby

Automatically exported from code.google.com/p/octalforty-wizardby
1 stars 0 forks source link

Extend syntax for type shortcuts #21

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Usual type declarations are too wordy:

    add column Foo type => String, nullable => false, length => 200

This can be shortened to:

    add column Foo type => "String!(200)"

Proposed notation is as follows:

    <TypeName><Nullability>[(<Length>)]
    <TypeName><Nullability>(<Scale>, <Precision>)

Here: 
* <TypeName> is standard DbType enumeration member (case-insensitive due to 
issue 20)
* <Nullability> is either "?" for nullable or "!" for non-nullable
* <Length> is an optional integer
* <Scale> and <Precision> are pretty much self explanatory

Original issue reported on code.google.com by anton.go...@gmail.com on 28 Jul 2010 at 8:52

GoogleCodeExporter commented 8 years ago

Original comment by anton.go...@gmail.com on 28 Jul 2010 at 8:52

GoogleCodeExporter commented 8 years ago
This issue was updated by revision r154.

Original comment by anton.go...@gmail.com on 28 Jul 2010 at 8:53