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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
cl123
Frequent Visitor

Expression.Error: 5 arguments were passed to a function which expects between 3 and 4. Details:

cl123_0-1661320226509.png

Below is my coding:

 

= Table.FuzzyGroup(#"Changed Type",{"Name Keyword"}, {{"Count Name Keyword", each Table.RowCount(Table.Distinct(_)),Int64.Type}},[IgnoreCase = true, IgnoreSpace = true, Threshold = 0.42],{"Group By Name Keyword ", each _, type table [Name Keyword=nullable text, RecordTypeId=nullable text, BillingCountry=nullable text, ShippingCountry=nullable text, OwnerId=nullable text, Business_Unit__c=nullable text, National_Account__c=any, Status__c=nullable text, ADM_Geography__c=nullable text, Account_Customer_IDT__c=nullable number, Classification__c=nullable text, Entity_Description__c=any, Source_System__c=nullable text, Market_Segment__c=nullable text, Region__c=nullable text, SAP_ECC_Id__c=nullable number, Record Type.Name=nullable text]})

 

Hi all,

 

Current facing this error:

 

Expression.Error: 5 arguments were passed to a function which expects between 3 and 4.
Details:
Pattern=
Arguments=[List]

 

and have no idea how to fix it, your kind help will be greatly appreciated.

 

Thank you so much.

 

 

3 REPLIES 3
Ehren
Employee
Employee

According to the docs, Table.FuzzyGroup can be passed up to four parameters: table, key, aggregatedColumns, and an optional options record.

 

You're passing it five parameters.

Table.FuzzyGroup(
    #"Changed Type",    // #1
    {"Name Keyword"},   // #2
    {
        {"Count Name Keyword", each Table.RowCount(Table.Distinct(_)),Int64.Type}
    },                  // #3
    [
        IgnoreCase = true,
        IgnoreSpace = true,
        Threshold = 0.42
    ],                  // #4
    {
        "Group By Name Keyword ",
        each _,
        type table [Name Keyword=nullable text, RecordTypeId=nullable text, BillingCountry=nullable text, ShippingCountry=nullable text, OwnerId=nullable text, Business_Unit__c=nullable text, National_Account__c=any, Status__c=nullable text, ADM_Geography__c=nullable text, Account_Customer_IDT__c=nullable number, Classification__c=nullable text, Entity_Description__c=any, Source_System__c=nullable text, Market_Segment__c=nullable text, Region__c=nullable text, SAP_ECC_Id__c=nullable number, Record Type.Name=nullable text]
    }                   // #5
)

It looks like you may have started with a fuzzy group that just computed a count, but then added a new aggregated column ("Group By Name Keyword") at the end of the parameters, instead of adding it to the existing list of aggregated columns.

cl123
Frequent Visitor

Hi, 

 

Thank you so much for your input. Do you happen to know the solution for this, if you do, do you mind sharing the correct codes with me?

 

Thank you so much.

 

With Regards,

 

I'm not sure exactly what you're trying to do, but I suspect you need to move the "Group By Name Keyword" definition into the list of aggregated columns.

 

Table.FuzzyGroup(
    #"Changed Type",
    {"Name Keyword"},
    {
        {
            "Count Name Keyword",
            each Table.RowCount(Table.Distinct(_)),
            Int64.Type
        },
        {
            "Group By Name Keyword ",
            each _,
            type table [Name Keyword=nullable text, RecordTypeId=nullable text, BillingCountry=nullable text, ShippingCountry=nullable text, OwnerId=nullable text, Business_Unit__c=nullable text, National_Account__c=any, Status__c=nullable text, ADM_Geography__c=nullable text, Account_Customer_IDT__c=nullable number, Classification__c=nullable text, Entity_Description__c=any, Source_System__c=nullable text, Market_Segment__c=nullable text, Region__c=nullable text, SAP_ECC_Id__c=nullable number, Record Type.Name=nullable text]
        }
    },
    [
        IgnoreCase = true,
        IgnoreSpace = true,
        Threshold = 0.42
    ]
)

 

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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

Top Solution Authors
Top Kudoed Authors