Skip to main content

Notifications

Power Apps - Building Power Apps
Suggested answer

Modern table control - Date format & lookup field issue

(2) ShareShare
ReportReport
Posted on by 102
Hello, 
 
I would like to use the modern table control in my canvas app using dataverse tables.
Contact and AccountID are lookup fields.
 
My first attempt
 
Formula
Search(Filter('Opportunity CRM',OpportunityStatus<>'OpportunityStatus (Opportunity CRM)'.Lost),TxtSearchOpportunities.Value,OpportunityID,OpportunityCandidate,OpportunityKey)
 
Result
Then I tried to solve date format issue by using the AddColumns formula
 
New Formula
Search(Filter(AddColumns('Opportunity CRM',DeadlineFormatted,Text(OpportunityDeadline,DateTimeFormat.ShortDate,"nl-BE")),
OpportunityStatus<>'OpportunityStatus (Opportunity CRM)'.Lost),TxtSearchOpportunities.Value,OpportunityID,OpportunityCandidate,OpportunityKey)
 
Result
By using the AddColumns formula, the lookup fields are empty now...
I would like to have 3x OK.
How can I solve this issue?
Thanks.
 
Kr
 
 
Categories:
  • Suggested answer
    ThomasVDS Profile Picture
    ThomasVDS 102 on at
    Modern table control - Date format & lookup field issue
    Thank you for your suggestions, but they did not work.
     
    Via the following formula the lookup fields are shown, I added them also in the AddColumns part
     
    Search(Filter(AddColumns('Opportunity CRM',DeadlineFormatted,Text(OpportunityDeadline,DateTimeFormat.ShortDate,"nl-BE"),AccountName,AccountID.AccountID,ContactName,OpportunityContact.ContactID),OpportunityStatus<>'OpportunityStatus (Opportunity CRM)'.Lost),TxtSearchOpportunities.Value,OpportunityID,OpportunityCandidate,OpportunityKey)
     
  • timl Profile Picture
    timl 33,744 on at
    Modern table control - Date format & lookup field issue
    Hi ThomasVDS
     
    I'd try wrapping AddColumns around the Search. That should hopefully work.
     
    AddColumns(
    
               Search(Filter('Opportunity CRM',OpportunityStatus<>'OpportunityStatus (Opportunity CRM)'.Lost),
                      TxtSearchOpportunities.Value,OpportunityID,OpportunityCandidate,OpportunityKey
               ),
               DeadlineFormatted,
               Text(OpportunityDeadline,DateTimeFormat.ShortDate,"nl-BE")
    )
     
  • Suggested answer
    MichaelFP Profile Picture
    MichaelFP 1,543 on at
    Modern table control - Date format & lookup field issue
    You need to put the filter inside the AddColumn() and not the inverse. Try that and will get all of the columns that you required.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,434

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,722

Leaderboard