Mirror Busy Makes Principle Slower?

Jun 6, 2008

Hi everyone,

A relatively simple question but I have no been able to find an answer.

We have a SQL Server mirror Active/passive with High availability. So the usual Witness with failover.

However, we are using the Mirror server for reporting and letting the users query without limit. We sometimes have problems (slowness) with the Principle server and I'm wondering the following.

If the mirror server in high availability mode is maxed out will this affect the principle server because it takes longer to commit the data on both servers?

It seems obvious but I would like a clear response.

Thanks.

View 5 Replies


ADVERTISEMENT

Move Principle And Mirror From Local Drive To San?

Sep 22, 2007

I have a 600 gig database that has a mirror. I need to move the databases from local drives to a SAN. Can anyone recommend a document that lists the steps to go through to move both the principle and mirror to the SAN with no down time? or minimal down time?

View 3 Replies View Related

URGENT: The Command Failed Because The Database Mirror Is Busy!

Mar 30, 2007

Hi,



Mirroring has been working fine on 2 identical servers. We even tested failover and that worked....but today something happened (still investigating) and suddenly the Principal is disconnected and we cannot force failover with:



ALTER DATABASE [LeoCTI] SET PARTNER FORCE_SERVICE_ALLOW_DATA_LOSS



Error: The command failed because the database mirror is busy! Try again later!



How can I bring the principal back online? It won't let me do anything, won't let me turn off mirroring etc. etc.



HELP PLEASE!



Thanks

Hyper aka Richard

View 2 Replies View Related

Help Cursor Based Stored Procedure Is Getting Slower And Slower!

Jul 20, 2005

