Index: SQLLexicalAnalyzer.java
===================================================================
--- SQLLexicalAnalyzer.java	(revision 44097)
+++ SQLLexicalAnalyzer.java	(revision 44098)
@@ -1,5 +1,6 @@
 package org.gvsig.expressionevaluator.impl;
 
+import org.gvsig.expressionevaluator.ExpressionSyntaxException;
 import org.gvsig.expressionevaluator.spi.AbstractLexicalAnalyzer;
 import org.gvsig.expressionevaluator.LexicalAnalyzer;
 
@@ -62,6 +63,8 @@
         case '<':
             ch = getch();
             switch( ch ) {
+            case EOF:
+                throw new ExpressionSyntaxException(I18N.unexpected_end_of_source(), this);
             case '>':
                 token.set(Token.OP_NE, "<>");
                 return token;
@@ -75,7 +78,10 @@
 
         case '>':
             ch = getch();
-            if( ch == '=' ) {
+            switch( ch ) {
+            case EOF:
+                throw new ExpressionSyntaxException(I18N.unexpected_end_of_source(), this);
+            case '=':
                 token.set(Token.OP_GE, ">=");
                 return token;
             }
@@ -96,29 +102,38 @@
             token.set(Token.PARENTHESIS_CLOSE, ")");
             return token;
         case '+':
-            ch = getch();
-            if( !Character.isDigit(ch) ) {
-                ungetch();
-                token.set(Token.OP_ADD, "+");
-                return token;
-            }
-            ungetch();
-            parseNumber();
-            token.setLiteral("+" + token.getLiteral());
+            token.set(Token.OP_ADD, "+");
             return token;
+//            ch = getch();
+//            if( ch == EOF ) {
+//                throw new ExpressionSyntaxException(I18N.unexpected_end_of_source(), this);
+//            }
+//            if( !Character.isDigit(ch) ) {
+//                ungetch();
+//                token.set(Token.OP_ADD, "+");
+//                return token;
+//            }
+//            ungetch();
+//            parseNumber();
+//            token.setLiteral("+" + token.getLiteral());
+//            return token;
         case '-':
             ch = getch();
-            if( ch=='>' ) {
+            switch( ch ) {
+            case EOF:
+                throw new ExpressionSyntaxException(I18N.unexpected_end_of_source(), this);
+            case '>':
                 // SQL Extension to access object methods and attributes
                 token.set(Token.OP_GETATTR, "->");
                 return token;
             }
-            if( Character.isDigit(ch) ) {
-                ungetch();
-                ungetch();
-                parseNumber();
-                return token;
-            }
+//            if( Character.isDigit(ch) ) {
+//                ungetch();
+//                ungetch();
+//                parseNumber();
+//                return token;
+//            }
+            ungetch();
             token.set(Token.OP_SUBST, "-");
             return token;
 
@@ -127,13 +142,13 @@
             ch = getch();
             while( ch != '"' ) {
                 if( ch == EOF ) {
-                    throw new RuntimeException("Found end of source and expected end of string");
+                    throw new ExpressionSyntaxException(I18N.End_of_string_was_expected_and_end_of_source_was_found(), this);
                 }
                 buffer.add(ch);
                 ch = getch();
             }
             if( buffer.length() < 1 ) {
-                throw new RuntimeException();
+                throw new ExpressionSyntaxException(I18N.Incorrect_string_length(), this);
             }
             token.set(Token.IDENTIFIER, buffer.toString());
             return token;
@@ -143,13 +158,13 @@
             ch = getch();
             while( ch != ']' ) {
                 if( ch == EOF ) {
-                    throw new RuntimeException("Found end of source and expected end of string");
+                    throw new ExpressionSyntaxException(I18N.Closing_square_bracket_was_expected_and_end_of_source_was_found(), this);
                 }
                 buffer.add(ch);
                 ch = getch();
             }
             if( buffer.length() < 1 ) {
-                throw new RuntimeException();
+                throw new ExpressionSyntaxException(I18N.Incorrect_identifier_length(), this);
             }
             token.set(Token.IDENTIFIER, buffer.toString());
             return token;
