DataSource Controls :: Managing SQL Connections In A Website?

Jun 18, 2010

My lecturer insists that a web site should NOT have a static SQL connection as its not good practice (didn't explain why) but then I thought that if one makes instances of an SQL connection everytime I want to save, delete or edit then surely thats a bottleneck as I would need to everytime establish a connection and then do the save process. From what I have read online, the process of establishing a connection to the server is the longest (about 5 to 10ms)...

How would one manage their SQL connection. At the moment I do something like:

[Code]....

View 1 Replies


Similar Messages:

Managing Concurrent Connections In IIS7?

Feb 8, 2011

I'm having an issue with my hosting provider (winhost.com). My app is built on ASP.NET 4 MVC 3. Up until a few days ago, everything was running fine. All of a sudden I've started getting 503 errors when trying to access my site (wikipediamaze.com). It doesn't happen all the time, just most of the time.

When someone starts playing the game a request is made to wikipedia.org to get the contents of the page for the current step in the puzzle. Basically I'm screen scraping wikipedia.org, injecting some html and then displaying the results. All of my web requests are closed immediately after receiving the data.

What winhost is telling me is that there are connections remaining open and causing any additional requests to the site to get the 503 Service Unavailable Error. What I can see from my end is that only 1 request is ever allowed to be made to wikipediamaze.com at a time. If you keep refreshing the page you'll eventually get the HTML but all subsequent requests (css,images,js) all get the 503 error. Even pages that don't ever call out to wikipedia.org.

If it was an issue with connection throttling in IIS, do both incoming and outgoing (requests made internally) fall in to the same bucket? If I'm sure all of my connections are being closed (and I've never had this issue before) what else could cause this?

View 1 Replies

DataSource Controls :: Managing A List Of Object?

Jun 2, 2010

Need ideas on how to do this. I have a page where I'm adding a new object.This is a row in a db table. This object has a list of other objects associated with it.I want to be able to define the sub-objects before adding the new object. Does that even make sense??

I was thinking somehow using the object datasource would be a good way to manage this. That way when I add the object, just loop through the object datasource to get the sub-objects to add. How would I achieve this with the object datasource, or am I even going about it the right way?

View 5 Replies

DataSource Controls :: How To Detect Smo Remote Connections

Apr 19, 2010

I've been playing about for ages in an attempt to get a simple bit of code that can detect whether or not SQL Server is listening remotely or just locally.. My pretty lame attempt so far is as follows:

[Code]....

I'm sure there must be a better way to do this! Aside from the fact that this code fails to work properly.

sp.IPAddresses contains:

- 127.0.0.1
- 0.0.0.0
- 10.0.0.10

When I used Surface Area Manager > Surface Area Configuration for Services and Connections and set Remote Connections to "Local connections only" sp.IPAddresses still contains the same addresses.

View 1 Replies

DataSource Controls :: SET ARITHABORT ON For Connections In Linq To SQL?

Jun 4, 2010

the SQL connection option ARITHABORT is OFF for OLEDB connections, which I assume Linq To SQL is using. owever I need it to be ON. The reason is that my DB contains some indexed views, and any insert/update/delete operations against tables that are part of an indexed view fail if the connection does not have ARITHABORT ON. Even selects against the indexed view itself fail if the WITH(NOEXPAND) hint is used (which you have to use in SQL Standard Edition to get the performance benefit of the indexed view).Is there somewhere in the data context I can specify I want this option ON? Or somewhere in code I can do it??I have managed a clumsy workaround, but I don't like it .... I have to create a stored procedure for every select/insert/update/delete operation, and in this proc first run SET ARITHABORT ON, then exec another proc which contains the actual select/insert/update/delete. In other words the first proc is just a wrapper for the second. It doesn't work to just put SET ARITHABORT ON above the select/insert/update/delete code.

View 4 Replies

DataSource Controls :: Onfigure SQL 8.00.2039 To Allow Remote Connections?

Feb 9, 2010

web service show me this errorFailureA network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified) App_Code.d-vwopz6my sql version in 8.00.2039 how to configure SQL 8.00.2039 to allow remote connections

View 2 Replies

DataSource Controls :: .Net SqlClient Data Provider - Connections?

Jan 19, 2010

We have developed web application using Asp.net, C# and SQL Server. However, When viewing the Process Info Tool for MS SQL Server, we see lots of processes (150-1000+) with Status = 'sleeping' and Command = 'AWAITING COMMAND' (Application = '.Net SqlClient Data Provider')The DataReaders and Connections are all being closed, but still the sleeping connections are accumulating. The problem becomes so severe that we finally get a "General Network Error" or a "Internal system error" and if we restart IIS. We have tested a lot but no success.

View 5 Replies

DataSource Controls :: Server Profiler / ReportServer Has Four Connections After Restart?

Jan 22, 2010

I think I have a problem that I never noticed before. I was just recently (as in tonight) shown the SQL Server Profiler. I noticed that on a video that I watched there profiler did not move unless there was a query to the database, thus making it easy to see what exactly was going on. When I opened mine for the first time and ran it I am getting 9 logs every say 5 seconds. They consist of;

Audit Logout
RPC:Completed
Audit Login
RPC:Completed
RPC:Completed
SQL: BatchStarting
SQL: BatchCompleted
SQL: BatchStarting
SQL: BatchCompleted

Does anyone know if this is normal or my database just working way to hard?

I just restarted the server and checked databases for active connections now that I know nothing is running, and found the one database that is causing the problem... ReportServer has 4 connections after my restart. Should I leave this alone? Is it normal to have this reporting constantly going on?

View 1 Replies

DataSource Controls :: ADOMD Connections To Accessing SSAS Cubes

Mar 19, 2010

I am new to using ADOMD for accessing SSAS cubes. I am having an issue with concurrency. I am using ADOMD to connect to SSAS 2005 in an ASP.Net 2008 application. When a user executes an MDX query and the ASP.net page opens an ADOMD connection, a second user that tries to execute an MDX query gets "a connection is already open" error. I don't understand how ADOMD works. Does it open only one connection for all users because ASP.Net is using a single account for all connections from the web server? I do not have this problem when using ADO.net in the same manner.

View 2 Replies

DataSource Controls :: Verify That SQL Server Is Configured To Allow Remote Connections?

Dec 8, 2010

I am trying to make a small utility program to update a table in a database.

I made it as a asp.net 2008 project and connected to the development SQL server(which is located locally).It is working fine.

Then I try to move this to production, I realized that the sql server is located in another state and I can not connect it this way.( connection string from webconfig and open the connection).I can not change any configuration of the prod sqlserver.

I get error like sql server does not accept remote connection.( Verify that SQL Server is configured to allow remote connections).

View 2 Replies

DataSource Controls :: Verify That SQL Server Is Configured To Allow Remote Connections?

Jun 11, 2010

I am trying to make a small utility program to update a table in a database.

I made it as a asp.net 2008 project and connected to the development SQL server(which is located locally).It is working fine.

Then I try to move this to production, I realized that the sql server is located in another state and I can not connect it this way.( connection string from webconfig and open the connection).I can not change any configuration of the prod sqlserver.

I get error like sql server does not accept remote connection.( Verify that SQL Server is configured to allow remote connections).

View 2 Replies

DataSource Controls :: Managing Users In SQL Server 2008 Management Studio?

Jul 12, 2010

I restored a database from another server, and everything looks good except the users.

I'm managing all this from SQL Server 2008 Management Studio as SA.

The users are present in the [u]databaseName > security > users[/u] section, and they exist in [u]databaseServer > Security > Logins[/u]. However I can't change anything in the [u]databaseName > security > users[/u] section, because when I try and make a change, and then I hit OK to apply, it says "[i]login name must be specified[b][/b][/i]". But the login name field is grayed out and I can't modify it(even though I'm logged into the machine as Administrator and SQL as SA).

Also, in the user mapping section, when I try to map one of the users to a database, it says '[i]create failed user already exists[b][/b][/i]'...but I don't want to create the user, I just want to map that user to the appropriate databases...

View 2 Replies

DataSource Controls :: SqlDataSource Connections Not Closing Maxing Out Connection Pool?

Jul 28, 2010

i have a web application that use a MySql DataBase. In a page, i have used the sqlDatasource control. The problem is that the conection with the database doesn't closed and i have a lot of open conections until show me the error that says me that the conection pool is full.

[code]....

View 9 Replies

DataSource Controls :: Code Behind To Disconnect Temporarily All DB Connections To Backup/copy Database?

Mar 30, 2010

SQL Server Express 2005 MS Visual Studio 2005 Using ASP.NET with VB code behind. Requirements: Click a button on an ASPX page to disconnect temporarily all DB connections when not in use to allow a script to backup/copy the database to a safe backup location. When a user access the db afterwords, the DB connections will be re-established.

If this is imposible, recommend an alternative. Note: I am working with what I have been given and authorized to use.

View 3 Replies

Web Forms :: Managing Web Buckets On Semi-CMS Website?

Dec 20, 2010

Now i am developing web application, i wanted to be like a CMS but not with all the bells and whistles of a fully blown CMS system. To explain the idea, it is a classifieds ads site were users can log on and add their own ads or browse other users' ads. What i want to be able to do is to have full control on the application without having to write any line of code. I mean, after the application is launched, i want to be able to add / delete ad categories, change dynamic content on the site (like banners, polls and so on).

I managed to create a control panel for myself where i can edit and manage the ad categories (after all it's a data repeater bound to a database and rendering to an ul list containing the categories). My question now is: i am using Master / child pages design, I have some content that's on the Master page and other on the child pages (by content i mean those plugins that are frequently found on websites like polls, news tickers, stocks...etc). Using the Master / Chile paradigm: how can i control the visibilty of those controls through my control panel?

add labels for those controls and control their content from the backend database together with a boolen indicating their visibility. But the problem is that: how can i determine which page is serving this content currently. Like for example, a news ticker on the addad.aspx child page but not on viewads.aspx child page.

View 1 Replies

Managing A Session With C# Website From Java (Apache HttpClient)?

Dec 13, 2010

I want to fetch a web page from a ASP.NET site that is only accessible from within a session. I'm using Apache HttpClient. I first open the main page of the site, then I search for the link to the "goal" page, and then I fire up a GET request for the "goal" page. The problem is that when I get the response for the second GET request, I always get the same (first) page. If I open the site with Firefox or Google Chrome I get the "goal" page.

From the first response from the server I get the following headers:

HTTP/1.1 200 OK
Date: Sun, 12 Dec 2010 19:03:56 GMT
Server: Microsoft-IIS/6.0
Platform: Mobitel Pla.NET
Node: 4
X-Powered-By: ASP.NET
X-AspNet-Version: 1.1.4322
Set-Cookie: ASP.NET_SessionId=0vpgd055cifko3mnw4nkuimz; path=/
Cache-Control: no-cache, must-revalidate
Content-Type: text/html; charset=utf-8
Content-Length: 7032

I inspected the traffic with WireShark and all headers look OK. I send the correct cookie back to the server on the second GET request.

I'm using Apache HttpClient. I have only one instance of DefaultHttpClient and I reuse that for the second request. I have BROWSER_COMPATIBILITY Cookie Policy.

View 2 Replies

Managing SQL Server Connected To Existing DotNetNuke Website?

Oct 14, 2010

Before my time at the company they paid for a very expensive website written in asp.net and dotnetnuke. Absolutely terrible but there's very little that can be done about that now. They won't give us access to the SQL Server for some bizarre reason but they've given us FTP access.

Is there some way I can install a database manager (like phpMyAdmin) using FTP? I think I've found the username and password but I'm not familiar with asp so it's quite a confusing system.

View 2 Replies

Managing Visual Studio Projects For A Website And Custom Usercontrols?

Aug 26, 2010

I have one main project for the cms we are using for our website. I have also created usercontrols to include in the site, but I think I would like to keep these in a separate project and just reference them in the main project. Is this a best practice and how would I do this?

View 1 Replies

DataSource Controls :: Connections Are Being Pooled Even With "Pooling=False"?

Jan 27, 2010

Recently I bumped a problem with an asp.net application where seemingly random errors were thrown, although they were all related to the use of a connection object. Coming from Classic ASP, I wrote my pages by creating a connection object at the top of the page, and using that connection throughout the page. The connection object was opened whenever something had to be done with the database and closed immediately after.

Connectionstring:
"Data Source=<server>;Initial Catalog=<catalog>;Integrated Security=false;user=<user>;password=<password>;Pooling=False;"
So pooling=false.

View 8 Replies

DataSource Controls :: Building A Website By C#?

Feb 2, 2010

I want to building a website. I don't know step build a new website. I don't know use DataSet or create new class store connection string connection to DB ?

View 3 Replies

DataSource Controls :: Run Queries From Website?

Jun 28, 2010

I need to fire sql queries in my website and get the results from the Database. for example: I will give select * from emp in a text box. It shud return the results for me. DO any of u have a sample/links of such application, through which i will be able to implement in my application share me the links/sources/app if u have any.

View 2 Replies

DataSource Controls :: Website Not Connecting To Database

Mar 8, 2010

Could not establish a connection to the database. If you have not yet created the SQL Server database, exit the Web Site Administration tool, use the aspnet_regsql command-line utility to create and configure the database, and then return to this tool to set the provider. I have set up a db locally which mimics the production DB, THe production db and website has no has no issues.

THis used to work till i had hard disk failure and had to reinstall all software and do the db from scratch. Used the table scripts and ran the aspnet_regsql. I am using sql server express 2008 asp.net 3.5 I am using custom provider for Roles and custom membership provider for Memberships. Pretty sure the problem is in the db permissions, though I have set up Users in the Security of the DB.

[Code]....

View 7 Replies

DataSource Controls :: How To Improve Website's Performance

Jun 5, 2010

I had created a web site with asp.net and sqlserver. How can i improve the my website's performance in with regard sqlserver connection?What's your mind about use pool connection? In this regard what the defualt values is set for 'Max Pool Size' and 'Min Pool Size'?What's your mind about use Asynchronous access to data? What's your mind about other ways that you think?

View 3 Replies

DataSource Controls :: Start Sql Agent Job From Website

Jun 25, 2010

Start Sql Agent Job from Website Can this be done in VB?

View 2 Replies

DataSource Controls :: Website Doesn't Run From Localhost?

Jan 8, 2010

im developing a web app in asp.net. it works fine when i run it from visual webdeveloper. however when i run it from localhost i get the following error:

Server Error in '/zoo_webservices' Application.

The SELECT permission was denied on the object 'Zoo', database 'zoo_network', schema 'dbo'.

View 5 Replies







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