|
|
|
|
|
|
|
Question of the Day |
Today's question (by Steve Jones - SSC Editor): | |
Floating Storage | |
A float data type has a parameter when declared that indicates the mantissa for a number. This is declared as:
DECLARE @f FLOAT(53);The maximum value for the parameter is 53. When 53 is used, the variable uses 8 bytes of storage. If the value of 24 is used, 4 bytes of storage are needed. How many bytes of storage are used for a parameter of 4? | |
Think you know the answer? Click here, and find out if you are right. |
Yesterday's Question of the Day (by Steve Jones - SSC Editor) |
Getting Wait Stats I want to get the wait stats for my SQL Server instance, for all sessions since the server started. What DMV do I query? Answer: sys.dm_os_wait_stats Explanation: For a local SQL Server instance, sys.dm_os_wait_stats includes all waits since the server started (or since the counters were cleared). sys.dm_db_wait_stats is only for Azure SQL Database, while sys.dm_exec_session_wait_stats is for session level waits and these are cleared when sessions close. Ref: sys.dm_os_wait_stats - https://docs.microsoft.com/en-us/sql/relational-databases/system-dynamic-management-views/sys-dm-os-wait-stats-transact-sql?view=sql-server-2017 |
Database Pros Who Need Your Help |
Here's a few of the new posts today on the forums. To see more, visit the forums. |
SQL Server 2017 - Administration |
TDE error Server principal 'public' has no credential associated with cryptograp - As our first foray into TDE (corporate mandate, so please don't post "don't do it"), we're playing with a sandbox server (fortunately) and I was given wrong instructions. We're using a third party encryption key that SQL Server is hooking into. We installed it, got halfway through the instructions and SQL Server blew up at […] |
How to capture permission denied errors - we are implementing SP 2019 and getting an error regarding permission denied on VIEW SERVER STATE. The error doesn't have an account name, is there a way to via a trace flag or more verbose logging level that would force these permission denied events to show in the log? This is just a test server. […] |
System Database directory at Install - I'm running my first real SQL 2017 (Dev edition) install and find that I can't seem to deliberately place the system database files (aside from tempdb) in a location of my choosing. When I name the instance (the default / named instance install page) the path is auto-named with no edit boxes available. When I […] |
SQL Server 2017 - Development |
XML Query Help - Hi: I have xml column with date in this format 2018-07-31T00:00:00+02:00 , when I parse the date with this statement xmldata.value('(ns8:date)[1]', 'DATE') RDate I get the RDate as 2018-07-30 instead of 2018-07-31. When I use xmldata.value('(ns8:date)[1]', 'DATETIMEOFFSET') RDate I get the RDate as 2018-07-31 00:00:00.0000000 +02:00 I want the date to be 2018-07-31. How would […] |
SQL Server 2016 - Administration |
TempDB files - While running the script below I am seeing all the tempdb files but I am just able to see the primary and log file(2 files) in the GUI. Use master GO SELECT name AS [LogicalName] ,physical_name AS [Location] ,state_desc AS [Status] FROM sys.master_files WHERE database_id = DB_ID(N'tempdb'); GO |
ReportServer DB will not join basic availability group - Hello, I am running into a strange situation that I have not been able to resolve. I have a 2 node Basic AG running sql server 2016 standard. I am trying to add the reportserver DB to an ag, but it keeps failing on joining the DB to the secndary node. I have done the […] |
SQL Server 2016 - Development and T-SQL |
t-sql 2016 using different languages - Right using t-sql 2016, in sql server management studio. I can change the fonts by picking options->tex editor->fonts and I can pick 'Karen Hilang'. When I do that, all the sql changes to the language called 'Karen'. **Note: this font is available for me since I installed this font on my computer. Now I have […] |
Looking for Step by Step Instructions for SQL Server Loop using Powershell - Hi Everyone! Does anyone have a good link with instructions to Query a list of servers in a table and put the results in a table? I created a table for the server connection strings. I created a table to store the results. I have the SQL query to get the information. I just don't […] |
row size exceeds the maximum allowable of 8060 bytes - Hello Team, I am having a SQL view(having 600 columns). From last 5 years it is working fine but suddenly we are getting below error. Msg 8618, Level 16, State 2, Line 3 The query processor could not produce a query plan because a worktable is required, and its minimum row size exceeds the maximum […] |
SQL 2012 - General |
Making a Copy of an Existing DB in SQL using SQL script - We need a script by which a source DB, the name will be supplied, to be copied into another DB with another name and also create users who have access only to the new DB. |
Data Type Error In Stored Procedure -Updating a Table - I have the below stored procedure, and I am getting this error message: Incorrect syntax near '01' I have other stored procedures which begin with '01,' and they work ok. I'm not sure where the incorrect syntax is. Thanks for any leads. Here is my table structure: CREATE TABLE [dbo].[01_news_test] ( [interestid] [INT] IDENTITY(1, 1) […] |
SSRS 2012 |
Uploading 10 MB PDF file to SSRS - I need to upload 10 MB pdf file ssrs 2012 I used advice from https://www.mssqltips.com/sqlservertip/4688/resolving-the-maximum-request-length-exceeded-exception-in-sql-server-reporting-services/ and changed maxRequestLength to 1100000 After I restart SSRS I can 't access server SSRS Log file show error bellow The value for the property 'maxRequestLength' is not valid. The error is: The value must be inside the […] |
Design Ideas and Questions |
Is there any way of storing database related information? - Last week I was asked to write a SSRS report against a MySQL database. Never having worked with MySQL, I found this a challenge that I enjoyed. And I got it done. Today we had a follow-up meeting to learn more about the database, what two applications that run against it and other related things. […] |
Storing Unit Of Measures - Hello, What is a good design to store unit of measures ? We have a measure dimension with all the measures and we are building a scorecard fact table that leverages these measures and build performance metrics. I could think of three options with third one as a best pick: Option 1: Build a UOM […] |
Microsoft Access |
MS Access will not allow update or delete commands - MS Access will not allow update or delete commands on an external table in SQL Server. Does anyone ever seen this issue. It's not a rights issue. Using the same account it works directly against SQL Server. Please advise? |
| |
©2019 Redgate Software Ltd, Newnham House, Cambridge Business Park, Cambridge, CB4 0WZ, United Kingdom. All rights reserved. webmaster@sqlservercentral.com |