jehugaleahsa / SQLGeneration

Provides core classes for generating SQL at runtime.
The Unlicense
22 stars 10 forks source link

numericLiteral is always integer #23

Open marnun opened 9 years ago

marnun commented 9 years ago

when using: builder.AddProjection(new Function("AVG", new Multiplication(new NumericLiteral(1.0), new Column("col1"))), metric); i'm getting : SELECT AVG((1 * col1)) instead of : SELECT AVG((1.0 * col1))

jehugaleahsa commented 9 years ago

NumericLiteral has a Format property that you can use to force how the number is converted back to a string. On Sep 7, 2015 10:06 AM, "erez l" notifications@github.com wrote:

when using: builder.AddProjection(new Function("AVG", new Multiplication(new NumericLiteral(1.0), new Column("col1"))), metric); i'm getting : SELECT AVG((1 * col1)) instead of : SELECT AVG((1.0 * col1))

— Reply to this email directly or view it on GitHub https://github.com/jehugaleahsa/SQLGeneration/issues/23.