Suddenly, starting on 6/6/2019, the ADG_OrderShipperUnion proc that gets called when clicking the Refresh button on the Credit Manager's Assistant (40.170.00) screen throws the attached error. I was able to modify the proc so that if the CreditDateTo parameter is 6/6/2079, it gets reset to 6/5/2079. Every one of my installs (SL 2011 & SL 2015) using this screen have been affected by this. Anyone know if the 6/6/2079 date is no longer the max SQL date allowed? Was there an SQL update that changed this?
From another forum, alter the ADG_OrderShipperUnion stored procedure, changing the @CreditDateFrom and @CreditDateTo variables from smalldatetime to datetime,
Thanks. I'm really curious as to what may have caused this sudden change. The error did not exist prior to 6/6/2019, and at least 4 site installs reported the same error popping up on the same day.
Good question! Seems to me that the differences in size of the datatypes would have caused the problem before. All I can think of is that the 'translation' of the smalldatetime was read by the datetime type as outside of the default range of acceptable dates and didn't trigger until 6/6/2019. Just a guess! I'm not a database engineer and don't even play one on TV.
The max value for a smalldatetime field is 6/6/2079. That date can be seen in different SL tables where it was as a default value, like 1/1/1900 used as a minimum default value; probably where no actual date is supplied by the program, as SL table definitions don't allow null values in any field.
Going past 6/6/2019 triggered this problem, what isn't obvious is why the current date has a conflict with the this field type's maximum date. A Datetime field type is 8 bytes long, so it can hold larger date values than a smalldatetime for the CreditDateFrom and CreditDateTo variables declared in this stored procedure, avoiding a problem with the size of the date field.
Business Applications communities