SAP Note: 1544419 - SQL Error 8152 in Syslog (SM21), Developer Traces (ST11) or when executing transaction DB02
| | | ---------------Original Message--------------- From: jcook2 Sent: Monday, March 01, 2010 7:49 AM Subject: DB02 -- SQL error 8.152: String or binary data would be truncated Hi Santosh, I experienced same problem with ERP 6 EHP SP5. I opened a message with SAP and they provided a fix until their next BASIS SP. Below is their explanation and fix. One of our monitoring stored procedures, sap_mon_sqldbfiles, retrieves information about the data files, calculates the remaining free space on disk and generates statements based on this. We store the related information in a temporary table which is defined by: create table #fileData ( groupname sysname NULL, logicalname nvarchar(128), physfilename nvarchar(512), fileid smallint, flsizeMB int, allocatedMB int, freepct float, growth nvarchar(10), growthMB int, flmaxsize int, primfile nchar(1), readonly nchar(1), logdev nchar(1), grwthpct nchar(1), devfreeMB int null, alertStatus nchar(1), fileMsg nvarchar(50) <<<< ) The definition for the field fileMsg is 50 characters, but lateron we try to insert texts that exceed the 50 characters limit, e.g. like Autogrow is on, but there is not enought disk space to grow This is the part where the truncation error is caused. We have already fixed this problem and will deliver the fix with the next Basis SP. 1) Go to SQL Server Management Studio 2) Navigate to the <SID> DB > Programmability > Stored Procedures 3) Scroll down to the SP sap_mon_sqldbfiles 4) rightclick on it and choose modify - this will open it in a query window 5) look for the above table definition and change the last field to 100 chars: .... alertStatus nchar(1), fileMsg nvarchar(100) ) 6) Execute the query window to update the procedure accordingly. Afterwards the problem will not occur anymore, even if the size of the transaction log changes. | | __.____._ Copyright © 2011 Toolbox.com and message author. Toolbox.com 4343 N. Scottsdale Road Suite 280, Scottsdale, AZ 85251 | | Popular White Papers In the Spotlight Visit IBM's Leveraging IT Services Briefing Center. Register now and learn how to deliver smarter security & resiliency. _.____.__ |