Orphan / Ghost Connections

Sep 6, 2007

Hello,

I have a VB program which uses ADODB.Connection to make connection to SQL Server DB.
However, under some circumstances, orphan / ghost connections remain in DB even after the VB program closed.

Here are the facts...

(1) Windows Server 2000 + SQL Server 2000
- run the VB program and made connection to the DB, leave it for 3 minutes, the connection closes when the program closes.
- run the VB program and made connection to the DB, leave it for 3 hours, the connection closes when the program closes.

(2) Windows Server 2003 + SQL Server 2000
- run the VB program and made connection to the DB, leave it for 3 minutes, the connection closes when the program closes.
- run the VB program and made connection to the DB, leave it for 3 hours, the connection does not close even after the program is closed.


Does anyone know if there is any problem with Windows Server 2003 + SQL Server 2000 using ADODB.Connection?
Or is there some kind of "timeout" parameter for which I can set to resolve such issue?

Any help is appreciated!!!

Thanks & Regards,
Andy.

View 11 Replies


ADVERTISEMENT

Orphan's Won't Die!!

Jul 31, 2002

Hi Folks,

I have a 2000 remote server that polls the 6.5 server every 2 mins to check for access violation on the server via a query analyzer connection. It then uses xp_sendamil and net send for notifications.

The problem is, I've started to get loads of orphan connections from the remote server, which will not kill when attempted.

Any ideas, apart from stopping and starting sql service?

View 1 Replies View Related

Orphan Records

Mar 14, 2001

I have run a NOT EXISTS query comparing a table in test and production, to determine which records have been added to the table in production so I can import those records to test. The count(*) from both tables has a difference of 766 records but the query is showing 768. I am trying to find the easiest/quickest way to identify the orphan records.

View 2 Replies View Related

Orphan Logins?

Apr 10, 2008

Like orphan users, is there a way to figure out orphan logins?

------------------------
I think, therefore I am - Rene Descartes

View 16 Replies View Related

Orphan Logins

Apr 18, 2007

Hi

Just logged on to one of the SQL Servers.I see a lot of logins there who dont have any database access. Its a SQL Server 2000 box.

Can someone please help me with a script that would get me a list of such Orphan Logins (not orphan users).

Thanks

Regards

View 3 Replies View Related

Orphan Recods

Jul 23, 2005

Hi,Say, a database has all the FK constraints created properly, would sqlserver 2000 save this kind of meta data into sysforeignkeys table? Orit depends on ...?I'm trying to find all the orphen records in a given database via metadata.TIA.

View 7 Replies View Related

Orphan Record In Sys.objects

Aug 29, 2007

Not sure if this is the correct place to ask. But it made sense to start here.

I have a legacy stored procedure that had been running under SQL2005 for some time correctly. Now it fails as it is trying to deal with user tables listed in the sys.objects view. The issue appears to be an individual table that no longer exists in the database but is still has a record visible from sys.objects. This entry is an orphan. My question is how do I remove the orphan record from sys.objects?

Thank you

View 4 Replies View Related

DB Ghost

Jan 9, 2004

Anyone here have experience with DB Ghost? Pros/Cons.

View 3 Replies View Related

Can You Ghost SQL Server?

Sep 25, 2002

I use Ghost and Sysprep to image the OS and core apps, but have never Ghosted the PC with SQL installed.

Is it necessary to restore the image to a drive THEN install SQL (as I currently do), or can I be lazy and Ghost the whole thing?

View 2 Replies View Related

Ghost Cleanup....

Mar 28, 2008

Hi:

I need to restore a DB but it was prevented by a background process of "Ghost Cleanup".
server is SQL2000 ENT. sp4.

It could not be killed, neither it was stoped after restart the server. Is there a way to change its running schedule and/or to kill it when I need to restore the db?

thanks
David

View 1 Replies View Related

Can I Ghost An SQL Server?

Jul 23, 2005

