Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
fwdtech
Starting Member
11 Posts |
Posted - 2006-04-04 : 15:17:28
|
I have no idea why, but at a recent product demonstration the database team setup a SQL 2005 machine onto a wireless network that we were supposed to run our queries against. All was going well for about 2 hours until we noticed that entire records were missing from tables and other weird things were happening. I wrote a quick command line c# program to query the database using LINQ with a stored procedure returning 250 records.When I viewed the output of 20 queries I noticed rather amazingly that in two (of the 20) record dumps the values printed where literally out of order going "4.5.6.9.7.10.8" instead of being in numerical order. We chalked this up to wireless packet ordering magic and started throwing food at the SQL guys. We grabbed the SQL machine and shoved it under our table during a break connecting the two machines directly using a switch I had in my bag which resolved the issues.Without digging into the SQL itself could this be caused by running SQL over a wireless connection as opposed to a cabled connection or is this a case of "I just want this to be a SQL problem?" |
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2006-04-04 : 15:20:08
|
Is there a clustered index on the column that has the numeric values? If not, did you use an ORDER BY? If no to both of these, then there is no way to guarantee order. SQL Server will return the data as it finds it. So this is not a network issue.Tara Kizeraka tduggan |
|
|
fwdtech
Starting Member
11 Posts |
Posted - 2006-04-04 : 15:29:44
|
quote: Originally posted by tkizer Is there a clustered index on the column that has the numeric values? If not, did you use an ORDER BY? If no to both of these, then there is no way to guarantee order. SQL Server will return the data as it finds it.
The stored procedure has an ORDER BY at the end thats how I got back the other 18 sets in numerical order. I'm going to try this again at the office and see if I can duplicate what happened. |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2006-04-04 : 15:47:02
|
So did you execute the stored procedure, open the table in Enterprise Manager, or use a select statement in Query Analyzer?Tara Kizeraka tduggan |
|
|
fwdtech
Starting Member
11 Posts |
Posted - 2006-04-04 : 15:48:38
|
quote: Originally posted by tkizer So did you execute the stored procedure, open the table in Enterprise Manager, or use a select statement in Query Analyzer?
I executed the procedure from within a command line app in c#. It was the same chunk of code that we were using from our control application. 18 of 20 dumps of data looked fine but 2 had this out-of-order issue. |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2006-04-04 : 17:57:05
|
can you try to execute your Stored Procedure in Query Analyser over a wireless connection and compare it with over a wired connection ? KH |
|
|
|
|
|
|
|