Path: csiph.com!news.mixmin.net!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail From: Erland Sommarskog Newsgroups: comp.databases.ms-sqlserver Subject: Re: `sqlcmd' withholding error messages? Date: Fri, 12 Aug 2022 22:45:25 +0200 Organization: Erland Sommarskog Lines: 24 Message-ID: References: <20220811131035.f10b114df6b905668746c2ab@g{oogle}mail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit Injection-Info: reader01.eternal-september.org; posting-host="b2ee3610490b957ecb1d847ea19114bb"; logging-data="2733875"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18CVvJsOnaZOfzks+qTpmGx" User-Agent: Xnews/2006.08.24 Mime-proxy/2.1.c.0 (Win32) Cancel-Lock: sha1:v5rtE0N053LlnE7xbztE+HldUbM= Xref: csiph.com comp.databases.ms-sqlserver:2156 Anton Shepelev (anton.txt@g{oogle}mail.com) writes: > Most of the time is works as expected, but on rare oc- > casion the log file will contain error entries with an > empty message, e.g.: > > Thu 08/11/2022 13:04:12.46: > Error invoking mem_bal _mem_balance.sql for SBO35: > -- > > Which means that `sqlcmd' returned an error code yet > did not print any message to standard output. Do I in- > voke it incorrectly? > Unfortunately without a reproducible case, this is difficult to comment on. What I can say is that sometimes I get the feeling that SQLCMD does not relay all errors when there are many, but I have never investigate it. But have I run into no errors at all, but still it's apparent that the operation falied? When I think of it, I think I have, but I don't recall the details. What's in your scripts? Loading of stored procedures and other objects? Or something else? (In my case, it was most likely a stored procedure.)