I have a test environment that we rebuild servers on a regular basis.To streamline the process we use ghost. We will be installing SQL onthe servers and want to build a ghost image with that build. We havetested it by doing the build, loading the data, and then stopping allthe services and setting them to manual. After we Ghost the machine,we start up the services and reset them to Automatic. Seems to work.My question is:Are there any risks? Should I expect any adverse affects?Thanks for all your help!

View 2 Replies View Related

Controling For Widow And Orphan Rows In A Table

Jan 30, 2008

I am using a table to display a very large amount of data (a basic list of information) with groups (the group header repeats on each page). Each of the groups can span multiple pages, The problem I have is that in the printed mode (or PDF) the group title may show at the bottom of some pages with no details (there may not be enough space for a detail row) and then the heading repeats on the next with the detail. How do I prevent this widow problem?

This can be controled in Access and Brio but not here seems a little odd.

View 1 Replies View Related

You Can't Explain This! ARRRRG! SQL Ghost!

Dec 23, 2007

Hello all,
Where do I start?  My son and I wrote a small ASP.net 2.0 website on XP IIS 5.  Works ok with the standard login controls.
I FTP'ed the files up to a Windows server2003.  I installed the SQL publishing wizard.  I created a .sql file of the data base.
I ran the file in SQL2005 manager to build the data base on SQL express running on the Windows 2003 server.  It installed,  no errors.  great!
The website would not run with Data base connection errors ,  like files or data base was read only,  duplicate database ,  can not run mydatabase.create.  something like that.
I created a new app pool and made sure network service was the account.  Gave network server permissions to the folders,  it started working great.
Now sit down.  I created a few accounts using the website  ok,  no errors, Great!   Then check the database to see if the passwords were encrypted.  The new accounts were not there. 
But the accounts went somewhere????   Must be two databases????  One hidden?
I detached the database I created with the .sql script file....  to see if I would get an error on the browser.  nope still worked. Hmmmm other hidden database still working.... I stopped database server
in the management tool,    It still worked....Ok, I'll get the house check for poltergiests.
I went to SERVICES.  The service was stopped(SQLEXPRESS)..  I changed auto start to manual.  Browsed back to the site again,  finally an error.
I restarted the service,  website worked again,  but the database,  the only user database,  is still detached.  Created more user accounts with no error....
Seached the hard drives for .MDF files.  Found the file I detached and also the ASPNETDB.MDF that I orginally FTP'ed to the server earlier in the APP_DATA folder of the website.  I renamed the  
MDF file to see if then I would get an error,  yep I did.    It then automatcly re-created the MDF file exactly the same size.  Two files in the directory now and now a new error in the browser
about a database mismatch.  Ok  that makes sense.   But it will not allow me to rename the new file so I can rename the original. 
Question is how does SQLEXPRESS run the ASPNETDB.MDF file in the web folder which is not attached to the database engine? 
Why use a SQL pub wizard if ASP.NET creates the database automaticly? Or just "Runs" it?    AM I HIGH?
Thanks in advance,  before I take drugs and sit in a dark closet.
-Wade
 
 
 
 

View 4 Replies View Related

Problem With Ghost Locking...

Sep 28, 2004

Hi

I just now had the strangest error, for some reason a table in my DB was locked by two processes, there is no use with BEGIN TRANSACTION in the queries that execute on the DB and while it suddnely happaned no heavy process was running... I was just browsing the table with the enterprise manager.

After viewing the processes with sp_lock I found the two processes that caused the locking and killed them, this fixed the problem, but I would like to know what caused it...
When viewing the process info with sp_who the status was "sleeping" and in sp_lock in one process the type was "key" and the status was "wait" (mode "s").

Any ideas ?
I'm using SQL-Server y2k + sp3.

Thanks,
Inon.

View 1 Replies View Related

Ghost Records In SQL 2000

Jul 14, 2006

Where did this thread go?

View 1 Replies View Related

Problem With Ghost Cleaner...

Nov 9, 2007

I have problem with 'Ghost cleanup' system process. It is locking up my tables and user transactions are keep getting wait status. So is there any way to disable or change the schedule of ghost cleaner?
Thanks in advance..

