Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Unable to use GenerateSeries() for decimal values.

Hi All,

 

I am unable to use GenerateSeries  for decimal values. I am generating a series from -1 to 100 as below  GENERATESERIES(-1, 100, .01).

The numbers are generating the value as 2.0000009, 2.0000009, this is happening with random numbers.I am using decimal number and rouded off to 2 decimal place still I am facing this issue.
Could any one know help me on this.
1 ACCEPTED SOLUTION
v-xuding-msft
Community Support
Community Support

Hi @Anonymous ,

It is by design. You could change the format of data type to decimal number. Or you could use some functions to transform the data.

1.PNG

Column = ROUND('Table'[Value],2)

Table 3 = SELECTCOLUMNS(GENERATESERIES(-1,100,0.1),"Values",CURRENCY([Value]))

Reference:

https://www.sqlbi.com/articles/generating-a-series-of-numbers-in-dax/

 

Best Regards,

Xue Ding

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. Kudos are nice too.

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi,

I faced a similar issue but the problem is not with the round function or the format of the column. The problem is the single value slicer itself, so if you still get the same error, there is detailed information about another method on the link below.

https://medium.com/@ezginazaslankara/the-solution-of-unable-to-input-number-parameter-in-power-bi-98...

v-xuding-msft
Community Support
Community Support

Hi @Anonymous ,

It is by design. You could change the format of data type to decimal number. Or you could use some functions to transform the data.

1.PNG

Column = ROUND('Table'[Value],2)

Table 3 = SELECTCOLUMNS(GENERATESERIES(-1,100,0.1),"Values",CURRENCY([Value]))

Reference:

https://www.sqlbi.com/articles/generating-a-series-of-numbers-in-dax/

 

Best Regards,

Xue Ding

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. Kudos are nice too.

Best Regards,
Xue Ding
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.