Scott Gray
75b0b1c1e3
Remove unnecessary semicolons
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1044917 13f79535-47bb-0310-9956-ffa450edef68
2010-12-12 20:43:03 +00:00
Scott Gray
bdd23c22d5
Add missing override annotations
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1044913 13f79535-47bb-0310-9956-ffa450edef68
2010-12-12 20:41:27 +00:00
Adam Heath
d06f72f7f9
FEATURE: Start of union support; parsing isn't tested yet.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981640 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:44:20 +00:00
Adam Heath
872db5befd
FEATURE: Start of aggregate function support.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981639 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:44:12 +00:00
Adam Heath
550d275781
FEATURE: Add count-all variant that doesn't require a table name.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981638 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:44:05 +00:00
Adam Heath
ca01d94d2a
FEATURE: Add support for CREATE INDEX.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981637 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:44:00 +00:00
Adam Heath
56c7c3391a
FEATURE: ORDER BY now supports any ConstantValue, which includes any
...
function, and also math operations.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981636 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:53 +00:00
Adam Heath
f7ad0f1ea6
Allow external callers to parse individual OrderByItem instances.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981634 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:42 +00:00
Adam Heath
055e49cb5a
FEATURE: Add support for NULLS FIRST/LAST in ORDER BY.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981633 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:36 +00:00
Adam Heath
8ebec8e647
OPTIMIZE: Remove descending and orderingSet booleans, they weren't being used
...
properly.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981632 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:30 +00:00
Adam Heath
5147b48afa
TESTS: Ensure that no more statements has been parsed.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981631 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:25 +00:00
Adam Heath
eebce0b77f
BUG FIX: Fix parsing of -/+ style order by prefixes.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981630 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:19 +00:00
Adam Heath
6772e47dd6
FEATURE: Add basic implementations of the available visitors.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981629 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:13 +00:00
Adam Heath
2923612353
OPTIMIZE: Remove unused variable i from Select().
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981628 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:08 +00:00
Adam Heath
f150eecfb9
BUG FIX: CountAll needs to remember the tableName; also implement
...
equals.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981627 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:43:02 +00:00
Adam Heath
46b66d2bd2
BUG FIX: Fix correct formatting around the operator.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981626 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:55 +00:00
Adam Heath
33809facfe
TESTS: Start adding low-level object unit tests.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981625 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:49 +00:00
Adam Heath
c9f9555c25
No longer use ON in relation settings; instead, use MAP, which makes the
...
sql a little bit simpler.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981624 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:39 +00:00
Adam Heath
1581156412
TESTS: Test reparsing of all statements.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981623 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:33 +00:00
Adam Heath
a9aa86c234
BUG FIX: OFFSET/LIMIT have to be after ORDER BY/GROUP BY.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981622 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:28 +00:00
Adam Heath
1fc630261e
BUG FIX: Fix toString with multiple RELATION, they should not be
...
separated by commas.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981621 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:23 +00:00
Adam Heath
3ade64a656
OPTIMIZE: KeyMap no longer extends Atom, so no longer has any appendTo variants.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981620 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:17 +00:00
Adam Heath
0864fca12f
BUG FIX: Fix multiple keymaps in a relation, wasn't separated by AND.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981619 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:11 +00:00
Adam Heath
bc6a4b7870
Introduce a new method, getDefaultName(), so that null alias logic
...
doesn't happen in the constructor.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981618 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:06 +00:00
Adam Heath
f8e091775c
FEATURE: Make public wrappers around several internal methods.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981617 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:42:00 +00:00
Adam Heath
3929451368
FEATURE: Create a new StaticValue function, based on the contents of
...
FieldDef.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981616 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:41:55 +00:00
Adam Heath
81a56ac59c
REFACTOR: Move FieldAll call to a new function, SelectField.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981615 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:41:50 +00:00
Adam Heath
e544bd6be0
REFACTOR: Optimize select AS support, so it is only required in one place.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981614 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:41:44 +00:00
Adam Heath
806332cc89
REFACTOR: Optimize FieldDef, so that the FieldDef object instantiation only
...
happens in one place.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981613 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:41:39 +00:00
Adam Heath
b98105c65f
REFACTOR: Abstract out FieldAll so it can be called externally.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981612 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:41:34 +00:00
Adam Heath
54c6cb0f16
FEATURE: Add static valueOf methods.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981611 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:41:28 +00:00
Adam Heath
0038f309a5
FORMAT: Re-indent; couldn't find a standard for indentation, so this is an
...
attempt to have some sort of common pattern for doing so.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981610 13f79535-47bb-0310-9956-ffa450edef68
2010-08-02 17:41:23 +00:00
Scott Gray
4448c4a866
No functional changes, just removing a whole bunch of unused imports and reorganizing them along the way.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@981019 13f79535-47bb-0310-9956-ffa450edef68
2010-07-31 08:28:34 +00:00
Adam Heath
cbd11cf3b0
Revert wrongly committed 950258
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@950277 13f79535-47bb-0310-9956-ffa450edef68
2010-06-01 22:00:26 +00:00
Adam Heath
69c2d455f3
sql foo
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@950258 13f79535-47bb-0310-9956-ffa450edef68
2010-06-01 21:46:44 +00:00
Adam Heath
feef6caffc
Use the new equals implementations to test for a correct parse; also
...
test all the statements.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949609 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:07:10 +00:00
Adam Heath
17d8151d34
Allow fieldAlls, fieldDefs, and relations to be null; if they are empty,
...
then force them to null instead.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949608 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:07:04 +00:00
Adam Heath
a24bab15cf
Only output the alias if it is not the same as the default name.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949607 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:06:58 +00:00
Adam Heath
40cff7fd7b
Implement equals() in a bunch of places.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949606 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:06:53 +00:00
Adam Heath
69de194305
Convert operators to lowercase in the constructors that have them,
...
instead of only during parsing; this fixes instances where the objects
are not constructed by the sql parser.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949605 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:06:42 +00:00
Adam Heath
4a31886e82
Fix operator parsing; only the last character was being parsed as the
...
operator.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949604 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:06:36 +00:00
Adam Heath
ddb9bf8b27
Remove FieldDefFieldValue, and merge FieldDefValue into FieldDef.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949603 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:06:31 +00:00
Adam Heath
8c083d6743
Make the Order enum public.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949602 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:06:23 +00:00
Adam Heath
39ee8befa9
Start adding DISTINCT support to SELECT.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949600 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:06:17 +00:00
Adam Heath
36bed586b9
Add support for several count function variants.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949599 13f79535-47bb-0310-9956-ffa450edef68
2010-05-30 22:06:11 +00:00
Adam Heath
95949ff2b7
Add <test-jar> macro.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@935381 13f79535-47bb-0310-9956-ffa450edef68
2010-04-18 18:03:47 +00:00
Scott Gray
6109808c8a
Tabs to spaces
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@924378 13f79535-47bb-0310-9956-ffa450edef68
2010-03-17 17:28:01 +00:00
Adrian Crum
24922db654
Created a new Java package - org.ofbiz.base.lang - which is intended to be used as a home for basic Java types. Moved some basic Java type classes into the new package.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@916987 13f79535-47bb-0310-9956-ffa450edef68
2010-02-27 16:48:32 +00:00
Jacopo Cappellato
75a3c9f270
Added a bunch of missing license headers; we'll have to pay more attention on this in the future.
...
Still some work needs to be done in order to have the codebase inline with the ASF policies as it used to be.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@907413 13f79535-47bb-0310-9956-ffa450edef68
2010-02-07 11:24:45 +00:00
Adam Heath
b17eb127ec
Fix trailing whitespace, and mixed tab/space at the beginning of lines.
...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@899812 13f79535-47bb-0310-9956-ffa450edef68
2010-01-15 21:00:23 +00:00