Got exception when upgrading Customized Commerce from 14.21 to 14.26

Vote:
 

Hi guys,

I am upgrading Customized Commerce from 14.21 to 14.26. I got this error when running application after upgrading

InnerException {"Failed to update database during execution of statement 'DROP PROCEDURE CustomColumnSettings_Save;\r\n'"} System.Exception {System.Data.DataException}

Actually, this procedure is not existed in my database.

Any suggestions to solve this issue?

#328615
Sep 01, 2024 9:12
Vote:
 

Hi,

Sounds like a bug, I will file a bug report to Commerce team. Apologies for the inconvenience and thanks for the report. 

Meanwhile you can workaround by adding this dummy SP

CREATE PROCEDURE [CustomColumnSettings_Save]
AS

BEGIN

END

#328656
Edited, Sep 02, 2024 9:08
Vote:
 

Hi Quan,

Thanks for your response. Unfortunately, I tried to create procedure like this and got another error

SqlException: Cannot drop type 'udttCustomColumnTable' because it is being referenced by object 'CustomColumnSettings_Save'. There may be other objects that reference this type.

#328697
Sep 03, 2024 2:18
Vote:
 

that is very strange. can you check if the CustomColumnSettings_Save SP exists at that point, with and without schema (dbo) ?

#328698
Sep 03, 2024 6:45
Vote:
 

Not sure what you meant.

Here is the SP

#328700
Sep 03, 2024 10:06
Vote:
 

I think that is the problem as you create the SP with the dbo schema. there should be another SP without the dbo schema 

#328762
Sep 04, 2024 8:05
Vote:
 

Yeah. You are right. I found 2 these SPs without dbo schema

#328764
Edited, Sep 04, 2024 8:09
Vote:
 

I think that you can drop those SPs and try again 

#328766
Sep 04, 2024 8:38
Vote:
 

so the problem was like this

  • the original SP was created without dbo schema, it'll be created with whatever user name used to run the upgrade script
  • the team recognized that problem, and try to correct it with later release
  • however it seem in your case, the context has changed (different user, maybe that's the difference between local vs DXP), so the upgrade script could not find the original SP and failed
#328769
Sep 04, 2024 8:47
Vote:
 

Thanks Quan. That seems working on foundation. 

The steps to fix is 

  1. Drop both Get and Save SPs under different schema name.
  2. Create two new SPs under dbo schema

Note: Another gotcha, keep Find package to 16.2, I just hit another error after upgrading to 16.3

#329239
Sep 06, 2024 3:41
Vote:
 

Yes, it works when I drops those SPs without dbo and create 2 other ones

#329346
Sep 06, 2024 3:52
Vote:
 

Can I see the full stack trace with Find 16.3 please? Maybe start another thread for it?

#329455
Sep 06, 2024 7:53
Vote:
 

@Vincent yes we are now aware of the problem and there is a solution here Foundation NuGet package upgrade then error | Optimizely Develope

#329771
Sep 12, 2024 10:37
* 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.