View 3 Replies View Related

Ghost Primary Key Column

Jun 25, 2006

Hello,I have a table 'customers', with 2 records:SELECT * FROM customers;customerID | customerName------------------+-------------------------myFriend | myFriend's Nametest | testing user(2 rows)but when I'm asking about customerID column, I get the answer:SELECT customerID FROM customers;ERROR: column "customerid" does not existWhat happens? I'm using PostgreSQL 8.1.3

View 4 Replies View Related

Problem With Ghost Cleanup

Nov 12, 2007

I have problem with 'Ghost cleanup' system process. It is locking up my tables and user transactions are keep getting wait status. So is there any way to disable or change the schedule of ghost cleaner?
Thanks in advance..

View 12 Replies View Related

Blocking On Something Like Ghost Cleanup?

Aug 23, 2007

I noticed that several connections were blocked by something called Ghost Cleanup (or something like that). I know what the cleanup does, but it often causes blocking for quite a while . . .

Anything I can do about it? SS2000.

Thanks,

Michael

View 1 Replies View Related

Need Help - Converting OLEDB Connections To SQL Connections In Asp.net

May 17, 2005

Hi there,
        Here we have got a
asp.net application that was developed when database was
sitting on SQL server 6.5. Now client has moved all of their databases
to SQL server 2000. When the database was on 6.5 the previous
development team has used oledb connections all over. As the databases
have been moved to SQL server 2000 now i am in process of changing the
database connection part. As part of the process i have a login
authorization code.
Private Function Authenticate(ByVal username As String, ByVal password As String, ByRef results As NorisSetupLib.AuthorizationResult) As Boolean
Dim conn As IDbConnection = GetConnection()
Try
Dim cmd As IDbCommand = conn.CreateCommand()
Dim sql As String = "EDSConfirmUpdate" '"EDSConfirmUpdate""PswdConfirmation"
'Dim cmd As SqlCommand = New SqlCommand("sql", conn)

cmd.CommandText = sql
cmd.CommandType = CommandType.StoredProcedure
NorisHelpers.DBHelpers.AddParam(cmd, "@logon", username)
NorisHelpers.DBHelpers.AddParam(cmd, "@password", password)
conn.Open()
'Get string for return values
Dim ReturnValue As String = cmd.ExecuteScalar.ToString
'Split string into array
Dim Values() As String = ReturnValue.Split(";~".ToCharArray)
'If the return code is CONTINUE, all is well. Otherwise, collect the
'reason why the result failed and let the user know
If Values(0) = "CONTINUE" Then
Return True
Else
results.Result = Values(0)
'Make sure there is a message being returned
If Values.Length > 1 Then
results.Message = Values(2)
End If
Return False
End If
Catch ex As Exception
Throw ex
Finally
If (Not conn Is Nothing AndAlso conn.State = ConnectionState.Open) Then
conn.Close()
End If
End Try
End Function
''' -----------------------------------------------------------------------------
''' <summary>
''' Getting the Connection from the config file
''' </summary>
''' <returns>A connection object</returns>
''' <remarks>
''' This is the same for all of the data classes.
''' Reads a specific
connection string from the web.config file for the service, creates a
connection object and returns it as an IDbConnection.
''' </remarks>
''' -----------------------------------------------------------------------------
Private Function GetConnection() As IDbConnection
'Dim conn As IDbConnection = New System.Data.OleDb.OleDbConnection
Dim conn As IDbConnection = New System.Data.SqlClient.SqlConnection
conn.ConnectionString = NorisHelpers.DBHelpers.GetConnectionString(NorisHelpers.DBHelpers.COMMON)
Return conn
End Function
in the above GetConnection() method i
have commented out the .net dataprovider for oledb and changed it to
.net dataprovider for SQLconnection. this function works fine. But in
the authenticate method above at the line
Dim ReturnValue As String = cmd.ExecuteScalar.ToString

