java.lang.AssertionError: numMsgsRcvd:1 should be less than numMsgsSent:1 when creating schemas - kotlin-exposed

I get java.lang.AssertionError: numMsgsRcvd:1 should be less than numMsgsSent:1 Error when I am using
SchemaUtils.create()
I am connecting to SQL Server

Related

Database 'wss_content_1' cannot be opened. It is in the middle of a restore

This is the scenario:
I am testing redundancy and fail over in my dev machine by creating two SQL Servers.
I have created two SQL Servers. One with an extra instance:
-SQL1 : primary server
-SQL2 : mirror server
-SQL2\wtn : witness instance
First I made a full backup of the database and transaction log in my primary server, then I restored the database and transaction log file.
I used option "Restore with no recovery".
In the database node "restoring" is being shown. I believe this is normal when you would like to keep pulling data.
Then in the primary server, I tried to create mirroring on the database. After the wizard completed, I clicked on start Mirroring, but now I am getting the following error:
An error occurred while starting mirroring.
------------------------------
ADDITIONAL INFORMATION:
Alter failed for Database 'WSS_Content_1'. (Microsoft.SqlServer.Smo)
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
------------------------------
Database 'wss_content_1' cannot be opened. It is in the middle of a restore. (Microsoft SQL Server, Error: 927)
I see there is another post here on stack overflow, but that does not have much information. I have been waiting more than 10 minutes.
Update
I am using SQL Enterprise 2016 by the way. Perhaps there is a difference in 2016 version.
I was watching this youtube video and my steps were exactly as this guy's.
Update 2:
I followed this as well but did not help.
How to: Prepare a Mirror Database for Mirroring (Transact-SQL)

Handling a SQL Server Login error msg with VBA?

I'm working in a VBA module for Access that queries linked tables, generates reports based off the data, and then uses a PDF printer to save the reports to disk. There's a timer in the primary form that will, every N seconds, run an Access query against a "JOBQUEUE" table to see if there are new jobs.
If the database server becomes unavailable, this operation will of course time out. The run-time error of 3051 is being logged, and the loop will try to continue. The loop can't finish, however, because the following error comes right after the VB Run-Time error;
Title is "Microsoft SQL Server Login", so it's not within VB as far as I can tell.
Connection Failed:
SQLState: '01000'
SQL Server Error: 53
[Microsoft][ODBC SQL Server Driver][DBNETLIB][ConnectionOpen(Connect()).
Connection Failed:
SQLState: '08001'
SQL Server Error: 17
[Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not
exist or access is denied.
In every forum & discussion I've found that mentions this error, the asker is concerned with the cause of the error. In this case, I can assume that the error is temporary, and that it needs to continue trying to connect because the installation is unattended. Access goes into a "Not Responding..." state when it's timing out against the DB, and that's OK too, if connection is restored before it goes into the MsgBox described above, it will pick up where it left off and soldier on.
Does anyone know of a way that I can either mute that msgbox, preferably programatically, but I'd take anything at this point that can be done remotely that isn't an RDP session.
Edit: Link to image
The error I was getting was indeed not a run-time error that could be caught from code. Rather, it was SQL timing out after I already swallowed & dismissed time-outs in run-time in my VBA module.
The error does not seem to ever appear now that I have introduced a new timer that resets the loop that runs a query against my linked tables. It can't be logged & swallowed, but it can be prevented by being smarter about how I handle timeouts in run-time.

Generating an Entity Framework model - There is insufficient system memory in resource pool 'internal' to run this query

I'm just trying to right click then select "Generate Model from database." and I get the error:
Unable to generate the model because of the following exception:
'An error occurred while executing the command definition. See the inner
exception for details.
There is insufficient system memory in
resource pool 'internal' to run this query. '.
Loading metadata from
the database took 00:00:04.0661492. Generating the model took
00:00:01.7104861.
I'm running SQL Server 2008 express, and only trying to generate 10 tables.
It looks like there is a bug in SQL Server and they have fixed it. Try downloading the fix.
Temporary fix :
Go to services.msc and stop and start SQL Server (MSSQLSERVER) and you are good to go!

SQL Server Exception "A severe error occurred on the current command. The results, if any, should be discarded"

Can somebody help me get through the following Sql Exception : "A severe error occurred on the current command. The results, if any, should be discarded".
I'm running a drop replication (i.e sp_dropsubscription & sp_droparticle) script reading from the uploaded file using c#.net. I encounter the above error when running in Sql server 2008, but the same thing works fine in Sql Server 2005.
At the point of the Exception, I see that the Commands have actually got executed in the backend but can't figure out why the exception. Any idea ??
Thanks.

Why does this transport-level error occur?

After a breakdown on my virtual webhost, they finally restored the container, but now I randomly get the error when I try to execute queries. I can do a
Select top 20000 from Orders
But
Select * from Orders (about 100k rows total)
Receives the error in my management studio:
A transport-level error has occurred when receiving results from the server. (provider: Shared Memory Provider, error: 0 - No process is on the other end of the pipe.)
And this error in my error log:
A read operation on a large object failed while sending data to the client. A common cause for this is if the application is running in READ UNCOMMITTED isolation level. This connection will be terminated.
I have googled the error and can see that it could be because "Lightweight pooling" is enabled, but this is not the case here.
I run mssql 2008 express on a windows 2003 server.
We get the same random issue on MSSQL where I work and (for us any way) its down to network issues (too much traffic and such).
This blog post by Michael Aspengren explains the error message "A transport-level error has occurred when sending the request to the server."

Resources