NetTalk Central

Author Topic: SQL Errors after NT 10 Upbrade  (Read 4158 times)

Matthew51

  • Full Member
  • ***
  • Posts: 152
    • View Profile
    • Email
SQL Errors after NT 10 Upbrade
« on: December 19, 2017, 11:59:13 AM »
After updating from NT 8 to NT 10 we stated having trouble with the server thread count maxing out and the server locking up.  Whenever this would happen I ran a query on the MSSQL server to list the currently active queries.  Their would always be 2 queries that where "AWAITING COMMAND".  These weren't always the same queries, but were always one that were run frequently.  I'm just guessing that it is fairly random when these lock ups happen.

Looking through NT code I found that it used the SetSqlTimeout procedure, and I tried using that in some of my custom code.  The result was fewer lockups, but also 'Set Lock_Timeout -1' would be one, or both of the queries that are "AWAITING COMMAND" when the server would lock up.

It looks as if NT generated code hasn't be "AWAITING COMMAND", however that may be because my own hand code runs much more often.  I use Access:[Filename] in my custom code rather the the NT methods.  IT would take a lot of work to switch them all over, and I don't know of a NT method to use a SQL dummy file for custom queries.

I have no idea why a NT update would cause this problem, but it was the only significant change we made at the time.  I haven't yet been able to replicate the problem in a test environment.

We are still using Clarion 8 and that may be contributing to the problem, however as I said when we were on NT 8 our server was vary stable.

My driver options are "/BUSYHANDLING=2 /MULTIPLEACTIVERESULTSETS=TRUE /TRUSTEDCONNECTION=TRUE"

Thank You
Matthew
Contractor with 10+ years of NetTalk experience looking for work.
www.linkedin.com/in/matthew-leavitt
BisWare.ca
Check out my free EasyTime Template

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: SQL Errors after NT 10 Upbrade
« Reply #1 on: December 20, 2017, 11:26:40 PM »
Hi Matthew,

>> I use Access:[Filename] in my custom code rather the the NT methods.

that's all the NT methods use as well. so in an ABC app it's usual to use the file manager objects directly, and indeed I do so in my own code. So that's not the issue.

>> I have no idea why a NT update would cause this problem, but it was the only significant change we made at the time.

I'm not sure either. There have been no changes to the basic SQL code in a long long time. The main problem I've seen with SQL stuff is where folk are doing a prop:SQl - especially using BEGIN TRANSACTION in a prop:Sql

cheers
Bruce