I am begginner at best so I hope someone that is better can help.I have a stored procedure that updates a view that I wrote using 2cursors.(Kind of a Inner Loop) I wrote it this way Because I couldn'tdo it using reqular transact SQL.The problem is that this procedure is taking longer and longer to run.Up to 5 hours now! It is anaylizing about 30,000 records. I thinkpartly because we add new records every month.The procedure works like this.The first Cursor stores a unique account and duedate combination fromthe view.It then finds all the accts in the view that have that account duedatecombo and loads them into Cursor 2 this groups them together for datamanipulation. The accounts have to be grouped this way because aaccount can have different due dates and multiple records within eachaccount due date combo and they need to be looked at this way aslittle singular groups.Here is my procedure I hope someone can shead some light on this. Myboss is giving me heck about it. (I think he thinks Girls cant code!)I got this far I hope someone can help me optimize it further.CREATE PROCEDURE dbo.sp_PromiseStatusASBEGINSET NOCOUNT ON/* Global variables */DECLARE @tot_pay moneyDECLARE @rec_upd VARCHAR(1)DECLARE @todays_date varchar(12)DECLARE @mActivityDate2_temp datetimeDECLARE @tot_paydate datetime/* variables for cursor ACT_CUR1*/DECLARE @mAcct_Num1 BIGINTDECLARE @mDueDate1 datetime/* variables for ACT_CUR2 */DECLARE @mAcct_Num2 BIGINTDECLARE @mActivity_Date2 datetimeDECLARE @mPromise_Amt_1 moneyDECLARE @mPromise_Status varchar(3)DECLARE @mCurrent_Due_Amt moneyDECLARE @mDPD intDECLARE @mPromise_Date datetimeSELECT @todays_date =''+CAST(DATEPART(mm,getdate()) AS varchar(2))+'/'+CAST(DATEPART(dd,getdate()) AS varchar(2))+'/'+CAST(DATEPART(yyyy,getdate()) AS varchar(4))+''DECLARE ACT_CUR1 CURSOR FORSELECT DISTINCTA.ACCT_NUM,A.DUE_DATEFROM VWAPPLICABLEPROMISEACTIVITYRECORDS AOPEN ACT_CUR1FETCH NEXT FROM ACT_CUR1 INTO @mAcct_Num1 , @mDueDate1WHILE (@@FETCH_STATUS = 0)BEGINSELECT @rec_upd = 'N 'DECLARE ACT_CUR2 CURSOR FORSELECTB.ACCT_NUM,B.ACTIVITY_DATE,B.PROMISE_AMT_1,B.PROMISE_STATUS,B.CURRENT_DUE_AMT,B.DAYS_DELINQUENT_NUM,B.PROMISE_DATE_1FROM VWAPPLICABLEPROMISEACTIVITYRECORDS B (UPDLOCK)WHERE B.ACCT_NUM = @mAcct_Num1ANDB.DUE_DATE = @mDueDate1ORDER BY B.ACCT_NUM,B.DUE_DATE,B.ACTIVITY_DATE,CASEB.Time_ObtainedWHEN 0 THEN 0ELSE 1END Desc, B.Time_ObtainedOPEN ACT_CUR2FETCH NEXT FROM ACT_CUR2INTO @mAcct_Num2 ,@mActivity_Date2,@mPromise_Amt_1,@mPromise_Status ,@mCurrent_Due_Amt,@mDPD,@mPromise_DateWHILE (@@FETCH_STATUS = 0)BEGIN----CHECK------------------------------------------------------------------------DECLARE @PrintVariable2 VARCHAR (8000)--SELECT @PrintVariable2 = CAST(@MACCT_NUM2 AS VARCHAR)+''+CAST(@MACTIVITY_DATE2 AS VARCHAR)+' '+CAST(@MPROMISE_AMT_1 ASVARCHAR)+' '+CAST(@MPROMISE_STATUS AS VARCHAR)+''+CAST(@mCurrent_Due_Amt AS VARCHAR)+' '+CAST(@mDPD AS VARCHAR)+''+CAST(@mPromise_Date AS VARCHAR)--PRINT @PrintVariable2----ENDCHECK------------------------------------------------------------IF @mDPD >= 30BEGINSELECT @tot_pay = SUM(CONVERT(FLOAT, C.PAY_AMT))FROM vwAplicablePayments CWHERE C.ACCT_NUM = @mAcct_Num2ANDC.ACTIVITY_DATE >= @mActivity_Date2ANDC.ACTIVITY_DATE < @mActivity_Date2 + 15----CHECK------------------------------------------------------------------------DECLARE @PrintVariable3 VARCHAR (8000)--SELECT @PrintVariable3 ='Greater=30 DOLLARS COLLECTED'--PRINT @PrintVariable3----ENDCHECK------------------------------------------------------------ENDELSE IF @mDPD < 30BEGINSELECT @tot_pay = SUM(CONVERT(FLOAT, C.PAY_AMT))FROM vwAplicablePayments CWHERE C.ACCT_NUM = @mAcct_Num2ANDC.ACTIVITY_DATE >= @mActivity_Date2ANDC.ACTIVITY_DATE BETWEEN @mActivity_Date2 AND@mPromise_Date + 5----CHECK----------------------------------------------------------------------DECLARE @PrintVariable4 VARCHAR (8000)--SELECT @PrintVariable4 ='Less 30 DOLLARS COLLECTED'--PRINT @PrintVariable4----END CHECK------------------------------------------------------------END----------------------------------------MY REVISEDLOGIC-------------------------------------------------------IF @rec_upd = 'N'BEGINIF @mDPD >= 30BEGINSELECT @mActivityDate2_temp = @mActivity_Date2 + 15--DECLARE @PrintVariable5 VARCHAR (8000)--SELECT @PrintVariable5 =' GREATER= 30 USING ACTVITY_DATE+15'--PRINT @PrintVariable5ENDELSE IF @mDPD < 30BEGINSELECT @mActivityDate2_temp = @mPromise_Date + 5--DECLARE @PrintVariable6 VARCHAR (8000)--SELECT @PrintVariable6 =' LESS 30 USING PROMISE_DATE+5'--PRINT @PrintVariable6ENDIF @tot_pay >= 0.9 * @mCurrent_Due_Amt--used to be promise amtBEGINUPDATE VWAPPLICABLEPROMISEACTIVITYRECORDSSET PROMISE_STATUS = 'PK',TOTAL_DOLLARS_COLL = @tot_payWHERE CURRENT OF ACT_CUR2--This statement updates the time that the status was placedinto PK.IF @mPromise_Status IN ('PTP','OP')BEGINUPDATE VWAPPLICABLEPROMISEACTIVITYRECORDSSET Status_Date = @todays_dateWHERE CURRENT OF ACT_CUR2ENDSELECT @rec_upd = 'Y 'ENDIF ((@tot_pay < 0.9 * @mCurrent_Due_Amt) OR @tot_pay IS NULL)AND( @mActivityDate2_temp > @todays_date )--need to put 1dayof month here for snapshot9/01/2004BEGINUPDATE VWAPPLICABLEPROMISEACTIVITYRECORDSSETPROMISE_STATUS = 'OP'WHERE CURRENT OF ACT_CUR2--This statement updates the time that the status was placedinto OP which is the original Activity Date.--The record will hold this date until it goes into PK,PB,orIP.IF @mPromise_Status IN ('PTP','OP')BEGINUPDATE VWAPPLICABLEPROMISEACTIVITYRECORDSSET Status_Date = @mActivity_Date2WHERE CURRENT OF ACT_CUR2ENDENDELSE IF ((@tot_pay < 0.9 * @mCurrent_Due_Amt) OR @tot_pay ISNULL)AND( @mActivityDate2_temp <= @todays_date )--need to put 1dayof month here for snapshot 9/01/2004BEGINUPDATE VWAPPLICABLEPROMISEACTIVITYRECORDSSETPROMISE_STATUS = 'PB',TOTAL_DOLLARS_COLL = case when @tot_pay is nullthen 0 else @tot_pay endWHERE CURRENT OF ACT_CUR2--This statement updates the time that the status was placedinto PB.IF @mPromise_Status IN ('PTP','OP')BEGINUPDATE VWAPPLICABLEPROMISEACTIVITYRECORDSSET Status_Date = @todays_dateWHERE CURRENT OF ACT_CUR2ENDENDENDELSE IF @rec_upd = 'Y'BEGINUPDATE VWAPPLICABLEPROMISEACTIVITYRECORDSSETPROMISE_STATUS = 'IP',TOTAL_DOLLARS_COLL = 0WHERE CURRENT OF ACT_CUR2--This statement updates the time that the status was placedinto IP.IF @mPromise_Status NOT IN ('IP')BEGINUPDATE VWAPPLICABLEPROMISEACTIVITYRECORDSSET Status_Date = @todays_dateWHERE CURRENT OF ACT_CUR2ENDENDFETCH NEXT FROM ACT_CUR2 INTO @mAcct_Num2,@mActivity_Date2,@mPromise_Amt_1,@mPromise_Status ,@mCurrent_Due_Amt,@mDPD,@mPromise_DateENDCLOSE ACT_CUR2DEALLOCATE ACT_CUR2FETCH NEXT FROM ACT_CUR1 INTO @mAcct_Num1 , @mDueDate1ENDCLOSE ACT_CUR1DEALLOCATE ACT_CUR1SET NOCOUNT OFFENDGO