for some reason its throwing the below error.
Run-time exception thrown : System.Data.SqlClient.SqlException - @password is not a parameter for procedure EDSConfirmUpdate.
If i comment out the
Dim conn As IDbConnection = New System.Data.SqlClient.SqlConnection
and uncomment the .net oledb provider,
Dim conn As IDbConnection = New System.Data.OleDb.OleDbConnection
then it works fine.
I also have changed the webconfig file as  below.
<!--<add
key="Common" value='User ID=**secret**;pwd=**secret**;Data
Source="ESMALLDB2K";Initial Catalog=cj_common;Auto
Translate=True;Persist Security Info=False;Provider="SQLOLEDB.1";'
/>-->
<add key="Common" value='User ID=**secret**;pwd=**secret**;Data Source="ESMALLDB2K";Initial Catalog=cj_common;' />
 
Please help. Thanks in advance.
 

View 4 Replies View Related

Idle Timeout, Orphan Timeout Help

Oct 13, 2004

Here's the DB Connection code for a site (Web.config file)
I was wondering how I could specify an idle timeout or orphan timeout.
I tried idle timeout=x and kept getting errors

<add key="DBConn"
value="server=localhost;Trusted_Connection=true;database=SaltwaterFishing;Min Pool
Size=5;Max Pool Size=150;"></add>

Thank you

View 2 Replies View Related

Keep A Few Connections Open All The Time Or Open/close Connections On The Fly?

Jul 20, 2005

Just a quick question about connection management. My application willnever need more than 1 or 2 connections about at any given time. Also, I donot expect many users to be connected at any given time. For efficiency, Iwould like to keep connections alive throughout the lifetime of the objectsrequiring them, rather than opening a new connection, executing code andthen closing it again. What is the most efficient way of doing this?Should I perform the open/close or just one open when I create the objectand a close when I dispose of it?

View 1 Replies View Related

Some Ms SQL Connections

Dec 27, 2007

Hi I have some simple questions of for MS SQL. Say I have a database with a table Called Company. In this table I have Employee's with these columns(EmployeeID<PK>, FirstName, LastName) Now I am inserting some data like this.EmployeeID  FirstName, LastName------------------------------------------------------- 1                  Bob            Smith2                  Joe               Mitter Now Say I have this situation(this will look weird for this example but for another examples and the stuff I am working on it make sense). Say I have a new Employee Called Jessica White. Jessica must be the second record. So I need to insert it between the 1st and 2nd record. Like I said I am very noob at doing this stuff so I am not sure how I would do it. I first was going to my table and then went to modify. This brought up a blank grid with all my column names. I then started to add all my data in. I found out later to make my life easier I need to enter in certain spots null rows in it to help with formating(otherwise I would have had to figure out a way to do make null rows with c# code). I then went back to this grid and I tried to add a record before the data just like you if you used excel. I quickly found out you can not do that. This resulted me having to recreate the table and reput the all the data back in(this told me I was doing something very very wrong). I was then thinking of writing it with a query and I been playing around with it and still running into problems like say I had a table called test with a coloum called id<PK> and testss(yes bad names just playing around though).So if I did something like this:INSERT INTO testVALUES(2)INSERT INTO testVALUES(1)SELECT * FROM testNow I am trying to figure out how to insert something between rows 1 and 2. Would I have to drop the table or delete all the data and then run a saved copy of my script with the added change or what?My second question is what is a good site that has examples of all the commands(I don't want to read a book on it I have had a oracle sql course and well it was just boring and I did not learn too much.). I think the best way for me to learn is just continue doing my site and picking it up on the file and when I got a problem read about it and ask on the forums.   Thanks 

View 11 Replies View Related

SQL 7 Connections

Jul 13, 2001

Very strange event. Installed new machine into NT 4 network, which has a PDC and a BDC. We have copies of all SQL databases on both the PDC and the BDC. I installed SQL 7 on new workstation. Throught Control Panel/ODBC connections I can reach the SQL files on bith the PDC and BDC. Howver when I try to use Enterprise Manager, I can connect to the tables on the PDC, but not the BDC. SQL lists both machines in the server group, but only allows me to access tables on PDC! Here is the Event information that I recived on the BDC:

