Showing posts with label inserts. Show all posts
Showing posts with label inserts. Show all posts

Tuesday, March 27, 2012

General Network Error

Hi,
I am occasionally getting the above error from an ASP.NET application that i
nserts documents into a SQL database. It had been running without this probl
em for several months and suddenly this problem has raised it's head twice i
n the last few days.
I have narrowed it down to happening when documents are being inserted into
the database, and while this is happening other queries can still be execute
d without any problems - including other inserts.
The full error message is as follows, where line 247 is the insert:
System.Web.HttpUnhandledException: Exception of type System.Web.HttpUnhandle
dException was thrown. --> System.Data.SqlClient.SqlException: General netw
ork error. Check your network documentation.
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior cmdBehavio
r, RunBehavior runBehavior, Boolean returnStream)
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at aifl_na.downloadReadingTest2.Page_Load(Object sender, EventArgs e) in c:\
inetpub\wwwroot\aifl-na\Secure\downloadReadingAssessment2.aspx.vb:line 247
at System.Web.UI.Control.OnLoad(EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain()
-- End of inner exception stack trace --
at System.Web.UI.Page.HandleError(Exception e)
at System.Web.UI.Page.ProcessRequestMain()
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at System.Web.CallHandlerExecutionStep.System.Web.HttpApplication+IExecution
Step.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& comp
letedSynchronously)
The only way Ihave managed to stop this happening is to restart the IIS serv
er that connects to the database. As far as I can tell there is nothing wron
g with the SQL server, could it be a problem with the IIS server it connects
to?
Any suggestions would be greatly appreciated.
Thanks in advance,
Alistair GillespieHi:
As I knowledge, most bug is caused by the code yourself and you have the
call stack, you can see where the error happen is
quote:

> at aifl_na.downloadReadingTest2.Page_Load(Object sender, EventArgs e) in

c:\inetpub\wwwroot\aifl-na\Secure\downloadReadingAssessment2.aspx.vb:line
247
I suggest you insert a breakpoint at line 247 for
downloadReadingAssessment2.aspx.vb, please check the status at that line and
you may ask in the vb groupnews, because it is not exeception throws by sql
server, after I search in MSDN, it is not error can can handle in vs.net
Best Wishes
Wei Ci Zhou|||You might try running a network monitor trace to see what is going on on
the network when this problem occurs.
Rand
This posting is provided "as is" with no warranties and confers no rights.

Friday, March 23, 2012

fuzzy lookup taking too much time

I have a SSIS package where a small table of 270 rows are fuzzy looked up with a table in another sql server and inserts the records to a temporary table. This takes more than 3 hours in debug mode or so and never goes beyond this step.I have used a OLE DB destination to insert to temporary table and temporary table doesn't get a value.

How big is that other table? The fuzzy will build an index to start with, and this can take time. Review the options on the second tab to influence the index. Also check obvious things like blocking or such like? What about a profiler trace, anything untoward?

|||other table also is the same size and has same no of rows.Thank for the clues I found that some of the NOT null columns in the destination table were not mapped which result in failure of insert. Now it inserts correct rows to temp table and fails with a primary key violation which means its going in a never ending sort of a loop. I am going to put a profiler trace to identify the problem.Any advice welcome