View 15 Replies View Related

Cannot Use The Special Principle 'sa'

Jan 9, 2008

Ok, here's my issue... SQL 2005.

I have about 12 different databases, which about 4 of them are have no user mapped to it. Under the SA login, databases are mapped to the "dbo". The 4 I am having issues with have no user mapped. They are blank.

Here is where I am at... Security>Logins>sa>Login Properties>User Mapping

The columns are "Map", "Database", "User", and "Default Schema"

Here is an example of the correct Selection
Map=checked, Database=eDistribution, User=dbo, Default Schema=dbo


Now here is an example of a problem database
Map=unchecked, Database=FORMS, User=blank, Default Schema=blank

Here is the error when trying to add the "dbo" as a user

Any ideas?

TITLE: Microsoft SQL Server Management Studio
------------------------------
Create failed for User 'sa'. (Microsoft.SqlServer.Smo)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Create+User&LinkId=20476
------------------------------
ADDITIONAL INFORMATION:
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
------------------------------
Cannot use the special principal 'sa'. (Microsoft SQL Server, Error: 15405)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.1406&EvtSrc=MSSQLServer&EvtID=15405&LinkId=20476
------------------------------
BUTTONS:
OK
------------------------------

TITLE: Microsoft SQL Server Management Studio
------------------------------
Create failed for User 'dbo'. (Microsoft.SqlServer.Smo)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Create+User&LinkId=20476
------------------------------
ADDITIONAL INFORMATION:
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
------------------------------
User, group, or role 'dbo' already exists in the current database. (Microsoft SQL Server, Error: 15023)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.1406&EvtSrc=MSSQLServer&EvtID=15023&LinkId=20476
------------------------------
BUTTONS:
OK
------------------------------

