This repository was archived by the owner on Dec 24, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +12
-12
lines changed
src/ServiceStack.OrmLite/Expressions Expand file tree Collapse file tree 1 file changed +12
-12
lines changed Original file line number Diff line number Diff line change @@ -2154,33 +2154,33 @@ protected virtual object VisitSqlMethodCall(MethodCallExpression m)
2154
2154
2155
2155
switch ( m . Method . Name )
2156
2156
{
2157
- case "In" :
2157
+ case nameof ( Sql . In ) :
2158
2158
statement = ConvertInExpressionToSql ( m , quotedColName ) ;
2159
2159
break ;
2160
- case " Desc" :
2160
+ case nameof ( Sql . Desc ) :
2161
2161
statement = $ "{ quotedColName } DESC";
2162
2162
break ;
2163
- case "As" :
2163
+ case nameof ( Sql . As ) :
2164
2164
statement = $ "{ quotedColName } AS { DialectProvider . GetQuotedColumnName ( RemoveQuoteFromAlias ( args [ 0 ] . ToString ( ) ) ) } ";
2165
2165
break ;
2166
- case " Sum" :
2167
- case " Count" :
2168
- case " Min" :
2169
- case " Max" :
2170
- case " Avg" :
2166
+ case nameof ( Sql . Sum ) :
2167
+ case nameof ( Sql . Count ) :
2168
+ case nameof ( Sql . Min ) :
2169
+ case nameof ( Sql . Max ) :
2170
+ case nameof ( Sql . Avg ) :
2171
2171
statement = $ "{ m . Method . Name } ({ quotedColName } { ( args . Count == 1 ? $ ",{ args [ 0 ] } " : "" ) } )";
2172
2172
break ;
2173
- case " CountDistinct" :
2173
+ case nameof ( Sql . CountDistinct ) :
2174
2174
statement = $ "COUNT(DISTINCT { quotedColName } )";
2175
2175
break ;
2176
- case " AllFields" :
2176
+ case nameof ( Sql . AllFields ) :
2177
2177
var argDef = m . Arguments [ 0 ] . Type . GetModelMetadata ( ) ;
2178
2178
statement = DialectProvider . GetQuotedTableName ( argDef ) + ".*" ;
2179
2179
break ;
2180
- case " JoinAlias" :
2180
+ case nameof ( Sql . JoinAlias ) :
2181
2181
statement = args [ 0 ] + "." + quotedColName . ToString ( ) . LastRightPart ( '.' ) ;
2182
2182
break ;
2183
- case " Custom" :
2183
+ case nameof ( Sql . Custom ) :
2184
2184
statement = quotedColName . ToString ( ) ;
2185
2185
break ;
2186
2186
default :
You can’t perform that action at this time.
0 commit comments