|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
SQL server remote connection error
I am getting this error when I execute a query on a remote server.
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]ConnectionCheckForData (CheckforData()). [Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]General network error. Check your network documentation. Connection Broken This only happens when my query is run between these dates '5/1/2003' '5/30/2003' The query returs an extended cost- I have checked the totals for that quarter is over 1900000.00 If I run for the first quarter of this year the total is just under 1800000.00 and it executes fine. here is my query SELECT TOP 15 t.description, Amount = CASE WHEN t.Extcost_priceUSD IS NULL THEN 0 ELSE t.Extcost_priceUSD END FROM ( SELECT DISTINCT a.description, (SELECT sum(d.Extcost_priceUSD) FROM POS_DataTable d WHERE d.description = a.description AND d.ship_date >= '5/1/2003' AND d.ship_date <= '5/30/2003' AND d.COID = 100 ) as Extcost_priceUSD FROM POS_Datatable a WHERE COID = 100 AND ship_date >= '5/1/2003' AND ship_date <= '5/30/2003' Group By a.description ) as t Order by t.Extcost_priceUSD DESC Can anyone tell me why this happens. |
|
#2
|
||||
|
||||
|
That's really strange. Don't know if this will help, but try using BETWEEN to see if you still get the error:
AND ( d.ship_date BETWEEN '5/1/2003' AND '5/30/2003' ) |
|
#3
|
|||
|
|||
|
i'm experiencing the same problem. the weird thing is, it happens on random tables on the same database and same remote server.
my query is a simple select count(*) from imgtable where id = 7 |
![]() |
| Viewing: ASP Free Forums > Database > Microsoft SQL Server > SQL server remote connection error |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|