View 1 Replies View Related

Why SSIS Package Slower And Slower

Mar 1, 2008

hi, friends, please look at this:

I have a SSIS package, and inside it I do something like below:

1. I have a SQL component, to give back a object to store the records.
2. I have a VB script component, I direct the object I got in 1 step into the script as a dataset.


My problem is:
I run the package in the SQL SERVER 2005 Store Procedue like this:

do
dtexec.exe package.dtsx
loop untill i>t

I control the it runs 30 times. But I found that the speed is slower and slower.
the first time, it takes about 600 s, but the last time, it takes the 1800 s.

Why?
The package don't drop the object it create during the loop in the Store Procedue ?
Thanks!

View 11 Replies View Related

Mirroring :: How To Reduce LDF Size While Mirror Enabled With Mirror And Witness Server

Jun 14, 2015

I am using SQl Server 2012 Database Mirroring with around 40 gb as mdf and 1 gb as ldf. Now my ldf size increased . How to reduce ldf size while mirror enabled with mirror server and witness server. Can shrink the ldf with mirror enables.

View 4 Replies View Related

Mirror And Witness Connection In A Disconnected State Immediately After Adding Witness Server To Mirror Session.

Jan 31, 2008


After adding the Witness Server to the Mirror session, the Witness Connection state between the Mirror and Witness Connection is Disconnected and the state between Principal and Witness Connection is Connected.

The procedures defined in Books Online was used to setup Database Mirroring...when the Witness server was added to the Mirror session, only the alter database T-SQL statement was executed on the Principal server.

ALTER DATABASE <db_name> SET WITNESS = 'TCP://<servername>:<port>'

After executing the above statement, a few seconds later the state between Principal and Witness Connection changed to Connected and the state between Mirror and Witness Connection remains Disconnected.

The Mirror session is not using Certificates, every server is on the same domain, using the same domain login account, and all servers have SP2 installed running Enterprise Edition.

Any idea's why the state between Mirror and Witness Connection remains Disconnected?

Thanks,

View 9 Replies View Related

Mirror Database-How Do I Remove It From Being The Mirror

Dec 27, 2006

I was trying to test mirroring and now would like to delete the mirror database but it says I need to remove database mirroring first. I deleted the endpoint and cannot figure out how to remove the mirroring. Can someone please help.

View 1 Replies View Related

How To Makes Sum In Sql

May 5, 2006

I want to get different sums from an item base. I have taken the number of every order (ord) from an order base and goes to the item-base like this:

Set Rss = Server.CreateObject("ADODB.RecordSet")
sSQL= "SELECT array(sum(numitems)) from oitems where orderid= " & ord
Rss.Open sSQL, sDSN, adOpenStatic, adLockReadOnly, adCmdText

I have not tried to run the sql- the array is just a dummy to show the idea.

