Skip to Content.
Sympa Menu

freetds - Re: [freetds] SQL-08S01 error in FreeTDS/Azure when executing stored proc for a few minutes from Linux (but not from Windows)

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Cade Roux <cade AT roux.org>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] SQL-08S01 error in FreeTDS/Azure when executing stored proc for a few minutes from Linux (but not from Windows)
  • Date: Wed, 21 Nov 2012 09:03:28 -0600

It took a large number of batches in the loop to get to one which
showed the problem, so I've got a 160MB log now, and somewhere before
the row count check and the last 12 inserts is the clue. I might set
up another test. I'm thinking that Azure "pauses" the connection at
some point and the inserts fail and then the connection starts working
again (I reuse the same connection for all the files). Why this
happens only on the start of a file is a bit of a mystery, although
obviously there is a small time gap between files for the count to be
take, the file to be close, the new file to be opened, and the table
to be truncated before the next set of inserts. Also weird is that
the first truncate step always seems to be working - just the first
few inserts are failing. I'm wondering if SQL Azure can do the
truncate out of order on the connection? That doesn't seem possible
on the same connection. But that would definitely explain the
behavior - if all the inserts are actually working but the TRUNCATE
comes at the wrong time. Never saw this behavior in the same script
on Windows, though. None of this really make any sense.

Perhaps the suggestion on my StackOverflow Q to count the rows after
every insert wasn't such a bad idea (although obviously not feasible
in practice).

Thanks,

Cade
Cade Roux
cade AT roux.org
504-717-4887


On Mon, Nov 19, 2012 at 7:55 AM, James K. Lowden <jklowden AT freetds.org> wrote:
> On Sun, 18 Nov 2012 20:14:37 -0600
> Cade Roux <cade AT roux.org> wrote:
>
>> I'm finding problems with the inserts now where prepare and/or
>> execute are failing without giving any indication of an error
>> (http://stackoverflow.com/questions/13435327/perl-dbi-freetds-sqlazure-some-inserts-ignored).
>
> What does TDSDUMP indicate about the first batch of rows?
>
> I suspect the error messages aren't being printed.
>
> --jkl
> _______________________________________________
> FreeTDS mailing list
> FreeTDS AT lists.ibiblio.org
> http://lists.ibiblio.org/mailman/listinfo/freetds




Archive powered by MHonArc 2.6.24.

Top of Page