2 identically databases - 1 is fast and 1 is slow
Hi!
we've got a curious problem. we've two identicall databases, same tables, same date, same indexes, same server, both replicated.
One of them is our life database and the other is our development database. If I execute the following query at the development database the query takes less then one second. If I execute the same query at the live database the query takes about 4 seconds to complete. This is very unsatisfactory!!
What I've noticed is, if I try to analyze the query in the tuning advisor on the developement database it completes without tuning tips. If I do the same on the live database I get the following error:
TITLE: DTAEngine
The minimum storage required for existing physical design structures selected to keep is more than the default storage bound selected by DTA. Set the storage bound explicitly to be larger than 17 MBs using (1) Define max. space for recommendations (MB) under Advanced Options in Tuning Options screen in DTAShell or (2) -B option in DTA command line or (3) <StorageBoundInMB> under <TuningOptions> in input XML to DTA or select fewer PDS to keep.
What can we do? Is there any way to repair the database? Unfortunately we cannot easily recreate the database because the database is replicated.
We use SQL Server 2005 Standard Juni CTP.
Here's the our test query:
CREATE TABLE #tbl_Test
(
RS_ID uniqueidentifier,
TFV_T nvarchar(1000)
)
INSERT INTO #tbl_Test (RS_ID) SELECT TFV_RS_ID FROM tbl_xTableFieldValue
WHERE TFV_FD_ID = '4FD31E1D-8BEE-4211-89D1-26B63369E745'
UPDATE #tbl_Test SET TFV_T = TFV_T_Value FROM tbl_xTableFieldValue WHERE TFV_RS_ID = RS_ID
AND TFV_FD_ID = '4FD31E1D-8BEE-4211-89D1-26B63369E745'
SELECT * FROM #tbl_Test
DROP TABLE #tbl_Test
Best regards,
Markus