Actually I want to make an array of the sum of items with the same numitems (i.e. the same productnumber)

if the sql runs I will write the array like this:

While Not rss.eof
response.write array(sum(numitems))
'or whatever way I have to write it
rss.Movenext
Wend

...anyone who has a good idea of how to do this?

View 20 Replies View Related

Why Minor Diff Makes Big Lag

Mar 31, 2008

The DB Enginee is SQL2005 SP1. In MSSMS

the following query always finishes within 1 minute

SELECT *
FROM t1 INNER JOIN t2 ON t1.key= t2.key
where t1.StartTime >= '3/19/2008' AND t1.EndTime <= '3/20/2008'
AND t2.StartTime >= t1.StartTime AND t2.StartTime < t1.EndTime

however, the following always takes 10+ minutes
declare @pStartDate datetime
declare @pEndDate datetime
set @pStartDate='3/19/2008'
set @pEndDate='3/20/2008'
SELECT *
FROM t1 INNER JOIN t2 ON t1.key= t2.key
where t1.StartTime >= @pStartDate AND t1.EndTime <= @pEndDate
AND t2.StartTime >= t1.StartTime AND t2.StartTime < t1.EndTime


Both return same result. The only diff. is the blue part. Why the second one performances so badly?
Thanks.

View 4 Replies View Related

GO Makes Things Hugley Faster

Oct 15, 2007

I have a data migration script that takes about an hour half to complete. The script conists of several insert statements that pull data from another sqlserver database while doing a fair amount of manipulation.

If I put a "go" in after every insert statement. The job finishes in 30Seconds. can some explain this huge performance change.

View 1 Replies View Related

Sorting Makes Table Invisible

Sep 13, 2006

I have a table which visibility can be toggled by a text box. By default it is invisible. After it is made visible, clicking a sortable column header makes the table invisible. Does this mean sorting makes the table go back to its default visibility?



View 3 Replies View Related

Add/Remove DataViewers Makes VS To Crash

Sep 14, 2006

Hi all,

I'm sick of VS crashing when I add/remove DataViewers any idea why this could happen ?

Sébastien.

View 4 Replies View Related

Database Busy, Whats Going On?

Dec 15, 2007

Hi, I'm new to c# and sql2005 express. I'm getting an error on the simplest of activities. From C#, i create a database, create a table, then try to delete the database and get a database busy error. I think its because sql has some connections to the database its not releasing. I have already tried closing the connection, disposing of the object and forcing garbage collection for the c# app to no avail.

can someone explain to me wat is going on?

Here is the only function i am calling for c#. I pass in T-SQL command strings such as 'Ceate Database myDB','Create Table myTbl','Drop Database myDB', etc.. :

private bool ExecuteSQLNonQry(string sqlStr)
{
SqlConnection myConn = new SqlConnection(ConnectionString);
SqlCommand SqlCmd = new SqlCommand(sqlStr, myConn);

try
{
myConn.Open();
SqlCmd.ExecuteNonQuery();
myConn.Close();
return true;
}
catch(Exception e)
{
MessageBox.Show(e.Message.ToString());
return false;
}
}

View 11 Replies View Related

Error: Connection Is Busy

Jun 14, 2007

Error: 0xC0202009 at Load SQL Deals, Insert SQL Deals [12494]: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005.
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80004005 Description: "Connection is busy with results for another command".

Why isn't the connection manager managing this?


How can I trace the cause? The data flow component (insert SQL deals) is just a simple INSERT statment.

View 1 Replies View Related

Visual Studio Is Busy

Jun 22, 2007

I keep getting this balloon message along with 'please contact microsoft if you continue to get this message' when using SSIS

Here's the news: I continually get the message so here I am 'contact MS'

There is no link in the balloon indicating quite how I should contact MS.

Any one else have this problem?

View 3 Replies View Related

Express 2005: How To Makes Changes Without Stopping The Web Site?