The computer IVR1 tried to connect to the server NTBACKUPSERVER using the trust relationship established by the MASSCOM domain. However, the computer lost the correct security identifier (SID) when the domain was reconfigured.

How do I fix this?

View 2 Replies View Related

Connections

Apr 14, 2000

HI all,
I have a problem here. I am having two computers both are loaded windows NT 4.0 AND SERVICE PACK 4 AND ALSO I INSTALLED SQL SERVER 7.0.
Now i want to connect those two servers , so pls anyone suggest me how i have to do.I connected both servers thru HUB.
Pls suggest me..
thank u..

--ram

View 1 Replies View Related

Connections

Oct 9, 1998

I figure anyone who has done VB and SQL Server might have run into this.
>
> I am set up as a DBO on SQL Server with access to db1 and db2. My default
> is set to db2. From my local machine, I can log through VB(DSN-less) in
> to
> either one without a problem. BUT, if I go to another machine and try to
> log in through VB(DSN-less) to db1, it rejects my login. Here is my
> connect
> string :
>
> UID=xxxxxxx;PWD=pedro;DATABASE=db2;DRIVER={SQL
> Server};SERVER=Athens;DSN=``;
>
> The only thing that changes when I log into db1 is the database parameter-
> "DATABASE=db1".
>
> Am I doing something wrong here? Is there something that needs to be
> setup
> differently in SQL Server? Do I need to put something else into the
> connect
> string?
>
> This happens for the other developers as well, not just me.
>
> Any help would be GREATLY appreciated.

View 2 Replies View Related

DTS Connections

Apr 12, 2001

I am looking for some ideas on the following DTS challenge: I need to import the data from an Access 97 database into a set of tables(about 25). The location of the database can be anywhere on the users drive(s) and I will need to get the location of the database from a registry setting and use it to define the connection.

Thanks

View 1 Replies View Related

Too Many SQL Connections

Jun 11, 2004

We have a case where a user is using Excel sheet to connect the database on SQL2K and generally his connection runs in the upper 150 in numbers. He generally gets more than 150 connections open.

I know that it's not a good thing, but is there a way to limit it or even kill it after it reaches max?

What are the disadvantages of opening too many connections?

View 1 Replies View Related

Out Of Connections... Or Am I?

Sep 7, 2006

I'm getting the classic message "The timeout period elapsed prior to obtaining a connection from the pool" etc when connecting to my SQL Server 2005 Express from a .Net application.
Then I try connecting, simultaneously, from a simple ASP.net thing I wrote just for testing and this works fine. So, then the connection pool can't be full, can it? Or, does each application have its own pool??

View 6 Replies View Related

Max Connections?

Apr 16, 2004

Ok, yeah, I'm being lazy...

Any comments?

View 8 Replies View Related

Connections To SQL

Feb 9, 2006

Hi

I have heard that SQL Server can support upto 10,000 users,

What if my application , connects to the sql & does not do antything then , why does the SQL server slow down with just 700 users.

I mean just the connection is established & NOTHING further is done.


Thanks

View 6 Replies View Related

2 Connections

Nov 29, 2007

hi,

have been looking for ages for somewhere that might be able to answer my question so thought i'd try here.

anyhows, my place of work have goldmine 6.7 running on a server. the problem is that some of the client machines seem to be taking 2 connections to the server when logged into goldmine and some only 1.

when looking at the open sessions it shows a second for some users accessing pipesqlquery. all users show this but only some show it as a second connection.

please any ideas

View 5 Replies View Related

DSN Vs. DSN-Less Connections.

Dec 21, 2007

Is there any type of performance gain to using DSN connections? Or any real advantage to using them over DSN-Less connections?

--
If I get used to envying others...
Those things about my self I pride will slowly fade away.
-Stellvia

View 5 Replies View Related







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