ahmetb / orman

lightweight and minimalist ORM for Java/Android. works with SQLite & MySQL. (not actively maintained)
Other
249 stars 47 forks source link

Solved JoinType Issue #52

Closed bohlool closed 11 years ago

bohlool commented 11 years ago

JoinType has problem when selecting other options and only works when JoinType.JOIN is selected.

bohlool commented 11 years ago

Suppose we are used JoinType.LEFT_JOIN because toString() method of enum by default returns name that is "LEFT_JOIN" this makes SQL statement syntactically problematic, What we want in this case is "LEFT JOIN" and this is possible by overriding toString() method in JoinType.java class and returning appropriate value. On the other hand getTemplate() method of JoinType.java is never used in the project files and can be deleted safely.