Skip to main content

Notifications

Dynamics 365 Community / Forums / Finance forum / Dual Write Filter Error
Finance forum
Answered

Dual Write Filter Error

Posted on by 2,741
I added the SalesType field to the SalesOrderHeaderAttachmentEntity and am now trying to filter the Notes map to sync sales orders only.  (We receive and error when we try to add a note to a Return Order in Finance.  Which makes sense as returns are in a seperate table in CRM.
 
I have tried both filters below and they successfully filter return orders, but they also prevent sales order notes from syncing.  What is my error?
 
((SalesType == SalesType::Sales) &&((DocumentAttachmentTypeCode == "Note") || (DocumentAttachmentTypeCode == "URL")))
((SalesType == "Sales") &&((DocumentAttachmentTypeCode == "Note") || (DocumentAttachmentTypeCode == "URL")))
  • Suggested answer
    lispyj Profile Picture
    lispyj 2,741 on at
    Dual Write Filter Error
    This is the winner!
     
    (((SalesType==SalesType::Sales)) && ((DocumentAttachmentTypeCode == "Note") || (DocumentAttachmentTypeCode == "URL")))
  • lispyj Profile Picture
    lispyj 2,741 on at
    Dual Write Filter Error
    Can someone tell me if && is the correct entry for AND in this syntax?
     
    Also
    What is the correct way to filter for enum?  I tried the field = enum value as Text "Sales"  and I also tried the field = enumType::Value without "".  Is one of these correct?
     
    I am pretty sure that the name of the field SalesType is correct because my value is not evaluating as I need it to. The filter I need is records having sales type of Sales and Note type of either Note or URL.
     
    Thanks for any help you can give.

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

Anton Venter – Community Spotlight

Kudos to our October Community Star of the month!

Announcing Our 2024 Season 2 Super Users!

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

Dynamics 365 Community Newsletter - September 2024

Check out the latest community news

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,522 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,441 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans