cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
rdegr Regular Visitor
Regular Visitor

category.source.type.underlyingType

I can't find a lookup for the values in this field, can anyone point me in the right direction?  Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
jppp
Advisor

Re: category.source.type.underlyingType

The `category.source.type` has to values that determine the real type if you are really interested: the `primitaveType` and the `extendedType`.

 

Both are enums and a pretty accurate definition is available at:

https://github.com/avontd2868/PowerBI-visuals/blob/c0278829a474f2b3f4dec1c8f0adb41fc4814fbf/src/Clie...

https://github.com/avontd2868/PowerBI-visuals/blob/c0278829a474f2b3f4dec1c8f0adb41fc4814fbf/src/Clie...

 

In case of the screenshot Ignat: the primitiveType is 3 (`Double`) and extendedType 259 (`Double`).

And to determine the difference between a `Double` and `Decimal` is the extendedType property: `259` vs `258`

 

-JP

6 REPLIES 6
Moderator v-viig
Moderator

Re: category.source.type.underlyingType

Not sure if understand the issue well. Do you want to detect column type?

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

rdegr Regular Visitor
Regular Visitor

Re: category.source.type.underlyingType

Yes, exactly.  This has numeric codes, I'd like to know what they map to.

Moderator v-viig
Moderator

Re: category.source.type.underlyingType

To detect column type please use metadata.type.numeric

 

image.png

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

Highlighted
rdegr Regular Visitor
Regular Visitor

Re: category.source.type.underlyingType

Other parts of the API appear to distinguish "double" from "decimal".  So that "valueEncoded" for a numeric might be digits followed by an M or a D (or L for integer).  How to distinguish "double" from "decimal"?

rdegr Regular Visitor
Regular Visitor

Re: category.source.type.underlyingType

jppp
Advisor

Re: category.source.type.underlyingType

The `category.source.type` has to values that determine the real type if you are really interested: the `primitaveType` and the `extendedType`.

 

Both are enums and a pretty accurate definition is available at:

https://github.com/avontd2868/PowerBI-visuals/blob/c0278829a474f2b3f4dec1c8f0adb41fc4814fbf/src/Clie...

https://github.com/avontd2868/PowerBI-visuals/blob/c0278829a474f2b3f4dec1c8f0adb41fc4814fbf/src/Clie...

 

In case of the screenshot Ignat: the primitiveType is 3 (`Double`) and extendedType 259 (`Double`).

And to determine the difference between a `Double` and `Decimal` is the extendedType property: `259` vs `258`

 

-JP