Take the community feedback survey now.

CommerceConnect not showing all SerializableCarts and orders in case you have a lot of Markets

Vote:
 

For our B2B use-case on CMS12/CommerceConnect14 we got quite some markets, every main customer (parent-organization) has it's own market, and per product-variant it's own prices.

While updating to CMS12/CommerceConnect14 we found some bugs when trying to load all SerializableCarts or Orders. While looking into the SP's used for loading these:-

  • [dbo].[ecf_SerializableCart_Filter]
  • [dbo].[ecf_PurchaseOrder_Filter]

We found out that the following fields are causing the issues:

  • Input parameter @MartketIds is by default limited to 512 characters.
    • The name is off too, but that's not really an issue..
  • The variable @Query only allows up to 4000 characters.

By setting both (on multiple places) to NVARCHAR(MAX) all Carts and Orders do load.

I can understand we have quite a specific case with a lot of markets, but since this field is limited to 512 characters, this value is reached quite easily. 
When you count with 8 chars for the market, and the comma (e.g.: 0005d129,0006f7d4,etc..) this is already reached with 57 markets.

Updating the SP's is not hard, but will be an issue when Optimizely updates these SP's in a future release.

Can this be looked into, and fixed by Optimizely?

#339975
Edited, Aug 14, 2025 14:44
Vote:
 

Hi Roland,

You are right. the 512-character limit on MarketIds and 4000-character limit on Query are restrictive for B2B scenarios with many markets.

Short term:

Your fix of changing the stored procedure parameters to NVARCHAR(MAX) is correct and addresses the root cause.

The specific changes needed are:

  1. In ecf_SerializableCart_Filter:

    • Change @MarketIds NVARCHAR(512) to @MarketIds NVARCHAR(MAX)
      Change @Query NVARCHAR(4000) to @Query NVARCHAR(MAX)
  2. In ecf_PurchaseOrder_Filter

    • Apply the same parameter changes

Long-term Approach

Since you're concerned about future updates overwriting your changes, here are your options:

1. Report to Optimizely Support

Submit this as a bug report through Optimizely's support channels.

2. Version Control Your Database Changes

  • Maintain SQL scripts with your modifications
  • Document which stored procedures you've modified
  • Create automated deployment scripts that can reapply your changes after Optimizely updates

I'd strongly recommend submitting this to Optimizely as a bug report or enhancement request, as this limitation affects scalability for legitimate B2B use cases. In the meantime, your NVARCHAR(MAX) solution is the correct technical fix.

#339982
Edited, Aug 15, 2025 11:45
Vote:
 

Thank you for your feedback Aniket! I have since reported the issue at Optimizely, see:

https://world.optimizely.com/support/Bug-list/bug/COM-20392

#339998
Aug 18, 2025 11:49
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.