Jan 24, 2008

 Are there any way I can make changes to my database without stopping the web site? I'm using SQL Server 2005 Express for my web shop. And each time I have to add or change a table or Stored Procedure I have to stop the site. What I do is to stop the web site (in IIS), restart the IIS and then open the database in the SQL Server 2005 Express Management tool. If I don't "release" the file first I get an error when I try to open the database file in the Management tool.But there must be a better way to do things? I also would like to take bacup of the database without stopping the site, but how? There must be others that have had the same problems? Regards, Sigurd 

View 3 Replies View Related

In Outter Joins, What Makes A Table Either Right Or Left?

Dec 16, 2002

Until today, I was always under the impression that left vs. right was determined by which side of the comparison operator the table was located.

In other words:
LEFT JOIN LeftTable.ID = RightTable.ID

would pull all the records from LeftTable and those that matched from from RightTable and that:

RIGHT JOIN RightTable.ID = LeftTable.ID

would pull exactly the same result set but I was wrong. So, if it is not the table position in relation to the comparison operator, is it simply that the tables listed first in the FROM clause aren the ones "Left" of those subsequently entered?

View 2 Replies View Related

Irritating ADODB Error... Makes No Sense To Me

Aug 22, 2007

Hi Guys,

I've been programming with SQL 7 for about a year and my company has finally decided to go SQL 2k5.

I've come accross a really irritating error when writing to the DB via ADO in ASP pages. I have a column in a table that is auto-incremental.

In SQL server 7 you just make an ADODB.Command object and enter the SQL query 'insert into table (columns) values ('val...') now for SQL 7 I can completely leave out the auto-incremental column (called 'ErrorNo') and simply specify the other columns and values in my insert query.
e.g. where my table is called master_error:

ErrorNo int identity (1, 1) not null
,ReportedBy char(10)
,ExpectedFixDate datetime


With ErrorNo being an auto-incremental identity, my query would be

INSERT INTO master_error (ReportedBy, ExpectedFixDate) VALUES ('Ben','01 Sep 2007')

this works perfectly with ADODB.Command when writing to SQL Server 7 from IIS 5.0

however when I execute the exact same command on the exact same table using ADODB.Command writing to SQL Server 2005 from IIS 6.0 I get an 'error 500 internal server error'

IIS log states:
|166|80040e14|[Microsoft][ODBC_SQL_Server_Driver][SQL_Server]Cannot_insert_the_value_NULL_into_column_'ErrorNo'__table_'ReACToR_V1.0.dbo.master_error';_column_does_not_allow_nulls._INSERT_fails. 80 - 192.168.78.159 Mozilla/4.0+(compatible;+MSIE+7.0;+Windows+NT+5.1;+.NET+CLR+1.1.4322;+.NET+CLR+2.0.50727;+.NET+CLR+3.0.04506.30) 500 0 0

I thought perhaps SQL 2005 might have different syntax so I typed the query directly into SQL Server 2005's version of query analyser and guess what... it worked fine.

I can't tell where the error lies. I find it hard to beleive that the error is in the code of my ASP page as it works perfectly against a sql 7 db.

Any ideas?

Many Thanks,
Ben Ward

View 8 Replies View Related

Sort Transformation Makes A Lot Of Temp Files

May 29, 2007

Hi all,



I have a problem with a Sort Transformation, I have a CSV file with 200'000 rows the csv file is about 30Mb. When the rows are processed in the Sort Transformation, SSIS generates around 160 temp files of about 10Mb each.



How can avoid so many temp files to be generated ?

View 4 Replies View Related

Add A Column To Large, Busy Table.

Jan 7, 2008

