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
tkboisvert
Helper II
Helper II

Custom Connector Documentation.AllowedValues not populating in service

Hello,

 

We have a custom connector using this logic:

 

 

 

[DataSource.Kind="xxxAUTH", Publish="xxxAUTH.Publish"]
shared xxxAUTH.Contents = Value.ReplaceType(xxxAUTH.BigNavTable, xxxAUTH.xxxType);

xxxAUTH.xxxType = type function (
    InputAsofDate as (type text meta [
        Documentation.FieldCaption = "As of Date",
        Documentation.FieldDescription = "Should P&L & BS values be from the first of the month to: Today or Month End?",
        Documentation.AllowedValues = { "TODAY", "MONTHEND" }
    ]),
    InputStartPeriod as (type number meta [
        Documentation.FieldCaption = "Fiscal Start Period",
        Documentation.FieldDescription = "When does your fiscal year start? If January, choose 1, if Feb, choose 2, etc..",
        Documentation.AllowedValues = { 1,2,3,4,5,6,7,8,9,10,11,12 }
    ]))
    as table meta [
        Documentation.Name = "xxx ", /* This is the title seen when filling in the parameters for the first time */
        Documentation.LongDescription = "xxx " & Extension.LoadString("Version")];

 

 

 

This works great locally ( meaning it populates the dropdown locally ) and DOES refresh through the gateway. Great!

 

https://imgur.com/SfhaMkD

 

However, when we are setting up the gateway, the dropdown only display nulls:

 
 

https://imgur.com/A6BE1zg

 

I'm on the latest version of the OPDG ( 3000.68.15. DEC 2020 rev 3 )

 

This is obviously very frustrating for my users, what can be done to fix this?

 

 

4 REPLIES 4
v-yiruan-msft
Community Support
Community Support

Hi @tkboisvert ,

Please review the content in the following link, hope it can help you resolve the problem.

Specifying Allowed Values, Sample Values and Descriptions For Function Parameters In Power Query

Best Regards

Community Support Team _ Rena
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hello, thank you for your response.

That blog post is from 2014, before the on premise data gateway was even released.

My original code was almost copy and pasted from that blog and the other Mat Masons examples he mentions.
However, I did create a barebones connector using the linked code and the same thing happens.

 

 

 

section ParameterTest;

[DataSource.Kind="ParameterTest", Publish="ParameterTest.Publish"]
shared ParameterTest.Contents = Value.ReplaceType(ParameterTest.HelloWorld,MyFunctionType);


ParameterTest.HelloWorld = ( _Greeting as text, _TestNumber as number) =>
    let
        a = _Greeting&" from ParameterTest: " & Text.From(_TestNumber)
    in
        a;


Greeting = type text
meta
[Documentation.Description = "Please choose a greeting",
Documentation.AllowedValues = {"Hello", "Bonjour"}];
 
TestNumber = type number
meta
[Documentation.Description = "Please choose a number",
Documentation.AllowedValues = {1..5}];
//declare custom function type using custom number types
MyFunctionType = type function(
_Greeting as Greeting,
_TestNumber as TestNumber)
as text;

 

 

 

 

tkboisvert_0-1613158802611.png

 

Anonymous
Not applicable

Hi,

I have same issue ....Does anybody knows what to do?

 

Thanks

@artemus  @curth 

 

The answer from my support ticket was to request and update on the documentation pages. I will be doing this.   Wrong post. Still no answer from microsoft.

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.

Top Kudoed Authors