this is also working query.
IDTSConnectionManager100 connMgr = this.Connections.ADONetAppStaging ; //this we need to give name in connection manager in script component
SqlConnection myADONETConnection = new SqlConnection();
myADONETConnection = (SqlConnection)(connMgr.AcquireConnection(null));
//Read data from table or view to data table
string query = &...
I just needed the query to return all the dates in the period I wanted. Without the joins. Thought I'd share for those wanting to put them in your query. Just change the 365 to whatever timeframe you are wanting.
DECLARE @s DATE = GETDATE()-365, @e DATE = GETDATE();
SELECT TOP (DATEDIFF(DAY, @s, @e)+1)
DATEADD(DAY, ROW_NUMBER() OVER (ORDER BY number)-1, ...
Firstly it advises things like: don't panic, don't restart the server, don't run a DBCC CHECKDB(DB_NAME, REPAIR_ALLOW_DATA_LOSS)
You can also check these references:
The error will indicate the data file (usually a .MDF file) and can be read or written. The offset is the physical byte offset from the beginning of the file. The logical page is obtained by dividing the offset number by 8192.
Reaching the end of the file usually means that the file is damaged. In this case, it is the TempDB data file (.mdf), not the log ...
MAX SERVER MEMORY worked a little differently before SQL Server 2012:
Starting with SQL Server 2012, Multi-Page allocations and CLR
allocations are also included in memory limits that are controlled by
max server memory (MB) and min server memory (MB).
Memory configuration and sizing considerations in SQL Server 2012 and later versions
When Total used memory reaches over 25 GB of RAM again, you can check how much SQL Server consuming RAM, using Windows Resource Monitor (Memory tab)
It is also possible that some other application consumes your memory, Resource Monitor can help to confirm that (or otherwise prove SQL Server overblowns the limits)
Also, check how much memory SQL Server is ...
Finally found the original install files from 2013 in the application install files a colleague restored onto the server. SQL Express had been installed as part of the application, but the SQLEXPR_x86_ENU.msi was hidden within.
You're right, this is probably a severe bug in SQL Server. It is not possible to cause corruption using documented and supported T-SQL. To cause corruption you need
OS-level file system problems (filter drivers, ...)
Undocumented commands like DBCC WRITEPAGE
A severe bug
Can you single-step through the upgrade script? If not, try tracing it ...
SQL Server logs are corrupted and they need to be rebuilt to make the database operational.
Follow all the steps in order. Replace the yourdatabasename name with real name of your database.
Create a new database with same name which you are trying to recover or restore. (In our error message it is yourdatabasename). Make sure the name of the MDF ...
Yes, It's possible.
You can migrate databases from older versions like SQL Server 2008 R2 to SQL Server 2019.
Check answer from here. Migrate to SQL Server 2019
Log shipping: Log shipping is supported if primary is running SQL
Server 2008 SP3 or later, or SQL Server 2008 R2 SP2 or later, and
secondary is running SQL Server 2019.
Warning: If an automatic or ...
You have the most authoritative answer you'll be able to find, with David Browne's answer. You can now go back to your colleagues and say "hey I spoke to someone at Microsoft and the answer is this is completely normal behavior for SQL Server, by design. I don't think any of us knows better than the guys who created / maintain the product themselves.&...
Is this Normal?
my boss and colleagues state that this is not normal behaviour for the database
SQL Server will grow its memory usage up to your configured max server memory and only reduce its memory usage if the system runs low on physical memory.
If the system has plenty of available RAM, SQL Server will use it to cache data and execution plans, ...