I have a table that currently holds about 5 million records. We add an average of 5,000 new records per day, all of them from overnight batch jobs. I guess it's not that big, but there are two text columns that hold a couple KB each, so the total size isn't exactly small either. The data is created from medical billing data we receive overnight. We get two reports- patient demographic information and a physician's dictation relating to that patient. This data is always one to one, and the purpose of this table is to store the data as we originally receive, which is why both reports are in the same table. After we extract the details from the report, (which are by this point always reduced to text documents) we need to keep not only the data but the original documents, hence the two text columns. We considered moving the large columns to their own table, which would just have an ID field and the column, but the powers that be really wanted all this in the same table. Nothing new goes into the table during day- it's all SELECT statements.

I need to add a column to this table. It's just a small char(7) column, NULLS allowed, of course. We bill for several clients, and reports from different clients become available at different times, so there's really no down time overnight. Altering the table during the day is out of the question. So how can I add a column while the table is active?

My best idea so far is to use SELECT *, NULL AS NewColumn INTO NewTable to create a copy of the table (using a cast to get the correct datatype) during the day, when no new data is going in, and replacing the old table with the new by simply changing the names right after everyone goes home. But this could still cause slowdowns while it builds the copy, and leave the problem of re-creating indexes (there are several). There ought to be some graceful way to tell it to add the column to the existing table and play nice with ongoing traffic.

View 2 Replies View Related

Connection Busy With Results For Another Hstmt...

Jan 31, 2006

Hi mates,

I am getting this strange error while working on SQL server through JDBC.
I am using a connection-pooling mechanism. Have written my own connection pool. The pool holds a number of connections and has methods for requesting and returning connections from the clients. The issue is - when I get a connection from the pool and execute a select query, it works fine. Then I return the connection to the pool (at the top). On next request for connection, this same connection object is provided. When another select query is fired on this connection, I get an error - "connection is busy with results for another hstmt"... The error occurs at the time of executing the query and not while obtaining the statement object from the connection object.
If I don't use the connection pool and create new connection every time, everything works fine (except the performance!)...
I'll be grateful if anyone can shed some light on this.....
Cheers!

View 1 Replies View Related

Connection Busy With Another Hstmt In Sql Server

Sep 2, 2005

Hello,
I am having above mentioned error while inserting records in database.This arises sometimes after 10 records or 20 records.I dont have any object such as hstmt.
before this insert query ,there is another query where I get one colume value from another table.
please can anybody tell me reason of this kind of error.
Thanks in advance

View 1 Replies View Related

Connection Is Busy With Results For Another Hstmt

Oct 11, 2007

Hi,
When i tried to retreive Datas from Sql Server continously(connection pooling), I got an Exception like "java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Connection is busy with results for another hstmt". After restarting the Tomcat server, it starts to work fine.I don know what is happening behind the screen. Let me know the nature of this Exception and the Solution to this kind of Exception.. Plz as soon as possible..

View 1 Replies View Related

ODBC Connection Busy Error

Jul 20, 2005

I am having multiple threads in my c program to execute same procedurewith differnt parameter values every time.I have created different functions to execute the same.However when SQLExecute is run on one of the thread it returns anerror saying[Microsoft][ODBC SQL Server Driver]Connection is busy with results foranother hstmtHow do I call the same stored procedure on different threads toexecute at the same time.

View 2 Replies View Related

Connection Is Busy With Results For Another Hstmt

Sep 22, 2006

HI guys,

I'm using ODBC driver from WinXP SP2 with SQL Server 2005 Express (on my machine for test) and SQL Server 2005 Standard (on the production machine).

With SQL Server 2005 Express I've no problem, but with SQL Server 2005 Standard, in some query, I get "Connection is busy with results for another hstmt".

I'm working with VisualStudio 2003 with standard CDatabase and CRecordSet MFC classes.

I looked for an advice in the Microsoft KB but I found only Service Pack for SQL Server 2000 !

Everything could be useful !

Thanks a lot!

Bye, Domenico

View 5 Replies View Related

Connection Is Busy With Results For Another Hstmt

May 3, 2008



Hi
I am using SQL server 2000 and vb.net 2003. We have used threads in our application.
Our application is running well but Sometimes we get the error message "connection is busy with results for another hstmt"
We are using adodb connection to open recordsets.

