Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Bug fixes in SQL Tokenizer.

  • Loading branch information...
commit fb92b5e9fd2990289895e7271b6ed22f978d9276 1 parent 171ae48
Gerke Geurts ggeurts authored hazzik committed
Showing with 2 additions and 3 deletions.
  1. +2 −3 src/NHibernate/SqlCommand/Parser/SqlTokenizerExtensions.cs
5 src/NHibernate/SqlCommand/Parser/SqlTokenizerExtensions.cs
View
@@ -62,7 +62,7 @@ public static bool TryParseUntilFirstMsSqlSelectColumn(this IEnumerator<SqlToken
// [ TOP { integer | ( expression ) } [PERCENT] [ WITH TIES ] ]
if (tokenEnum.Current.Equals("top", StringComparison.InvariantCultureIgnoreCase))
{
- if (tokenEnum.MoveNext()) return false;
+ if (!tokenEnum.MoveNext()) return false;
if (tokenEnum.Current.TokenType == SqlTokenType.BracketOpen)
{
do
@@ -70,8 +70,7 @@ public static bool TryParseUntilFirstMsSqlSelectColumn(this IEnumerator<SqlToken
if (!tokenEnum.MoveNext()) return false;
} while (tokenEnum.Current.TokenType != SqlTokenType.BracketClose);
}
- if (tokenEnum.MoveNext()) return false;
-
+ if (!tokenEnum.MoveNext()) return false;
if (tokenEnum.Current.Equals("percent", StringComparison.InvariantCultureIgnoreCase))
{
Please sign in to comment.
Something went wrong with that request. Please try again.