EXEC sp_configure ‘show advanced options’, 1
RECONFIGURE WITH OVERRIDE
EXEC sp_configure ‘max server memory (MB)’, 200
RECONFIGURE WITH OVERRIDE
EXEC sp_configure ‘show advanced options’, 1
RECONFIGURE WITH OVERRIDE
EXEC sp_configure ‘max server memory (MB)’, 200
RECONFIGURE WITH OVERRIDE
Select @CSV = isnull(@TRX_REF + ‘,’,”) + seqID from table
Sending XML data over HTTP to a web service, using XMLHTTP object
- Group by weeks
starting on Mondays
select count(OrderID) as numOrders,
min(dateadd(day, datediff(day,’19000101′,OrderDate)/7*7, ’19000101′)) as WeekStarting,
min(OrderDate) as EarliestOrder, max(OrderDate) as LatestOrder from
Northwind..Orders
group by datediff(day,’19000101′,OrderDate)/7
order by WeekStarting
via [SQLTeam]
Recently, I had a problem when SQL Server 2000 Enterprise Manager fails to register (local)database; the error message was “Data Source name not found and no default driver specified”
This was a problem with faulty installation of SQL Server or somehow ODBC/Data Access Components configurationgone bad. The solution thatworked in my case is to export and import HKLM\Software\ODBC\ODBC.INST\SQL Server registry key from a normal system with ODBC drivers installed to the faulty SQL machine’s registry
Truncate:
- deallocates the data pages in a table and only this deallocation is stored in transaction log
- aquires only table and page locks for the whole table. since no
row locks are used less memory is required (lock is a pure memory
object)
- resets identity column if there is one
- removes ALL pages. NO empty pages are left behind in a table
- fast(er)
- doesn’t fire delete triggers
Delete:
- removes one row at the time and every deleted row is stored in the transaction log
- aquires table and/or page and row locks for the whole table
- leaves identity column alone
- can leave empty pages in a table since empty page removal requires a table lock which doesn’t necessarily happen
- slow(er)
- fires delete triggers
RAISERROR (N'After 2', -- Message text 10, -- Severity 1) -- State WITH NOWAIT
The thing to note here is the use of NOWAIT option.
This flushes all waiting resultsets and messages back to the client.
Also note the use of non fatal severity and state, since we don’t
want to cancel our script but only inform the user of the progress.
It comes in very handy when running script that can take a while indeed.
ref: link
Each row has a null bitmap for columns that allow nulls. If the row in that column is null then a bit in the bitmap is 1 else it’s 0.
For variable size datatypes the acctual size is 0 bytes.
For fixed size datatype the acctual size is the default datatype size in bytes set to default value (0 for numbers, ” for chars).
Powered by ScribeFire.
if your web application is using ReportViewer web control, it will throw the exception:The type Microsoft.ReportingServices.UI.WebControlConnection, ReportingServicesWebUserInterface, Version=9.0.242.0, Culture=neutral,
PublicKeyToken=89845dcd8080cc91 does not implement IReportServerConnection or could not be found
its your application inheriting appSettings from parent’s site web.config.
To resolve this, modify your applications’ web.config as
<appSettings>
<remove key ="ReportViewerServerConnection"/>
<remove key ="ReportViewerTemporaryStorage"/>
</appSettings>