How to resolve this problem?

View 1 Replies View Related

Log Backups On Heavy And Busy Database

Apr 30, 2008


What will be best procedure for the following situation.

Heavy traffic database on daily basis. G growth every day. so Full backups every nights are needed.
Vendor recommends not taking Log backups but copy just log files over other location. will this help avoid degrading the performance during business hours.

if i don't take log backups, i am not able to recover Point in time if needed.
also log files can then grow faster and then i will have to shrink it more often.

what are risks and suggestions.

Thanks,

View 5 Replies View Related

Microsoft Visual Studio Is Busy

Feb 2, 2006

I get this message in a balloon that pops up frequently when I am trying to work in the SSIS designer. For example, I get it when working in a DataFlow task, trying to open editors for the OleDb Source and Destination. Is anyone else getting this? What could be the cause, it seems to get sluggish. Thanks.

View 33 Replies View Related

Connection Is Busy With Results For Another Command

Aug 31, 2007

We are migrating our databases from MS Access to SQL Server 2005 and using the SQL Native Client ODBC driver.

We also use a reporting tool called Actuate. Some of our Actuate reports use multiple datastreams to build the report.

When I run an Actuate report having multiple datastreams I get the following error message from SQL Server:

Error generated by the connected data source. Connection is busy with results for another command.

Is there a configuration setting in SQL Server to enable processing of multiple result sets?


Thanks.

View 6 Replies View Related

ASPNETDB Makes FULL TEXT SEARCH Impossible?

May 13, 2008

Hi There,
I have a database which I attached to Sql Server 2005 Express (With advanced features) and enabled full text search.  I created a FT catalog and FT index on a column and can successfully run the following query:SELECT expertise
FROM faculty_user
WHERE FREETEXT (expertise, 'Berry' )My issue is that full text search requires user instances to be turned off. Simply setting "User Instance=False" over in my web.config's connection string (in VWD) does not solve the problem.I still get the following error and I think it may be caused by my ASPNETDB. I can't find my connection string to ASPNETDB to turn off user instances and I can't diagnose my other connection strings because of it.Generating user instances in SQL Server is disabled

Here is a sample of my other connection strings:
<add name="myConnectionString" connectionString="Data Source=.SQLEXPRESS;AttachDbFilename=|DataDirectory|myDatabase.mdf;Integrated Security=True;User Instance=False" providerName="System.Data.SqlClient"/>
From what I understand, I should also not be attaching the database from my connection string like this because it relys on User Instances? I am officially confused! Thanks for reading, -Derek

View 1 Replies View Related

Multiple Table Joins Makes Query Go To Sleep

Jul 23, 2005

Hello All & Thanks in advance for your help!Background:1) tblT_Documents is the primary parent transaction table that has 10fields and about 250,000 rows2) There are 9 child tables with each having 3 fields each, their ownPK; the FK back to the parent table; and the unique data for thattable. There is a one to many relation between the parent and each ofthe 9 child rows. Each child table has between 100,000 and 300,000rows.3) There are indexes on every field of the child tables (though Idon't believe that they are helping in this situation)4) The client needs to be presented a view that has 5 of the mainfields from the parent table, along with any and all correspondingdata from the child tables.5) The client will select this view by doing some pattern-matchingsearch on one of the child records' detail (e.g. field-name LIKE%search-item% - so much for the indexes...)Problem:When I do the simple join of just the parent with one of the children,the search works *fairly* well and returns the five parent fields andthe corresponding matching child field.However, as soon as I add any one of the other child records to simplydisplay it's unique data along with the previously obtained results,the resulting query hangs.Is the overall structure of the tables not conducive to this kind ofquery? Is this a situation where de-normalization will be required toobtain the desired results? Or, more hopefully, am I just an idiotand there is some simpler solution to this problem?!Thanks again for your assistance!- Ed

View 9 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved