Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase «««1234

Worst Practice - Bad Connection Strings and Bad Info in Sysprocesses Expand / Collapse
Author
Message
Posted Sunday, August 10, 2003 8:02 AM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: Moderators
Last Login: Today @ 8:09 AM
Points: 6,779, Visits: 1,862
I think Access/VBA supports Environ$ - if so calling Environ$("computername") should work. Type set at a command prompt to see all variables accessible using this method. If not, you can always get it with an API call, which I'd have to dig around for.

Andy
http://www.sqlservercentral.com/columnists/awarren/




Andy
SQLAndy - My Blog!
Connect with me on LinkedIn
Follow me on Twitter
Post #41616
Posted Monday, August 11, 2003 5:03 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Monday, November 24, 2003 12:00 AM
Points: 125, Visits: 1
One thing I would like to contribute is regarding the connection string. Although it is true that opening database connections is one of the time consuming operations and connection pooling helps reducing it(if connection strings are exactly the same).
However I am not sure how connection pooling will be implemented in typical 2 tier applications,Yes as far a I know connection pooling is one of the services used by MTS in 3 tier architecture and also IIS uses it.
SO I presume that the suggestions provided in the article would hold true for 2 tier applications. If any one can has tested the same on 3 tier architectures and found any performance degradtion can share their comments..

Relationships are like Banks.You Invest the Principal and then get the Interest.



He who knows others is learned but the wise one is one who knows himself.
Post #41617
Posted Thursday, January 22, 2004 10:15 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, November 14, 2012 4:48 AM
Points: 1, Visits: 2
Nice enhancement. I have several components that are running and I would like for the same connection change the 'Application Name'. It seems that this is a read only parameter. Do you know by any chance if there is a way to change the application name or another property that could be used so that can be set when the query is done while maintaining the same connection?
Post #96651
Posted Thursday, January 22, 2004 2:12 PM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: Moderators
Last Login: Today @ 8:09 AM
Points: 6,779, Visits: 1,862
Not that I know of. I'd suggest putting that question out as a separate topic, maybe someone else has tried to do it.

Andy
SQLAndy - My Blog!
Connect with me on LinkedIn
Follow me on Twitter
Post #96732
Posted Monday, August 2, 2004 6:59 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Thursday, June 20, 2013 4:47 PM
Points: 17, Visits: 16

Yes, good article, Connection strings well written saves lots of time when maintaining an Application.

This is very good. I have used this method in the past when we had to to do rapid re-deploys and talk about a time saver.

Post #129601
Posted Monday, August 2, 2004 7:51 AM


SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Thursday, July 24, 2014 1:52 PM
Points: 290, Visits: 52
It's funny and everything to use the phrase "baaad developer", but the problem is, I have to edit the article to show it to the developers.  I'm not sure this sort of contention is a good thing anyway... 

John Scarborough
MCDBA, MCSA
Post #129610
Posted Wednesday, August 26, 2009 7:10 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, August 26, 2009 7:04 AM
Points: 5, Visits: 16
In case of the client using Microsoft Access, the baaad developer is actually Microsoft. Access Project purposely puts developer's machine name into the connection string when it connects to the server. I have been reporting this to Microsoft probably already for ten years in beta programs of both Office and SQL Server, but with Microsoft beta programs being nothing but marketing campaigns, it was of course to no avail. Eventually, I had to write small application that performs binary patch of the compiled Access database and erases the machine name right from the file.

And I'm pretty sure that Access is not the only application that does it. I bet Excel/Query Designer does the same.
Post #777448
« Prev Topic | Next Topic »

Add to briefcase «««1234

Permissions Expand / Collapse