Transact-SQL
.NET Framework error occurred during execution of user-defined routine or aggregate "geography"
'IF EXISTS(SELECT COUNT(1))' VS 'IF EXISTS(SELECT 1) '
'Incorrect syntax near' error while executing dynamic sql
'INSERT EXEC' within a function did not work
'Sort' in exuction plan is showing more than 90 % cost, what to do?
'TRY_CONVERT' is not a recognized built-in function name
'VARCHAR' is not a recognized built-in function name.
'WHEN MATCHED' cannot appear more than once in a 'UPDATE' clause of a MERGE statement.
"EXECUTE AT" with Dynamic Linked Server Name
"explicit value must be specified for identity column in table" error in SQL 2000
"FROM clause have the same exposed names. Use correlation names to distinguish them"
"No transaction is active." error when trying to send a transactional SQL statment over MSDTC
"Restricted data type attribute violation" error and SQLS 2017, ODBC Drivers 11 & 13 for SQL Server
"SELECT * INTO table FROM" a stored procedure? Possible?
"SELECT COUNT(*) FROM (SELECT..." not working
"SELECT INTO" with indexes?
"Simple" SQL to check for alpha or numeric charcters isn't working right
"String or binary data would be truncated.\r\nThe statement has been terminated."
"String or binary data would be truncated" and field specifications
“Unable to enlist in the transaction” with Oracle linked server from MS SQL Server
[<Name of Missing Index, sysname,>] in non clustered index
[Execute SQL Task] Error: The value type (__ComObject) can only be converted to variables of type Object.
[ODBC Driver Manager] Data source name not found and no default driver specified
[ODBC SQL Server Driver] Invalid Parameter Number/ Invalid Description or Index
[Sql server 2012] Change from vertical to horizontal table as dynamic
@@FETCH_STATUS in nested loops
@@ServerName returns wrong value in SQL SERVER 2008
##TempTable and INSERT-SELECT FROM an existing Table with an IDENTITY column
%rowtype equivalent in SQL server
++ operator in TSQL - bug or feature?
> converts as > & converts as > in XML query whats the solution?
2 tables referencing each other using foreign key.is it possible
2 transactions in one stored procedure
4 digit number to add to table
8 KB pages to MB or GB
9 digit date number (ex.01.01.2014 => 131989761)
A better way to join the same table multiple times?
A cursor with the name ' ' already exists.
A cursor with the name 'cur1' already exists.
A fatal scripting error occurred. The file specified for :r command was not found error, please help.
A file activation error occurred. The physical file name may be incorrect while creating database
A practical approach the Nested Sets when creating hierarchies.
A question about regular expressions in T-SQL
A stored procedure returning a boolean value indicating wheter a specified value exists in a table.
A transport-level error has occurred when receiving results from the server. (provider: TCP Provider, error: 0 - The semaphore timeout period has expired.)
A USE database statement is not allowed in a procedure, function or trigger.
A week this year Against a week this time last year in SQL (NOT MDX)
A WITH keyword and parenthesis are now required
Accent Sensitivity
Access Code - DELETE Statement with DISTINCTROW and T-SQL
Access Now() vs. T-SQL GETDATE() ?
ADD and SUBTRACT depending on the condition is CASE STATEMENT
ADD COLUMN to variable table?
Add prefix in data column
Add Time in SQL HH:MM:SS to another HH:MM:SS
Adding a column to a large (100 million rows) table with default constraint
adding a extra column in a pivot table created uisng T-SQL Pivot Table query
Adding a partition scheme to an existing table.
Adding a Value to a 'date' Column caused an overflow??
Adding Column to existing table with variable column name
Adding Days to Date Field
Adding leading zeroes (PADDING in SQL Server)
adding new column in my linked server
Adding NOT NULL DEFAULT VALUE column to existing table with data
Adding of counter column
Adding varchar(8) in time format that totals more than 24 hrs in SQL
Additional Column With BULK INSERT
Adventureworks query about sales
AFTER INSERT and AFTER UPDATE triggers on same table
After INSERT Trigger question - how to use value from last added record
Age Bucket in sql
Age calculation in report builder query
Aggregated CASE expressions versus the PIVOT operator… Is one better than the other?
Aging Report SQL Query
Alias all columns in a given table
Alias column with variable value in SQL Script
All MonthNames and Month numbers in sql server
All queries combined using a UNION, INTERSECT or EXCEPT operator must have an equal number of expressions in their target lists.
all the events in the workload were ignored due to syntax errors.the most common reason for the error would be database to connect has not been set properly
ALTER AN EXISTING TRIGGER TO ADD A NEW COLUMN
Alter collate of master database
Alter Coulmn takes long time to complete
Alter foreign key column to not Allow null question
Alter Multiple Procedures with One sql script
Alter Stored Procedure is taking huge time in sql server
Alter Table Add Column if Not Exists to update Schema Modification Script
Alter Table add Column - How do you add a column after say the second column
Alter table add constraint primary key clustered identity(1,1)
ALTER TABLE ALTER COLUMN (To set the default value)
ALTER TABLE Progress?
ALTER TABLE SWITCH statement failed. Check constraints or partition function of source table
ALTER TABLE with variable TableName
ALTER vs UPDATE when creating a new column with default value.
Alternate queries for MERGE
Alternative for OR in WHERE clause
Alternative for PIVOT
Alternative of CURSOR in SQL to improve performance ?
alternative query for in clause
Alternative to Full Outer Join
Alternative to Row_Number Query
Alternative way STUFF for XML PATH ('') ?
Am getting an error when i run this code
Ambiguous Column Name
An aggregate may not appear in the set list of an UPDATE statement....
An error occurred while executing batch. Error message is: Error creating window handle. SQL SERVER 2008
An error occurred while executing batch. Error message is: There is not enough space on the disk.
An error occurred while the batch was being executed.
An explicit value for the identity column in table 'Calculation' can only be specified when a column list is used and IDENTITY_INSERT is ON.
An invalid floating point operation occurred
An object or column name is missing or empty
anonymous tables
ANSI_PADDING Issue
Any easy way to change TempDB collation?
Anyway to force SQL server to save store procedure with errors?
Appending a SQL command output file rather than overwriting it?
Appending text to a field that already contains text using TSQL
apply cross apply function on condition
Arabic question mark
Arduino and SQL Server
Are there any Bitmap(ped) indexes in SQL Server?
Are there MIN(A,B) or MAX(A,B) functions in SQL?
Argument data type datetime is invalid for argument 3 of json_modify function
Argument data type sql_variant is invalid for argument 1 of like function
Argument data type text is invalid for argument 29 of checksum function
Argument data type varchar is invalid for argument 1 of formatmessage function
ARITHABORT in the connection string
Arithmetic overflow error converting expression to data type datetime.
Arithmetic overflow error converting expression to data type money.
Arithmetic overflow error converting float to data type numeric
Arithmetic overflow error converting money to data type numeric
Arithmetic overflow error converting numeric to data type varchar
Arithmetic overflow error when using DATEADD with [Timestamp] column in sys.dm_os_ring_buffers
Array as stored procedure parameter
Array data type in SQL server
Array's IN SQL SERVER?
ASCII values for extended characters
Assign empty string '' if datetime is null
Assign EXEC output to Variable
Assigning NULL value to column name using Case Statement of where is SQL SERVER 2008
atomic if not exists() and insert or update
Attempt to fetch logical page (1:155534) in database 7 failed. It belongs to allocation unit 72057595430240256 not to 72057594197835776.
Attempting to grow LOB beyond maximum
Attendance details- calculated the number of days leave ,present for each and every employees
auto fill foreign key
Auto increment a bigint column?
Auto Increment Insert in Merge Syntax
auto-increment column using stored procedure ???
autocommit
Autoincrement existing column sql server
Automated Conversion from T-SQL to ANSI SQL?
Automatic Truncate Long Strings while inserting data.
Automatically import the CSV files from a Folder
Automatically UpperCase ALL MS SQL Server Keywords
AutoNumber in T-SQL Select Statement
AVG ->Operand data type varchar is invalid for avg operator
avoid insertion of duplicate entries in a BULK INSERT statement
Bad performance of EXCEPT operator
Basic - select with fixed values - invert columns to rows
Basic CTE query, get full path of something recursive
BCP Error - Copy direction must be either 'in', 'out' or 'format'.
BCP Export to csv using UTF-8 or UTF-16
BCP Issue when using a format file and excluding columns.
BCP Numeric value out of range
BCP or BULK INSERT? why?
bcp query out format
bcp Unable to resolve column level collations...
bcp utility copies 0 rows
BCP Utility Native Format Error: Unexpected EOF encountered in BCP data-file
Before Delete Trigger
begin tran does the row level lock or table level lock
Begin Transaction with If Condition
BEGIN TRANSACTION within TRY - CATCH or vice versa
Best practice to handle the paging and performance in SQL Stored procedure
Best Practice: Use of semi-colon to terminate statements;
Best practices in writing queries for huge dataset
Best way to delete 311 million records from SQL Server 2017
Best way to Delete million records from billion records table
Best way to Delete the Data
Best way to force materialize a CTE?
Best way to reference calculated fields in a query
Best way to update date to default value if = 1900-01-01
Better Approach to avoid DISTINCT/GROUP BY
Between Date to include Null values
Between Vs Greater Than & Less Than
Big Float?
black diamond with question mark
boolean aggregate function
Building a field name by concatenating strings for SELECT statement
Building where clause dynamically in stored procedure
Bulk Import from files with different column order
bulk insert - Bulk load data conversion error
BULK INSERT - Will not accept datetime value regardless of format.
Bulk Insert -- Access denied issues
BULK INSERT .csv file error
Bulk Insert 0 rows affected
Bulk Insert and Blank Lines
Bulk Insert Arabic Data from .csv file to MS SQL 2008 DB
Bulk Insert error file does not exist
BULK INSERT error Row 1 File Offset 0 ErrorFile Offset 0 - HRESULT 0x80004005.
BULK INSERT Error; Access is Denied.
BULK INSERT error: Bulk load: An unexpected end of file was encountered in the data file.
BULK INSERT failed while loading data from CSV file
Bulk Insert Failing - Error "Cannot bulk load because the file XXX could not be read. ..."
Bulk insert failing on datetime datatype columns
bulk insert for loading .xls (excel files)
Bulk insert from changing file names.
BULK INSERT into "new" table possible?
BULK INSERT into a table variable
Bulk insert into local table from Linked Server table?
BULK INSERT into specific columns?
Bulk Insert issue with pipe field terminator
Bulk Insert limitation?
Bulk insert operation with checking if record exists
Bulk Insert Row Terminator issues
Bulk Insert skipping rows
bulk insert to one column table
Bulk Insert With Conditions
Bulk insert with data having comma
BULK INSERT with unlimited errors
Bulk INsert with variable Lastrow
Bulk Insert Without Locking Table
Bulk Insert. Strange Characters. Please, is really urgent. Thank You.
Bulk load: An unexpected end of file was encountered in the data file
Bulk renaming table names
Calculate Average of Top 10 Records
Calculate current Quarter period and previous 4 Quarter periods based on Todays date.
calculate current Quarter/Review Period and previous four Quarter/Review Periods based on todays date.
Calculate Elapsed Time Between Dates Excluding Weekends
Calculate stock ageing with SQL query
Calculate the date of the Next Sunday of current week
Calculate the number of workdays in a month
Calculate the Numerator and Denominator in 1 query
Calculate the ratio between two columns
Calculate YTD, Previous YTD in the same query
calculated field with decimal place
Calculating 30,60,90 Days Totals in sql
Calculating Average between two datetime columns
Calculating the RATE as the similar financial function in Excel - SQL Server 2014-2016
Call a webservice from TSQL (Stored Procedure)
Call function from view
Call function on Linked server
Call getdate from linked server
call the multiple .sql files through Batch script
Calling the same function multiple times in the same SELECT statement
Can a [non primary key] be referenced as [foriegn key] in other table?
Can a uniqueidentifier have a default value?
can I access function on remote server through linked server?
Can i call a stored procedure in view?.
Can I configure FILESTREAM to use file share?
Can I delete NT SERVICE\SQLWriter and NT SERVICE\Winmgmt logins?
Can I EXECUTE a SQL Server Stored Procedure with Parameters and store the result set to a CTE Table so that I can then UNION to it
Can I find out the "Listener" name through a SQL Server Query
Can i give a rollup an Alias?
Can I have a conditional JOIN?
Can I have a primary key as a non-unique column
Can I pass parameter to an ALTER DATABASE command
Can I prevent deadlock during concurrent delete
Can I print to file using T- SQL
Can I sort an SQL table?
Can I sort row without order by clause
Can I UPDATE, then INSERT if no record updated?
Can I use a COLLATE clause in a temp table definition?
Can I use aggregate function within CASE?
Can I use if statement in a table valued function?
Can I use LEN or DATALENGTH in a WHERE clause?
Can I use OUTER JOIN on 2 columns at the same time?
Can row_number() work in UNION STATEMENTS ?
Can someone explain just exactly why xp_cmdshell is such a massive risk?!
Can SQL Profiler give you the Missing Index information?
Can Symmetric keys be used in a view?
Can table-valued parameter be null?
Can the "print" command be told not to send a "newline"?
Can we alias name for temp table
Can we creating index on non unique value columns on temporary tables
Can we do MAX inside nested CASE Statement?
Can we generate pipe delimited column through SQL query
Can we optimise While Loop in sql server for large number of data?
Can we pass parameters to the trigger?(Beginner)
Can we RAISERROR inside MERGE Statement
Can we select Bottom 1000 rows of a database Table from SSMS 2008 R2?
Can we set value in a variable inside a select statement
can we use CTE for selecting data from excel
Can we use While loop in CTE?
can we write DDL command in Stored Procedure?
Can wildcards be used on datetime column?
can you add colour to a fields output in T-SQL?
Can you change the value of yes or no instead of true or false use data type (BIT) ?
Can you have a TRY CATCH in dynamic SQL?
Can you Select From (another query)?
Can you use a case statement as part of a left join
Can't access temporary table inside function
Can't add datetime column with default value in SQL Server 2005
Can't change the currente collate of my database
Can't copy the result of a query?
Can't declare table parameter as input to stored procedure
Can't delete rows from Mgt Studio view
Can't Enable Foreign Key Constraint (Msg 547, Level 16, State 0, Line 15)
Can't perform emptyfile operation on .mdf?
Can't select DISTINCT values with XML datatype.
Can't use Begin Transaction before a WITH
Cancel Rollback
Cannot ALTER 'dbo.fn_GetDate' because it is being referenced by object
cannot be used in an index or statistics or as a partition key
Cannot continue the execution because the session is in the kill state
Cannot create a row of size 8086 which is greater than the allowable maximum row size of 8060
cannot create an index on a view
Cannot create an instance of OLE DB provider Error 7302.
Cannot detach the database 'BDEV' because it is currently in use.
Cannot drop a SQL Database
cannot drop database because currently its in use
cannot drop table
cannot find tables in SSMS?
Cannot get data of the row from OLE DB provider "OraOLEDB.Oracle" for linked server
Cannot grant, deny, or revoke permissions to sa, dbo, entity owner, information_schema, sys, or yourself.
Cannot insert duplicate key row in object...
Cannot insert the value NULL into column 'ID', table
Cannot open backup device 'C:\TEMP\Demo.bak'. Operating system error 2(The system cannot find the file specified.).
Cannot parse using OPENXML with namespace
Cannot promote the transaction to a distributed transaction because there is an active save point in this transaction
Cannot resolve collation conflict for equal to operation
Cannot resolve the collation conflict
Cannot resolve the collation conflict between "Latin1_General_CI_AI" and "SQL_Latin1_General_CP1_CI_AS" in the replace operation.
Cannot specify an index hint for a remote data source.
Cannot transfer schemabound object - error
Cannot truncate remote table on linked server
Cannot update identity column 'ItemID'.
Cannot update the view or function "CTE" because it contains aggregates or a DISTINCT clause.
Cannot use an aggregate or a subquery in an expression used for the group by list of a GROUP BY clause.
Cannot use the ROLLBACK statement within an INSERT-EXEC statement.
Cant Drop Table
capitalise the first letter of each word in a string in SQL Server.
Capturing the results from exec command
Carriage Return...Line Feed...CHAR(10) and CHAR(13) Help
CASE Expression in conjunction with LEN(gln.GLNumber)
Case expressions may only be nested to level 10.
CASE in JOIN CONDITION
CASE STATEMENT AS A CONDITIONAND ALIAS
CASE statement based on TIME field
case statement for count between two dates
CASE statement in SQL returns Null
CASE statement in WHERE clause for IS NULL: I want to say IS or IS NOT Null for a column using CASE
Case Statement in Where clause with parameters SQL Server
CASE statement inclusion and exclusions
case statement inside a where clause with 'IN' operator
CASE Statement on multiple columns
CASE STATEMENT RETURNING MULTIPLE ROWS
Case Statement returning multiple values
CASE statement returns "Invalid Column Name" Error
Case statement that increments variable with 1 is giving error
Case Statement using Divide
CASE Statement when not null , else if Help
Case statement with Between in Where Clause
Case statement with Date Comparison
CASE statement with substring
CASE WHEN - Adding collate into it.
Case WHEN and concatenate string
CASE WHEN isnumeric(ColValue) THEN ... ELSE ... END
CASE WHEN MIN,SUM ETC.
CASE WHEN Problem with CASE NULL
cast nvarchar to smalldatetime
Cast a varchar(6), 112 as date
CAST and IsNull together
cast or convert nvarchar with comma as decimal separator to decimal
CAST Timestamp to Bigint
CAST() with COLLATE is non-deterministic -- what's the work around?
Casting a NVARCHAR column with percentage as INT
casting data-type nvarchar(100) to uniqueidentifier, how?
Casting to datetime2
Catching Error Message from XP_CMDSHELL
CATS in sql server
CEILING after decimal
Change All Field Names in a Table to have a Lowercase First Letter
change colimn definition from varchar to money
Change Data Type of data retrieved by SELECT query
change first letter in uppercase and and rest lowercase
Change font colour in table cell based on SQL Query in SQL Email
Change index of all tables, in at the databases on a server.
change Minutes and seconds of a datetime value to 0
Change SQL Server dateformat?
Change the row color based on result set
Change the seed & increment value of an identity column.
Changing a primary key clustered index to a non-clustered index
Charindex very bad performance
Check Actual Error from sp_executesql
Check Constraint Across Tables
check constraint calls a stored procedure or trigger
Check Constraint on decimal: restrict user to enter more than 1 digit
Check date format is dd/mm/yyyy
Check for Null Value or Spaces
check for the existence of multiple columns in a table
Check for valid Ip address
Check if amount is positive or negative
Check If Column Is PRIMARY KEY
Check if database exists?
Check if Feb-29 is falling between start and end dates
Check if file exists then delete it- fix code
Check if installed SQL Server is an Eval copy
Check if login has db_owner via user mappings on a specific database
Check if objects already exist (i.e. FILEGROUP and FILE).
check if schema exists
Check if UNC path exists (It is folder, not file)
Check if value is alphanumeric
check isnull for UniqueIdentifier
check table exists
Check valid decimal and integer values using TSQL
Checking for the existence of a SQL Agent Job
Checking how long a Stored procedure has been run?
Checking if xp_cmdshell is enabled or not
Chinese characters issue with T-SQL.
Clear tempDB data
CLR semaphore
Clustered index update in execution plan
Coalesce in JOIN condition
Coalesce with Sum
Code to check IBAN numbers?
Collapse and Expand node in SQL editor not displaying
Collate Database_Default
collation conflict
collation conflict between "Latin1_General_CI_AI" and "SQL_Latin1_General_CP1_CI_AS"
collation conflict between "SQL_Latin1_General_CP1_CI_AS" and "SQL_Latin1_General_CP1_CS_AS" in the equal to operation
Collation Issue in query using except operation
column alias as variable
Column Alias in Where clause
Column already has a DEFAULT bound to it.
Column is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.
Column is not a valid index to enforce a full-text search key. Why?
Column name in table starting with number
Column names in each table must be unique
Column names in each table must be unique. Column name 'Product Description' in table 'Tab' is specified more than once.
Column, parameter, or variable #2: Cannot find data type test_type.
Combining conditional COUNTs in one GROUP BY query
Commenting out an SQL Line when using Dynamic SQL
Common table expression defined but not used.. why?
Common Table Expression Select Into With Subquery
Common Table Expression with Primary Key Syntax???
Common Table Expression...Naming Standard?
Compare address in SQL
Compare BULK INSERT vs INSERT
Compare int to nvarchar ?
Compare the 3 columns and pick up the latest date
Compare two tables on different server
Compare two xml data by xquery in sql server
Comparing columns with NULL values--Merge says unmatched when data is matched.
Comparing two columns using a case statement
Complex string_split / PIVOT challenge
Compose an Email
Composite key and clustered index
Composite Primary Key with Auto Increment Column
COMPUTED COLUMN using deterministic UDF cannot be persisted
Computed Columns in Table Variables or Table Types
computed table cannot be persisted because the column is non-deterministic.
Concat with Auto-increment column
CONCAT_WS Not Recognizable
Concatenate a string to use after the AS statement
Concatenate distinct values to variable
concatenate numbers (not add them)
CONCATENATE ROW_NUMBER WITH LEADING ZERO FOR MAXIMUM OF 15 CHARACTERS
Concatenate two columns using a trigger
Concatenated Stored Procedure parameter value
concatenating in the string and passing parameters with sp_executesql
Concatenating inside EXEC
Condition query to parameter only if parameter has "usable" value?
CONDITIONAL failed because the following SET options have incorrect settings: 'ANSI_PADDING'. V
Conditional If in Where Clause
Conditional Joining tables based on param value
Conditional Unique Constraint
Conditionally CREATE a VIEW in a script
conflicts with the type of other columns specified in the UNPIVOT list
Connecting sysobjects table names with syscolumns names
CONSTRAINT rule of no special characters allowed? Help
consumed workload has syntax errors
contains more than the maximum number of prefixes. The maximum is 2
continue executing sql statements despite errors
Conversion failed when converting character string to smalldatetime data type
Conversion failed when converting date and/or time from character string.
Conversion failed when converting date and/or time from character string. SQL 2008
Conversion failed when converting from a character string to uniqueidentifier.
Conversion failed when converting the nvarchar value 'xxxxxx' to data type int.
Conversion failed when converting the varchar value to data type int.
Conversion failed when converting the varchar value '],[' to data type int.
Conversion of the varchar value overflowed an int column
Convert 3 character month abreviation to equivalent number?
Convert a date column to YYYYMMDD format.
Convert a datetime to YYYYMMDD
Convert a dattime to a date in where clause gives incorrect results
convert am/pm to 24 hour
Convert American to UK date
Convert BIGINT Timestamp to a Datetime
Convert BIGINT Timestamp to a Datetime???
Convert binary data to decimal
Convert binary format date in real date value
convert binary image to jpg image using sql
Convert Binary(32) data into human readable string formata in sql server 2005
Convert Bytes to GB
Convert Bytes to GB and MB to GB
convert comma separated string values into integer values
Convert Cron expression to Datetime
Convert CURRENT_TIMESTAMP as Current date only
convert date from YYYYMM to date for comparison
convert date to bigint - sql server 2014
Convert date to int in sql server 2008
convert date to mm/dd/yyyy
convert date to mmdd
Convert DateTime to a DateTime with Milliseconds format
Convert Datetime to Hour and minute WITHOUT second
Convert DateTime to int
Convert datetime to integer
CONVERT datetime to ISO8601 drops milliseconds
Convert decimal dynamically
Convert Float date time to readable format
Convert float to money
CONVERT FLOAT TO NVARCHAR
Convert from boolean to bit
Convert from Decimal to Hex in SQL
convert from scientific notation
Convert from scientific notation
convert from uniqueidentifier to int?
Convert GUID to bytearray in SQL
convert hh:mm to total decimal hours
convert hh:mm:ss to seconds
Convert int to varchar(max)
Convert Integer To Time Only In SELECT
Convert JPEG images to binary
Convert Military time to Standard time??
convert millisecond to "hh:mm:ss" format
Convert Milliseconds to Seconds
Convert Money field to string
Convert negative number stored as nvarchar
Convert NULL to datetime
Convert Number of Months to Year
Convert Numbers/Currency to Words
Convert nvarchar to date in format yyyy/mm?
Convert nvarchar to decimal
Convert one column of comma delimited data to multiple columns - dynamic (without using Pivot?)
Convert rows to columns without aggregation
Convert SQL datetime to Excel datetime
convert sql variant to date
Convert sql_variant to nvarchar without rounding
Convert string into datetime with timezone
Convert String With Int's Comma Seperated Into Acutal Int's With Commas For Use IN
Convert text from c# byte array to sql timestamp on sql script.
convert the below stored procedure into query
convert the string value to 2 decimal places in nvarchar data
Convert Time in Hours and Minutes to Decimal using T-SQL
Convert time integer to HH:mm:ss
Convert timestamp to varchar
Convert to whole number, no decimal point
Convert UTC time to Local Time (Daylight Savings Included) in SQL 2005
convert value to 2 decimal places?
Convert VARBINARY(MAX) column in human-readable form
convert varchar to decimal
Convert varchar to uniqueidentifier
Convert VARCHAR to XML in SQL Server 2008
Convert varchar(255) to varchar(50)
convert varchar(4) to time
Convert week number to date of 1st day of that week...
convert xml to nvarchar
convert YYYYQ to quarter end date
Converting Binary Column to Decimal in TSQL
Converting Decimal hours to hours and minutes
Converting IST to UTC in SQL server
Converting 13 digit numbers to Date
Converting a BIT value to NVARCHAR
converting a date to char(8) value then compare them as dates
Converting a Hex string to binary
Converting a Negative varchar decimal
Converting alpha-numeric into integer
converting bigint to date
Converting float to date
Converting float to varchar type
Converting from DATETIME TO FLOAT
Converting from dd.mm.yyyy to YYYY-MM-DD
Converting from varbinary to varchar
Converting Hexadecimal to Decimal
Converting Image datatype to Varbinary and Numeric
Converting Integer to IP Format
converting money datatype to varchar with out rounding the value
converting rows into columns when rows are using date.
Converting RTF in a text column to plain text in bulk
Converting seconds to hrs, and minute
Converting SQL Server HashBytes varbinary to Bigint
converting sql_variant column type to int
Converting String Month and Year to DATETIME Format
Converting string without converting to scientific notation and without truncating decimals
Converting UTC Time To Local Time in T-Sql
Converting UTC to Central Time
Converting VARCHAR to SMALLINT
Copy user mapping and server roles from one user login to another
Copy a stored procedure from another database via scripting
Copy all SP's from one Database to another Database using a script
Copy constraints and indexes from one database to another
Copy same data into multiple rows
copy stored procedures from one schema to another in a sql server database through batch
Copy table from one server to another
Copy table Structure including primary keys, index etc.
Copy tables with all constraints
Correct way to run multiple sql scripts from one 'master' script? with logs etc.
Could #TempTable within SP cause lock on tempdb?
Could not complete cursor operation because the table schema changed after the cursor was declared
Could not continue scan with NOLOCK due to data movement -error
Could not convert the data value due to reasons other than sign mismatch or overflow. ADSI Provider
Could not find prepared statement with handle %.
Could not find stored procedure
Could not implicitly convert range values type specified at ordinal 1 to partition function parameter type.
Count consecutive month reset if gap in months
Count decimal without function
Count Distinct based on another column in the same table
Count distinct records per month based on the year filter
Count null value from a table for each columns
count of columns of stored procedure in sql
count of columns with non-zero values
Count of unique combinations
Count subset of rows in subquery?
Count The Number Of Rows Inserted Per Day
Count(*) with Partition by producing the wrong result.
Count(Distinct): missing operator error?
Counting Blank spaces between two words in string
Counting Carriage returns
Counting the '-' (Hyphens) in a string
Country, State and City SQL Database
Couple of questions on SQL Server 2008 - Beginner
Covert sql output into excel and schedule the automate job that runs every friday and send email with attachment .
Coverting UTC date time to local date time in sql server
CR and LF not working in a SELECT statement
create a job without sql job agent
create a matrix table using sql query
Create a matrix table using t-sql
Create a new database from existing mdf file.
Create a percentage from two SUM values
Create a query to remove last two characters of a string
Create a view and change the data types of some variables
Create a writable view in SQL DB
create an index on just the date part of a datetime field
Create Database Failed - Primary file must be at least 3 MB ...
create dynamic tables with select * into using dynamic table names
create fixed length text file from sql data
create fulltext index (if not exists)
Create function with CTE code
create login error:
Create multiple query result in sp_send_dbmail
Create stored procedure if doesn't exists in sysobjects
Create Stored Procedure in Master DB or MSDB?
Create stored procedure on linked server
CREATE TABLE - BIT DataType and Default Value
Create table from stored procedure
Create table help
Create Table with current date as part of the table name
Create Table with variable name
Create temp table and insert records in a while loop
Create trigger based on two tables
Create trigger does not work inside if statement
CREATE TRIGGER IF FIELD IS EMPTY DO NOT INSERT
create trigger on northwind datase .. please help
create TRIGGER remove white spaces from a fields in table-scan and fix
Create Trigger to delete old data first before Inserts.
create view as EXEC sp
Create view dynamic pivot
create view from stored procedure
Create view with NOLOCK
CREATE VIEW WITH PRIMARY KEY
CREATE/ALTER PROCEDURE' must be the first statement in a query batch.
Create/Alter view with declare variable
Created a new column in a select statement .How to use that column name in CASE statement in the same select staetment
Creating a blank text file using SQL code?
Creating a file system folder by using a stored procedure
Creating a join based on calculated fields
Creating a Stored Procedure - Account and transaction
Creating a trigger that will increment a column in one table after an insert has been made in another table
Creating a trigger to automate insert into another table
creating a view using temporary table
Creating a view with a case statement
Creating an Aging report Query
Creating an instance of OLE DB Provider " Microsoft.jet - OLEDB.4.0" for linked server "SNE_SNAP2014"
Creating dummy headers (column names) with union all
Creating multiple stored procedures at once
Creating Permanent Temporary tables
Creating table failed because of the minimum row size
Creating temporary/virtual row on SELECT command of sql-server
Creating user if not exists
cross apply and stored procedure
CROSS Apply Showing NULL Values
Cross Apply versus CTE. What is better in terms of performance?
CROSS APPLY vs. ROW_NUMBER() OVER with JOIN
Cross Join Performance Issue
Crosstab/Pivot with Text Columns and Text Data
CTE and UNION Queries
CTE into temp table
cte order by clause eror
CTE query and OpenQuery mix
CTE To Sum Data
CTE use multiple time in single Store Procedure
CTE with dynamic SQL
CTE with multiple update statements?
CTE, VIEW and Max Recursion: Incorrect Syntax Error Near Keyword Option
Cummulative percentage in SQL Server 2012
Cumulative DIfference/Running Difference in SQL
Current Date minus one year
Current month and Previous Month
Current Month vs Previous Month within single stored procedure
Current Timestamp shows wrong time
CURRENT WEEK SQL QUERY
Cursor already exists
Cursor vs Batch
CURSOR vs. CTE
Cursor with input-parameter
Cursorfetch: The number of variables declared in the INTO list must match that of selected columns.
Cursors vs while loop
Customize email message - SQL Server Agent
Data Archiving/Purging process
Data conversion from non-unicode character to unicode character
Data Pump
Data Truncated using FOR XML PATH
Data type equivalent in T-SQL for the CLOB data type in PL-SQL - SQL Server 2012 and superior
Data Type for saving Base64 image string into SQL database
Data type for unsigned integer?
Database cannot be opened because it is offline
Database Email - Multiple Attachments.
Database is already open and can only have one user at a time
database user can't findagent job
Dataconversion: STRING (yyyymmdd) to DATE
DATALENGTH of Image Column not equal to size of file
DataType Bigger Than VARCHAR(MAX)/NVARCHAR(MAX)
Datatype for storing pdf files?
Date Conversion CONVERT function not working
Date diff Function giving negative values
Date difference in Days,hours minutes and seconds.
DATE FORMAT MMYYYY for current date
Date format with slashes instead of dashes
Date is showing 1900-01-01 instead of blank
date or time that are too negative or large to display as #########
Date time in Open Query
Date Time issue while exporting data from sql server to csv
DATEADD convert minutes to time
DATEADD excluding weekends and holidays
DATEADD in Where Clause
DATEADD with variable datepart?
dateadd(day,-1,getdate()) vs. getdate() - 1
Datediff format Hours, Minutes, Seconds and Milliseconds
Datediff on same column
DATEDIFF only returns integers
DATEDIFF Week - First day of week query
datepart(dw, date)
Datetime - Out of range Datetime Value
DateTime - Time round off to starting of day
DateTime filter is not returning correct results
Datetime in Indian Standard TimeZone (IST)
DateTime Interval in "DD HH:MM:SS"
Datetime Parameter set to Null works or what's wrong?
DATETIME To Format mm/dd/yyyy hh:mm am/pm
Datetimeoffset to DateTime Convert issue in SQL Server 2016 Database
DAYS 360 Function
DB2 Integer YYYYMMDD to a date MM/DD/YYYY within SQL
DBCC CHECKIDENT Permissions
DBCC CHECKIDENT: does the seed accepts null?
DBCC SHRINKFILE: Page could not be moved because it is a work table page.
dbms_lob conversion
dbo and [] for table name sources ? Correct me
Deadlock in tempdb
Deadlock on insert and select on same table
Deadlock while inserting into sql server table from multiple machines
DeadLocks on e_waitPipeNewRow Wait type
Decimal (18,5) to NUMERIC (15,6) Conversion
Decimal comma/point in SQLServer - how to control output
Decimal separator occasionally changes to comma
Decimal value from Year Month Days
Declare multiple values in a variable
declare statement in loops
Declaring a table variable inside a loop does not delete the previous data
declaring local variables in an if statement
DECODE equivalent in SQL SERVER
Decrypt Password using MD5 algorithm in sql server
Decrypt the encrypted store procedure through the T-SQL programming in SQL Server 2005
Decrypt the hashed password in SQL Server 2008
DECRYPTBYPASSPHRASE sometimes returns NULL for the same input and passphrase.
Default DATE and uniqueidentifier parameters?
Default sort order - Open Table - Select without order by
default to '0000-00-00 00:00:00.000' if null datetime
Defaulting a column to be Upper case
Defining a password column in a SQL table - SQL Server 2005
Delete all records in SQL Server Management Studio Table
Delete all rows from a temporary table except those meeting a selection criteria
delete bakups older than 1 day
delete both parent and child table records in one query.
Delete character and everything after it
Delete comma from table column data
Delete data from all tables in a schema
Delete data in Excel using Openrowset?
Delete from Where Exists
DELETE From with sub query
delete large number of rows without growing the transaction log
Delete Query is Performing too slow with around 6 million records to delete
DELETE RECORDS FROM VIEW
Delete Records where total amounts equal 0
delete row or sheet in excel from query
Delete statistics option is disabled when you try to delete statistics in sql server
Delete top 1000 rows from Table in 2 batches
Delete top n rows using join
delete with except
Deleted Microsoft SQL Server folder from C: Drive ...
Deleting a database in RESTRICTED MODE
Deleting all tables in a schema
Deleting all tables in database older than 14 days
Deleting duplicate records in a VERY LARGE table
Deleting records from Self-Referencing Table
deleting rows with null value ba column in sql
DELIMITER through SQLCMD command
Delta process in Stored Procedure
DENSE_RANK() : Start ranking by a no. of my choice and not by 1 ... Can I?
DENY UPDATE/DELETE/INSERT on specific columns to ALL users
Detect Current IDENTITY_INSERT Settings?
Determine if #TempTable has rows
Determine if the database is in Single User or Multi-User
Deterministic GUIDs
DIFFERENCE BETWEEN "INSERT INTO" AND UNION IN SQL
difference between (WITH [tablename] AS) and (DECLARE @[tablename] TABLE)
Difference between APP_NAME() and PROGRAM_NAME()
difference between char(13) and char(10)
Difference Between DB Log File and Transaction log file
Difference between JOIN and Multiple Tables in FROM
Difference between nonclustered and composite index
difference between Numeric and Money Data type in SQL Server
Difference between osql and sqlcmd ?
difference between Outer apply and outer join
Difference between read committed and read committed snapshot isolation
difference between scalar, inline and table valued functions
difference between select * and select column name
Difference between standard sql server and sql server developer edition
Difference Between Two Dates Excluding The Weekends.
Difference between Union All and Full Outer Join
difference between union all, union and intersect and minus in sql server
difference between updatable views and non-updatable views
Difference of Dates in Millisecond
Disable or block TRUNCATE command
DISABLE Trigger ALL on database not working
disadvantages of columnstore index
disadvantages of partition table?
Disconnect all connections
disconnect all the users from database
Display datetime without using colon in the script
Display zero in place of NULL value in date time column
DISTINCT Clause in Cursor SELECT.
Distinct count with multiple columns
distinct vs group by performance wise
Divide time into Morning , After noon , Evening and Night
Do I need to INCLUDE the primary key in an index or not?
Do not select the last row
Does anyone know how to find a period character in a string?
Does case sensitivity affect variable names in stored procedures of case sensitive databases ?
Does LIKE support (or can you code for) an optional character in a string?
Does order matter when doing INSERT?
Does SmallDateTime DateType Not store the seconds in TableColumn in Sql server 2000?
Does SQL Server Support the "MINUS" Keyword?
Does the dataReader permission can create global temp table?
Doing bulk insert with a bit column
Double in sum result from sum and group by query
Drop all constraints in Database
DROP ALL USERS FROM DATABASE
Drop and Create Constraint on Very Large Table
Drop and recreate table in stored procedure
Drop Database Error Msg 3701, Level 11, State 1, Line 1
Drop or Truncate a particular partition.
DROP Table - How to force a delete of a table when constraints are missing?
DROP TABLE does not seem to work.
DROP Table Taking FOREVER
Drop temporary tables from tempdb
Drop User-Defined Table Types
DROP/Truncate Table Hangs
Dropping multiple users
Dummy column in a query
Dumping varbinary(max) column values to files on harddisk using a SQL script
duplicate table names with multiple schema names
Duration of a sql job execution
Dynamic order by
Dynamic Pivot Conflicts with existing name error
Dynamic pivot table with date range
Dynamic Pivot with a where clause
Dynamic Query and print @sql test
dynamic query in view
Dynamic query: EXEC - Need to get a return value from query
Dynamic SELECT column names
Dynamic SQL - creating a temp table with a name that includes a random number
Dynamic SQL for Primary Key Declaration
dynamic sql if condition
Dynamic Sql Pivot- how to sort columns
Dynamic SQL query cannot store more than 4000 characters even with NVARCHAR(MAX)
dynamic sql single quotes
dynamic SQL to list all tables in a database with row count for each table
dynamic sql with CTE and temp table
Dynamic SQL with In Clause
Dynamic wrapping column names in square brackets
Dynamically checking job status with T-SQL
Dynamically create variable names in TSQL
Dynamically set IDENTITY_INSERT ON/OFF in stored procedure
EASY ONE: ALTER DATABASE with Variable
Effect of NOLOCK on a View
email from mssql if some condition is true
Encode from utf-8 to SQL Latin1 General CP1 CI AS
END AS
Enum flag in SQL
Enum in Sql server
Equals Today's Date in SQL
Equivalent of NOCYCLE in SQL
Erreur lors d'execution d'une fonction
Erro: The specified @job_name ('my_job') does not exist.
Error - Incorrect syntax near 'int'.\r\nIncorrect syntax near '?'
Error - Logical file is not part of database. Use RESTORE FILELISTONLY to list the logical file names
Error : The label 'http' has already been declared. Label names must be unique within a query batch or stored procedure.
Error :The cursor is READ ONLY.
Error :UNION ALL view 'address' is not updatable because a partitioning column was not found
Error :Update or insert of view or function 'af' failed because it contains a derived or constant field.
error 'DAYOFWEEK' is not a recognized built-in function name.
Error " "The text, ntext, and image data types are invalid for local variables"
Error "The certificate, asymmetric key, or private key file is not valid or does not exist; or you do not have permissions for it."
ERROR [HY000] [DataDirect][ODBC Progress OpenEdge Wire Protocol driver][OPENEDGE]Invalid date string (7497) (pgoe1022.dll)
Error = [Microsoft][ODBC Driver 13 for SQL Server]Unable to open BCP host data-file
Error =UTF-8 encoding (code page 65001)
error 1603 installing microsoft sql native client
ERROR 214:Procedure expects parameter '@statement' of type 'ntext/nchar/nvarchar'.
Error 3930, The current transaction cannot be committed and cannot support
Error 8623
error computed column or UNION operator while trying to insert records
Error converting data type nvarchar to bigint.
Error converting data type nvarchar to float
Error converting data type varchar to bigint.
Error converting data type varchar to smalldatetime.
Error creating Linked server to access data from SQL to oracle
Error executing ALTER TABLE DROP COLUMN
Error handling in user functions
Error Handling with Bulk Insert
Error in inserting datetime in ms sql..
Error in Query : Msg 258, Cannot call methods on varchar.
Error in query: [..not a valid identifier]
Error in Update SP using TableValued parameter
Error in view when using CONVERT(Date,GETDATE())
error message when remove log file
Error Msg when sending email using sp_send_dbmail
Error severity levels greater than 18 can only be specified by members of the sysadmin role, using the WITH LOG option.
Error validating the default for column
Error when calling a function from inside a function
Error when converting Nvarchar to Float were Null exist in a column being converted(When Joining two table)
Error when referencing Foreign Keys
Error when trying to alter column type
Error while attaching data from the SQL server management studio 2012
Error while creating clustered index view
Error while creating View
Error While enahling CDC(Change data capture) on Table.
Error while executing sp_OAMethod Send
Error while inserting record using OPENQUERY
Error with "The log in this backup set begins at LSN...."
Error with Linked Servers - "Deferred prepare could not be completed."
error-The data types varchar and varbinary are incompatible in the add operator.
Error: 'You can only grant or revoke permissions on objects in the current database'
Error: "Cannot schema bind function 'dbo.test' because name 'dbo.test' is invalid for schema binding. Names must be in two-part format and an object cannot reference itself."
Error: ALTER TABLE ALTER COLUMN ph failed because one or more objects access this column.type
Error: Cannot drop the database because it is being used for replication.
ERROR: date/time field value out of range:
Error: Invalid object name 'UPDATED' in trigger
Error: query processor ran out of internal resources (How can we prevent this)
Error: The data types varchar and varchar are incompatible in the modulo operator.
Error: the database could not be exclusively locked to perform the operation in sql server 2008 ?
Error: Unable to begin a distributed transaction
Error:"XML parsing: line 2, character 15, A string literal was expected"
Errors 2601 and 2627
Escaping a whole string variable in T-SQL
Evaluate percentage using two columns of a table
Exact Match in sql
Exact Word Matching in a Comma Separated Column in SQL Server
Excel data import Truncate Data length to 255
Excel date conversion to sql date
Exception Handling in SQL Functions
Exclude NULL-Values directly from ADSI-SELECT
exec and suppress output
Exec function - Must declare the table variable "@Table".
EXEC in SQL Functions
exec sp_executesql much slower than inline SQL
Execute a Stored Procedure for each row of a select statement
Execute a stored procedure of another server
EXECUTE permission was denied on the object using linked servers
execute sp_executesql into Table-Valued function
Execute Sql query based on condition using Case statement
Execute SQL Query dynamically in multiple databases
Executed as user:. The step was cancelled (stopped) as the result of a stop job request.
ExecuteScalar returns 0 (null) but INSERT is successful.
Executing BCP in stored procedure
Executing SQL directly; no cursor.
executing stored procedure from different server
Executing stored procedure with input parameters using sp_executesql
Executing the batch file from SQL Server Agent job
Execution of user code in the .NET Framework is disabled. How to resolve?
Execution plan Shows distinct sort when order by not in SQL
Expecting Conversation
Expecting Msg 207, Level 16, State 1, Line 1 Invalid column name 'b'.
Explicit conversion from data type int to date is not allowed.
Explicit value must be specified for identity column in table MyTable either when IDENTITY_INSERT is set to ON or when a replication user is inserting into a NOT FOR REPLICATION identity column.
Exponential expressions are failing with "Arithmetic overflow error converting expression to data type float."
Export a SQL Server Result Set from SSMS to Excel
Export BASE64 content to files with BCP Utility
Export image content from database as a file
Export in Excel With using OPENROWSET from Stored Procedure
export multiple sql results into single excel sheet
export nvarchar(max) to text file
Export To Excel With Column Formatting
Exporting CSV files from SQL Server Management Studio 2014
Exporting Data with Text qualifier
Exporting numeric query result in the right format
Exporting Stored Procedure results to Excel
Exporting temporary table to excel spreadsheet
Extract a substring from a varchar(x) variable formated as XML?
extract date from text string - Transact-SQL
Extract directory path from the file path with file name
Extract Image data (storing xml file) from sql server table, shred xml file and load to table
Extract integer portion?
Extract multiple strings between multiple characters in SQL Server 2012
extract string between two characters/string, first character is 'Test Name:' and second character is line break i.e., <br> or end of line.
Extracting domain name from FQDN fully qualified domain name see example
Extracting only year from getdate() function...
Extracting substring between two characters OR Delimeters using TSQL,SQLServer 2008
Extracting time from Date and converting it into 12 hour time
extremely slow: WHERE not exists (select 1 from...
failed because it contains a derived or constant field.
Failed to retrieve data for this request.
Failed to update database because the database is read-only.
Failure when converting character string to uniqueidentifier
fast way to join on "like" operator sql
Faster for xml path('')
Fastest Way to Update Rows in a Large Table in SQL Server
FASTFIRSTROW
Field values from another table as column headers for query
Filestream column
filter out rows in table data which have non-english characters
Find a database size limit from within the SQL Server
Find a String inside nvarchar(max)
Find all rows where the value in one column only occurs once
Find All Special Characters in a SQL Server
Find and insert missing records
Find cascading deletes that effect a specific table
Find creator of a table - SQL Server 2005
find database and table from object id
Find database of the SQL jobs - SQL server agent
find datatypes from stored procedure
Find date closest to getDate()
Find FQDN using TSQL
Find Hexadecimal value
Find IP address of Server instance
Find last record update or inserted date
Find match between two string fields.
Find multiple substring using a single query in single column
Find Multiple Values in a string
Find Non Numeric Value in column?
Find Number of Occurences of character in Given String
Find object owner
Find partitions, row count of each partition of a partition table
Find root of each ID in tree table SQL
Find rows divisible by amount
find table names of the index names in sql server 2000
Find the Bad Row: Arithmetic overflow error converting real to data type numeric.
Find the date of the nearest Monday to a given date
Find the difference between 2 consecutive rows in a sql table
find the range between two decimal numbers
Finding duplicate values for a set of columns in a table
finding duplicate words/phrases in a string
Finding Duplicates with DISTINCT and HAVING
Finding last occurrence of a space in a string
Finding spaces in a string
Finding the second space in a string
First 3 columns data of a table without specifying the column names - SQL Server
First and Last day of previous month from getdate()
Fiscal Week Number
Fixed Prefix Identity Column
Fixing this TRIGGER Syntax
Flashback query equavalant in Sql server
Flatten a Parent-Child Hierarchy data
Float Data Value and Scientific Notation
float to datetime sql
fn_dblog [Log Record] Column
Following query runs in activitymonitor in tempdb.
FOR JSON - How to prevent escaping of data values?
FOR XML output to a file
Force to close existing connections when restoring existing database
Force to complete query, ignore errors
Foreign key <name> references invalid table <Table name>.
foreign key constraint when attempting to truncate table
Foreign key references a two column primary key
FORMAT date versus CONVERT date, huge performance differences
Format equivalent in SQL Server 2008
Format for a bigint parameter in Raiserror
Format number with comma and 1 decimal point
Format number with Thousands separator? 10000 --> 10,000
Format SSN in SQL Server
FORMAT works in 2012 but not in 2008 - What am i missing?
formating msdb.dbo.sp_send_dbmail
Formatting a date as CCYY-MM-DD
Forward Slash in Field Names FOR XML AUTO
Freeing up space in tempdb
Frequently Used Stored Procedure Just Hangs and Does Nothing ... WHY?
Full Outer Join minus Inner Join?
FULL OUTER JOIN with multiple ON / AND clause conditions
FullText Search with symbols: #,$,%,^,&,(,)
Fully Qualified Names
Function for last Sunday of the month
Function Getdate() is not working
Function returns int instead of float
Function to find unicode characters in a string and replace them with a blank
function to return multiple values in SQL SERVER
Function with CASE Statements
Functions not recognized in sql server 2012
Fuzzy String Matching
Geeting TIMEOUT while executing a Stored Procedure.
Generate a alphanumeric id for primary key min 4 digits
Generate all the quarters between start and end dates
Generate email with Embedded Image using SQL Server
Generate n rows in the same query
Generate random number between Two number
Generate random number which is not exist in table
generate random string of length 5 [A-Z][0-9]
Generate the Fiscal Calendar For DateDimension
Generating a Database size report
generating a list of sequential dates
generating custom uniqueidentifier sql server
Generating Insert Script using Select statement
get 10 digit number from string
Get all child and grand child of parent
get all months between two dates in sql with or without data
Get an alert if the query is runnning from more than 5 minuts
Get column name key value when error occurs
Get Column Name which Causing Error in SQL
Get column name with value?
Get column names of table on linked server
Get connecting client PC's name or IP address
Get current directory
get current schema name
get date from GETDATE() without time
Get definition of an index from query in SQL Server
Get Difference between two dates as Hours, Minutes
Get First Node of XML In SQL Query
Get initials from first and last name
Get last 3 previous months records except current
Get Last 6 months data file growth on each database
Get list of email address from a string
Get list of users from AD
Get Max ID from Identity column
Get max length of every column of a table in one query
get MIN date from all tables and columns
Get MIN of Login time and MAX of logout time in sql server.
Get Nth column in a table
Get only first 2 digits from integer
Get only Numeric values from string with alphanumeric values in SQL
Get Previous Business day using custom Holiday table
Get SQL Data from temp table into Excel
Get substring from a text containing quotes
Get substring of file name up to the last underscore
Get the comma separated value and assign to other variable using sql server
Get the Execution Plan of an SPID
get the half of the year (like quarter)
Get the last inserted uniqueidentifier field
Get the quarter of a given date in datetime format
Get the TOP 1 of a Select Distinct
Get the windows UserID who is running the SQL Server Agent Job manually
Get Topmost Parent for a given row in a Parent-Child hierarchy table
Get Total Size of Database with a T-SQL query.
Get values of column in sql server enclosed with single quotes using dynamic sql
getdate with current date and time 00.00.00.000
Getdate() - 1 day of data extraction in query
GetDate() - extracting last 7 days dataset
GetDate() + specific time
getdate() and getutcdate()
GETDATE() get previous month data
GETDATE() retrieve date range using getdate()
Getting "Invalid object name" by creating a temp table and inserting rows right away
GETTING A MONTH BEFORE IN T-SQL
Getting All Days In a Month
Getting all months start and end dates between two dates
Getting Available Server Disk Space (Total Size / Free Space) using T-SQL on SQL 2000
Getting data for same month last year
Getting History of queries run on a database
Getting Identity values after a bulk insert in SQL Server 2008
Getting Invalid filegroup error
Getting last Saturday from a given date
Getting last week same day ,last month same day etc date for today.
Getting LCK_M_IX wait type
Getting list of files, Modified Date from Windows folders/Subfolders using T-SQL
Getting rid of 1900-01-01 00:00:00.000
Getting schedule ID in job step
Getting TDS protocol stream is not valid issue
Getting the data between Sunday and Saturday of last week.(DAYS NOT DATES)
GO command vs EXEC command
Grant create procedure on schema
GRANT CREATE TABLE/PROCEDURE to ROLE on Specific Schema
Grant Execute Right to a login
Grant SELECT, INSERT, UPDATE, DELETE on all table
Granting UPDATE for only certain columns in a table
GROUP BY a column with NULLs
GROUP BY a specified time interval
group by alias name?
Group by data into 15 minute intervals
Group by with partition over and pivot
Group By, needing to exclude a value in group by
Group data by weeks
group_concat in SQL Server 2012 with ORDER BY another column
Grouping by first four characters
Grouping Records into buckets of 15 minutes ....
GUIA - Como buscar una columna en todas las tablas / GUIDE - How to search a column in all tables
Handle Date Time with Null Values
Handling Datetime parameters in stored procedure
Handling Multiple Columns returned by a subquery with an IN Clause
Handling Single Quotation within Dynamic SQL
has fewer columns than were specified in the column list.
Help in Group By clause for excluding null values
Help to get first word from Name column
Help with ALTER TABLE SWITCH (IDENTITY COLUMNS)
Help with Bulk insert with text qualifier "
help-Incorrect syntax near the keyword 'BEGIN'.
Help! Create index with substring
Hex to String
HexaDecimal to string conversion in sql server
Hide SQL SELECT results in the Output window?
Hiding Results Pane from Exec SP
HMAC-SHA256
Ho to Compare two almost similar String
Horizontal sum of columns put in last column of same table
Host_name() in trigger
how to create a month name as a column for a date range dynamically in sql server.
How to Track DML operations in sql server
How big can a temp table be?
How can I check who has created the table in sql server 2008?
How can I convert Float numbers which are represented as 'E-05' to full precision
how can i enforce a null value in int type element in xml?
How can i execute multiple sql queries with one database hit ?
How can I export one column as a separate text file for each row?
How can i find out who did the update OR what changed a record? Please Please help is needed!!
How can I get a row count of CTE recordset?
How can I get sql to get the dates of first Saturday in each month between two dates
How can I get the “file Info” of all files in a directory into a SQL Server 2012 database table?
How can I get the all databases names with it's db_owners in Sql server instance ?
How can I get the Thursday of current week as a date?
How can I have Varchar(MAX) or Text as Stored Procedure Parameter in SQL 2000?
How can I improve Inner Join performance
How can I query the partition scheme and partition function used by a particular table?
How can I read file from filepath and Insert in to SQL Server ?
How Can I Release Lock on Tables?
How can i remove char which I don't see in result set but still they are there
How can I report progress on a long-running query
How can I see what queries were executed at a specific time?
How can i select a max of column witch type is unique identifier
how can i select all columns except one in sql server query
How can i select the step count of a recursive CTE ?
How can i set value of @variable inside with cte ?
How can I treat ZERO and NULL the same in a WHERE clause?
How can I use the function 'CTE' with multiple base tables and Delete the dupulicated row?
How can I view the Locals Window?
How can the rownum of oracle be represented in t-sql???
How can we change the default length of DateTime field in SQL Server
how can we put semi colon in web.config connectionStrings
How can we rollback mistakenly UPDATE statement change in SQL Database.?
How can you get current stored procedure name via T-SQL?
How can you get the current database name via T-SQL?
how create flag variable in sql using condition
How do I achieve - in SQL - something like "On Error Resume Next" in VB?
How do I add a securable to a database role?
How do I aggregate on more than one column within a PIVOT
How do I call a T-SQL Function?
How do I check if #tempTable exists?
How do I check if ANSI_NULLS is turned on or not?
How do i check weather a trigger exists in a database?
How do I collapse contiguous Date Ranges in SQL?
How do I concatenate Year, Month, and Day into an actual date?
How do I convert a timestamp to 'YYYYMM' in Teradata?
how do i delete records from the User defined table types?
How do I export BLOB (varbinary max) column to Excel or CSV file without xp_cmdshell?
How do I filter my SQL Server Query by UTC AT TIME ZONE 'Eastern Standard Time'
How do i find Logins with NO Database mappings?
How do I find which database a stored procedure exists
How do I force a job agent step to fail
How do i generate duplicates based on a column value
How do I get FOR XML to write data with carriage return/line feed at end of elements?
How do I get the fraction values for every row in a table
How do I increment a number in a SELECT statement
how do i increment variables without having to insert them into a second table? no insert!
How do I Join Calendar table with other tables with sparse dates
How do I pass a Date Parameter to a Oracle via an OPENQUERY?
How do I preserve leading zeros in SQL when I export to Excel sheet?
How do I replace entire row data from one table with another?
how do i replace the usage of "connect by prior" in SQL SERVER 2008-R2 ?
How do I return a TRUE or FALSE using a Stored Procedure?
How do I run update query without committing?
How do I use a variable to specify the column name in a select statement?
How do I use my CURSOR Variable in a WHERE Clause
How do I use prompt in TSQL?
How do I view the code of a partition function/schema?
How do tell the difference between the results of two result sets?
How do we reduce performance issue by using order by clause?
How do You Allow NULLs in a Foreign Key
How do you check if an index exists for SQL table column?
How do you combine an insert and update trigger together?
How do you get a TOP 1 in a CTE?
How do you make DISTINCT case sensitive?
How do you trigger a task from SQL Server
how do you write a case statment in Microsoft Access SQL view
How does the IN ( ) clause affect performance?
How find host name (IP Address) from log File?
How finding the creator of an old stored procedure - SQL Server 2014-2016
How get columns from Cursor "Select * From ..."
how i can solve " Incorrect syntax near the keyword 'END' " problem.
How i replace IN CLAUSE into JOIN in SQL Query ?
How important to specify dbo within single schema
How is it possible to use Index Seek for LIKE %search-string% case?
How LOB logical reads Happens
How many columns we can create in a table
How much do CAST statements affect performance?
How Send POST Request with Authorization key using stored procedure
How to allow truncation of Data while inserting from one table to another tabe
HOW TO : send sql mail + attachments dynamic from specific folder
How to access Oracle table from SQL Server ?
How to add 0's before the string in MS SQL server?
How to add a column to this stored procedure?
how to add a comment to a table
How to add a Totals column in a Pivot table?
how to add a where clause by parameter in a stored procedure
How to add colour to html table based on its values?
How to add columns to temporary table in loop
How to add date and time to get datetime2
How to add Dynamic Column to my SQL Select Statement
How to add FILESTREAM attribute to an existing column?
How to add Identity column in a view
How to Add Multiple Column's Sum in Pivot Table...???
How to Add Nameless DEFAULT CONSTRAINT
How to add new line in SELECT Statement
how to add string using a variable in where clause
How to add the condition to CROSS Apply ?
How to add trailing zeroes to Float and nvarchar Data Type in SQL Query
How to add uniqueidentifier data type column in existing table
How to alter a non clustered primary key constraint to clustered
How to alter an existing table column as identity without dropping the table?
How to alter column to identity(1,1)
HOW TO APPLY CASE WHEN IN DATEDIFF?
How to assign a value into a variable from a CTE?
How to assign read only access for a database to a single user?
How to assign results from xp_cmdshell to a SQL variable?
How to assign the result of 'FOR XML PATH' to a variable? Impossible?
How to automatically reseed for specific table max value + 1
How to automatically zip SQL backup file?
How to avoid "'CREATE VIEW' must be the first statement in a query batch" when I need to use SET QUOTED_IDENTIFIER ON
How to avoid clustered index scan in this query
How to avoid cross joins
how to avoid duplicates in CROSS JOIN Query
How to avoid group by many columns
How to avoid null values in PIVOT result set
How to calculate campdate > todays date + 45 days in sql query
How to calculate max value for decimal type
how to calculate MTD, QTD and YTD
how to calculate the fiscal month start and end dates based on the given date
How to calculate the size of a VARBINARY(max) field or variable
how to call a function from inside a trigger..with a cursor?
How to call a stored proc with optional parameters using sp_executesql
How to call Stored procedure in Select statement.
how to call webservice from tsql?
How to Capitalize the first letter in each word in SQL
How to capture the second result set from a stored procedure in a temporary table.
how to change textbox font's color based on some value ssrs tabular report
How to change database back to NORECOVERY MODE FROM RECOVERY MODE
How to change database dynamically inside cursor ?
How to change date to End of Day?
How to change Owner of ReadOnly Database which is configured with logshipping
how to change row's name in the query
how to change the default SQL Time zone to GMT -03:00
How to Change the Tempdb Collation
how to check a date is within current week or current month or next month USING T_SQL
how to check backup status in sql server
HOW TO CHECK EXTENDED PROPERTIES IF EXCISTS OR NOT 'VERSION'
How to check File is Exist or Not in Directory using T-SQL Store Procedure - SQL Server 2005 ?
how to check if a table is partitioned
How to check if data in one table exists in another table
How to check if the file exists or not before bulk insert
How to check if two returned result sets are the same?
How to check referential integrity
How To Check SQL SERVER Uptime Through T-SQL
How to check the Existence of a file & its size using T-SQL in SQL Server 2000?
how to check whether a number is integer?
How to check which stored procedure is running ?
how to checking the ip 4 and ip 6 address valid or not in already existing scalar function in sql server
How to clear uncommitted transaction? (TSQL 2000)
How to code DateTime-Literal in SQL Server
How to combine multiple result sets from WHILE loop?
How To Comment Stored Proc Best Practices
How to commit adding one additional record to an SQL Server database table
How to compare 2 NVARCHAR(MAX) columns in same table ?
How to compare a Date with GetDate() in SQL Server 2000 ?
how to compare from datetime only date,hours and minutes.
How to compare Image data type in SQL SERVER and BLOB in Oracle
how to compare image/varbinary column
how to compare two column e.g. select * from table1 where column1, column2 in (select column1, column2 from table2)
how to concat multiple rows with same id in sql
how to concat year(date) to create a new date 0101 with year
How to concatenate N Prefix to a parameter in sqlserver
how to concatenate special characters in TSQL ?
How to concatenate stored procedure varchar variables
How to concatenate the string and Parameter passed to stored procedure
How to concatenate varbinary?
How to conditionally OUTER APPLY with a function
How to configure SET XACT_ABORT ON permanently with Database Engine
How to connect two sql database in one query?
How to continue execution after error occurs in Stored Procedure ?
How to convert a DateKey representation of a date back into a DateTime data type?
How to convert a decimal(18,4) to a decimal(2,2)?
How to convert a float to timestamp or datetime?
How to convert a number stored as bigint to numeric to include 2 decimal places
How to convert Calendar Month Year to Fiscal Month Year
How to convert client date time to UTC date time in sql server
How to convert comma separated value(120,000 or 12,000) to INT (120,12)
How to Convert date formart yyyymmdd to yyyy/mm/dd in sql server 2008
How to convert date format from 'yyyy-mm-dd hh:mm:ss:mss' to 'yyyy-dd-mm hh:mm:ss:mss' in T-SQL.
How to convert date to integer value in sql server
How to convert Date to mm/dd/yyyy hh:mm:ss: AM PM
How to convert datetime to time in 24 hrs format?
how to convert english to arabic christian date like يناير
How to convert from decimal to binary in SQL?
How to convert HH:MM:SS coulmn in Decimal hours
How to convert horizontal row into vertical SQL Server
how to convert hours to days and months correctly
how to convert image to string and string to image.
How to convert long date to sql date format
How to convert Minutes to hours
How to convert number of days into Months and days
How to convert nvarchar to datetime data-type?
How To Convert nvarchar to DateTime in Where Clause please....
How to convert pl-sql to t-sql?
How to convert Query Result into string
How to convert rich text data field to plain text
How to convert Seconds to HH:MM:ss format
How to convert single digits into two digits in a string ie. 1 to 01
how to convert Time format HH:MM:SS to decimal point
How To Convert Unicode and Hexadecimal Characters
how to copy Previous Cell value when there is null value
how to count number of records inserted in between of running insert statement
How to count occurrences of two or more characters in a string
how to count total left and total right child of a user in downline in a MLM binary Tree
How to create a dynamic multi-line function in SQL Server
How to create a Folder using a SQL Query?
How to create a Local Temp Table using command sp_executesql
How to create a stored procedure that will create a table
How to create a Stored Procedure which will truncate and insert two tables
HOW TO CREATE A TRIGGER TO UPDATE A DATE FIELD WHEN RECORD IS MODIFIED
How to create a view on SQLServer 2008 as an OPENQuery select to a MYSQL linked server
How to create a view with an auto number column?
how to create an sql query to getting profit of each product
How to create and fill a random varbinary table?
How to create dynamic Insert Query Stored Procedure
How to create mdb from sql or sql server???
how to create nested table in sql
How to create ntext Variable in Stored procedure?Required help to execute Query more than 8000 character within a loop.
how to create number 1 to 100 using quary
How to create partition in a large existing table?
How to create rollback scripts
How to create SQL UNION clause with two queries that BOTH have a WHERE clause?
How to create table variables dynamically?
How to create the table name without username attached to it?
How to Create view from multiple views
How to create view from the output of a dynamic sql?
how to create view with default value
How to current logged windows user name in tsql
How to deal with this problem?
how to debug a function step by step
How to debug tsql code in Visual Studio since SSMS v18 does not have a debugger
how to declare a variable similar to table column type?
how to declare variable in table valued function
How to delete ALL jobs from sql server?
How to delete data that not exists in another table?
How to delete duplicate rows from temp table?
How to delete last 6 months data using storedprocedure where table does'nt contains timestamp field
How to delete or drop a cursor?
How to delete Row from table which has FK Constraint on same table
How to delete/drop all the tables from SQL Server Database without using Enterprise Manager?
How to deploy Stored Procedures
How to determine the Number of Cores in sql server 2012
How to disable and enable Unique Constraint of a table
How to disable dataset returned from xp_cmdshell?
How to disable transaction log for specified table
How to display '&' as '&' not as & in t-sql result
How to display a multi-level hierarchy?
How to display columns side by side in sqlserver
How to display values with percentage % symbol in Query ?
How to divide row 1 with row 2 using sql?
how to divide two int numbers and get a fraction ?
how to divide varchar values data with decimal
How to do CONCAT two numbers in sql server?
How to do a Bulk Insert with LF row terminator? Real error may be something different . . .
How to do super fast OFFSET and FETCH ROWS in sql server?
how to download sql server 2016 developer edition
How to drop all indexes and Re-Recreate it in single script
How to drop several stored procedure
How to drop/remove temporary tables from TempDB
how to dynamically add leading zeros in sql query
how to dynamically rename the table in the db?
How to eliminate NULL values from case statement?
How to execute a batch file / cmd file from t-sql
how to execute a long (11000 characters) dynamic query using sp_executesql
how to execute alter statement which truncate data
How to execute dynamic sql from function
How to execute dynamic sql in sql server function and return scalar value
How to execute entire result set of multiple sql statements via sp_executesql?
How to execute multiple sql statements in parallel ?
How to Execute Multiple Stored Procedures at one time?
How to execute procedure in function Sql server ?
How to execute query without using MSSQL Management Studio
How to execute sp_executesql for each row in a result set to perform an update
How to execute stored procedure with a Multiline String Value?
How to execute/call a storeprocedure for multiple records
How to Exit from SQL Server Function ?
How to explicitly set the value of a timestamp(rowversion) column?
How to export data to csv file on a scheduled basis
How to export SQL data to Excel SpreadSheet using SQL Query?
How to export the data to a file (csv) without using xp_cmdshell
How to extract a very very long text string from a varchar(max) feild
How to Extract House Number from Address line in SQL?
how to extract month and year from date column
How to extract numbers from string
How to filter out rows where one column does not equal another on a row?
How to find values in a column has leading and trailing space
How to find a hierarchy of employees, 3 levels deep, using JOINS
How to find a numeric (int, numeric) value in all columns of all tables in database.
How to find a word within a string that contains CHAR(13) + CHAR(10) , CHAR(9)
How to find all child tables that belong to a parent table
how to find all databases collation information and change them to standerd one with script.
How to find all objects that belong to the specific schema?
How to find and eliminate duplicates with very small timestamp differences
How to find blank values in all columns in all tables in database (sql server)
How to find Carriage Return CHAR(13)?
how to find combination of column is unique...
How to find disabled triggers?
How to find Hidden Space/Char in SQL Server?
How to find if a Column is used anywhere in the database
How to find if Quoted_Identifier is on or off?
How to find last login date of a sql login?
How to find list of all partitions of a partitioned table?
How to find list of all SQL servers in my Organization?
How to find list of users having access to a Table
How to find Missing sequence number in T-SQL
How to find multiple strings in the sql database
How to find number of Cores through T-SQL
how to find sql stored procedures without NOLOCK statements in a database
how to find the all databases sizes in sql server 2000 ?
How to find the last execution time of stored procedure sql server 2005
How to find the most expensive operation in an execution plan - need to read xml and sort on calculated field
How to find the space taken by Schema wise in a DB?
How to find the SQL Server install directory from tsql
How to find the user who performed a truncate statement
How to find transaction log backup history using query?
how to find whether is a prime or non prime with one select statement?
How to find which login/user has modified the record in a table in SQL server 2008.
How to find which user has DBO right
How to fix 'Error converting data type varchar to bigint.'?
How to fix an error:"Cannot resolve the collation conflict between "Latin1_General_CI_AI" and..."?
how to format a calculated field with 2-decimal place
How to format bigint values so that 16 digits can be copied to Excel?
How to generate Fiscal year from a date column
How to generate insert table data script programmatically ?
how to Generate missing entries for each month/year and assign to a metric without value the previous month's value
How to generate random date based on date range
How to generate random decimal no by tsql
How to generate random names and mapping to all the tables
How to generate row number in UNION query in VIEW (SQL Server)
how to get 0 if records have empty or null values when column datatype is numeric in sql server
how to get 5 min data from SQL data base
How to get 8 Digit Unique Number in Sql Server
how to get a column index value in SQL
How to get a row count from EXCEPT compare tables query?
how to get a user's permission using T-SQL
how to get all date older than 180 days from getdate()
How to get all field names in a table using sql query?
How to get all the manager of managers above of an employee
How to get begin and end date of any quarter in sql server 2008
how to get count of files
How to get Current Quarter and Fiscal Quarter for a Date - Fiscal Year starts from 1st April
How to get date - last Monday from given date?
how to get distinct count of all columns of a table
How to get Dynamic Column names in SELECT statement
How to get Employee manager hierarchy in Sql ?
How to get first 3 letters and year name from a column in SQL
How to get first month of current year
How to get First Name and Last Name From Full_Name with comma separated
How to get hardware related metrics of SQL Server through query ?
How to get Host name and SQL Instance Name by T-SQL
How to get integer column value Zero as a blank value in Select Query
How to get last months data when executing a stored procedure
how to get Last week data during any time in this week
How to get Leading Zero in Single Digit Date using T-SQL ?
How to get list of primary key columns using sys.sysobjects & sys.syscolumns ?
how to get month end date between two dates.
How to get Month name from YYYYMMDD integer
How to get more than 1000 records in querying AD
How to get OLD and NEW values while writing Triggers in SQL Server 2005 or 2008
How to get OLD value while writting AFTER UPDATE trigger
How to get records that have same id but different name?
How to get rid of Warning: Null value is eliminated by an aggregate or other SET operation.
How to get row_number in sequence in recursive CTE
How to get save result from EXECUTE from a dynamic SQL query in another table?
How to get Schema name from uid column in dbo.sysobjects in sql server 2000?
How to get SQL server IP ?
How to get START DATE and END DATE from month number and Year
How to get string array in string variable in SQL SERVER
How to get tab delimited text file when Stored Procedure executes ?
How to get the table name in the trigger definition without hard coding.
How to get the anniversary calculation correct in SQL server 2008 r2 ?
How to get the closest match strings
How to get the database owner name in T-SQL script
How to get the date using GETDATE in an OPENQUERY?
How to get the last 3 months data at any given point of time using T-SQL?
how to get the last friday of a given date
How to get the list of the invalid objects in the database
How to get the return code of sp_executesql?
How to get the Row count of all tables from all Databases of a SQL Server?
How to get the rowcount for rows inserted and updated in merge procedure
how to get the statement of each spid if it is still running
How to get the Stored Procedure Name inside the Trigger?
How to get the string before dot in SQL.
How to get the Week Number of a Specific Date in SQL Server 2005
how to get this into a table????
How to get view definition in formatted t-sql?
how to get which employee is working all project in sql server
How to grant select on table-valued functions and execute on scalar-valued functions to a user
How to group records in parent child relationship in a table and sort them internally
how to handle 53 rd week in sql server
How to handle identity columns when importing data from Database (table) to another
How to handle ntext/text columns in an AFTER insert/update trigger
How to handle special characters while doing bcp from a sql server 2005 database table
How to handle SQL code for Daylight Savings for MST Time zone
How to handle XML string with Single Quotes as a parameter to SP dynamically?
how to have a decimal in datediff?
How to i set the first char of Name Column always to capital?
How to identify if a date is in Daylight Saving
How to identify non UTF8 CHARACTERs
How to identify SQL Server Job Execution by Unique ID?
How to identify which fields changed between records?
How to identify/troubleshoot - Error SQL72014:.Net SqlClient Data Provider:Msg 1222, Level 16, state 56
How to implement a batch process or job in SQL Server?
How to implement OOP in sql server
How to import photos and the file name into SQL server table
How to improve Query performance on large table in MS SQL Server 2008 R2
How to In Time and Out Time for the Employees whose Shifts are Day Switch?
How to include a single quote in a sql query
How to include custom comments in SQL view creation script
How to increment alphanumeric?
How to insert a Hash value in a table
How to insert 24:00:00 into a datetime field?
How to insert a substring after every nth character of another string?
How to insert data to Oracle table from SQL using linked server?
How To Insert Into Table With Identity Over Linked Server
How to insert into whole year date
How to insert line breaks in a dynamic sql statement?
How to insert more than 5 millions of records to SQL Database table
How to insert rows in chunk size.
How to INSERT SUM into another table
how to insert to smalldatetime in sql-server
How to insert values into multiple tables which is related with primary and foreign keys
How to join 2 tables with same columns but different values
How to join tables on different servers?
How to kill a trigger stuck in an infinite loop
how to kill an open xp_cmdshell
how to know if a column in a table has decimal values
how to know if insertion is successful ?
How to know if Stored Procedure was successfully executed, if no, how to retrieve error logs
How to know list of users who queried the db and what were the queries they fired?
How to know the data size of my select query
how to know the database name if i know the table name
how to know the last row of a cursor
how to know the size of a view
How to load data from csv file into table in SQL Server Management Studio 2014?
How to load sp_who2 results in to a temp table?
How to load xml data into cursor for iterate to insert into table
How to loop through columns in a table using cursor?
how to make a condition statement when Count is = 0 in SQL Server
How to make an update multiple columns using stored procedure at a time using dynamic sql?
How to make FOREIGN KEY and allow to have 0 value
how to make sure for not empty XML element?
How to make the Phone number in a regex pattern??
How To Make Unique Constraint Case Sensitive In SQL SERVER 2008?
how to move table from one database to another database
how to multiply against a negative value?
How to name Excel tabs when export from SSRS 2008
How to open a .trn file from SQL server from Lab.
How to optimize left outer join and how to decide indexes on the left outer join query ? please provide example of it.
How to optimize Update query for 10 Million Records in SQL
how to outer join 3 tables
How to output/print in Triggers
how to pad left and right in sql select statement
How to Parse an XML with Multiple Nodes and Attributes
How to parse SOAP XML in SQL Server and show as table data
How to Partition Table by Uniqueidentifier column SQL Server 2005
How to Pass a filename as variable in OPENROWSET(BULK filename)
How to pass a list of IDs to a stored procedure ?
How to pass array of strings as an input to a function
How to pass database name to the query dynamically
How to pass Datetime value to a tsql stored Procedure
How to pass main query parameter to subquery
How to pass multiple -Variable from powershell invoke-sqlcmd to a tsql script ?
How to pass multiple string values to a stored procedure which accepts a string parameter?
how to pass Multipul integer values to a single parameter in a stored procedure
How to perform cascading inserts?
How to perform SQL Server health check
How to populate a table with dates
How to prevent "Invalid column name" error for not existing column in SELECT?
How to prevent duplicate data insertion with difference of milliseconds
How to prevent duplicate rows inserted by SP called simultaneously by different SPIDs (without unique constraint on table)
How to produce the effect of a date range inner join without actually doing one
How to Query Multiple Columns for Null, Empty, and 0 Values
How to query multiple values in a single SET statement?
How to Quickly Delete Millions of Rows
how to Raise a Error in Case Statement...?
How to re-order the ID column of a table?
How to read foldername from shared location in sql server
How to read JSON from https source?
how to read the value of image data type to plain text??
how to read varbinary data type using sql server
How to read XML parameter data and move to Temp table?
how to reconstruct a .jpg file from the image data
How to recover the deleted stored procedure?
How to reduce Scan count and Logical reads for Query
How to reference a linked server in code
How to remove a Primary Key you don't know?
How to remove box character in SQL
how to remove comma fro sql string
How to remove Hash Join
How to remove milliseconds from datet time
How to remove Namespaces from XML tags when using FOR XML option WITH XMLNAMESPACES
How to Remove Nested Loop
How to remove NULL in column
how to remove numbers in the given string
HOW TO REMOVE SPACE FROM MIDDLE OF STRING ?
how to remove special characters in a particular column
How to remove Table Spool(Eager Spool) from query plan of a function
How to remove those columns with all NULL values?
How to remove XML tags from query result?
How to repeat rows based on column value
How to replace ' by null value in sql server 2008
how to replace 'Like' operator
How to replace (null) values with 0 output in PIVOT
how to replace a character in SSMS
how to replace blank or space with NULL values in a field
How to replace first occurrence of word in TSQL?
How to replace ID with name in the query
How to replace In with Exists
How to replace NULL with 0 in SELECT Statement
How to replace placeholders in a string from a table or list
How to replace the Nulls values in OUTER JOINS with already existing values
How to resolve "Unmatched Indexes" warning.
How to resolve the Creating an instance of the COM component with CLSID {AA40D1D6-CAEF-4A56-B9BB-D0D3DC976BA2} from the IClassFactory failed due to the following error: c001f011. (Microsoft.SqlServer.ManagedDTS)",
How to retreive only columns which having at least one not null value in any row.
How to retrieve a value from EXEC a statement (EXECUTE (@Query) in a stored Procedure?
How to retrieve current step name of currently running job
How to retrieve last inserted row/ record from a table in sql server 2008
How to return multiple values from case statement, SQL 2005
How to return object names from sys.dm_tran_locks?
How to return table name on a select *
How to reuse subquery ?
How to run a large script from sqlcmd and continue despite errors
How to run a store procedure as background Job ?
How to run a stored procedure located in one database against another database
How to run exe file using xp_cmdshell
How to run sql query in bat file in task schedular at every 10 seconds
How to save special characters and symbols to Database
How to Script Out the User Mappings for the Logins\Users?
how to search for Spelling errors with the use of the language dictionary and show The row containing the error ؟
How to see Average CPU utilization by T-SQL
how to see the sql running on a spid (isnt it sql_handle?)
How to SELECT * into a SQL table incremntally by date?
How to select 2nd row from the table?
How to select all columns except one column from a table ?
How to select all fields from a table and only one field from another table with an inner join?
how to select into local variable AND retrieve data?
How to select last N columns
how to select last two words from a string...
How to select only numeric values from a column if it has both numeric and varchar
how to select range of columns SQL
How to select result from a OPENQUERY into a variable
How to select rows that contain substrings from another table
How to Select Tables Using 'LIKE'
how to select the 2nd word in a string?
How to select the nth word in a string?
How to select top 1 from union?
how to select top 1 record per group
How to Send a Message from Stored Procedure to the application
How to Send PDF file as an attachment with sp_send_dbmail?
How to send SQL select output to a txt/csv file
How to set a variable in an if exists statement
How to SET a variable in CASE statement..
How to set auto delete function in SQL Server ?
How to set Identity_Insert in dynamic sql?
How to set SQL Server Login MUST_CHANGE, CHECK_POLICY, CHECK_EXPIRATION all to OFF with T-SQL
How to set the default query for the SSMS 'New Query' button?
how to show columns with two decimal places
how to show only even or odd rows in sql server 2008 ?
how to show your total at the bottom?
How to skip rows in excel file with OPENROWSET
How to solve buffer latches problem
How to solve Hint 'noexpand' on object <Table>"
How to solve this error : The conversion of a nvarchar data type to a datetime data type resulted in an out-of-range value.
How to solve TOP clause contains an invalid value
How to solve Trigger failure with transaction (error 3609)
How to specify decimal size in C# code?
how to speed retrieving data from big table data when select from it?
how to speed up execution time of a stored procedure ?
How to speed up shrinking the mdf file.
How to split a large transaction?
How to Split Address into Multiple Columns in SQL
How to split comma delimited string?
How to split month in to weeks
how to split One column into multiple column through SQL Query
how to split quarters data into months in sql server
How to split string based on either space or tab delimitation?
How to stop execution of stored procedure if error occurs in try/catch block
how to store a value of SUM in the variable to use it in a SELECT clause
How to store Large Amount of Text Data(20000 Charector) in Sql Server?
How to store the result of Exec command into a temp table ?
How to subtract two values from same table but different columns?
How to Sum a data with outer Apply ?
How to Sum a varchar(20) Column?
How to sum all the count ?
How to sum bit values of a column in a group by (aggregrate function for and)
How to switch database inside stored procedure
How to take sum of column with same id in sql?
How to test if User has permissions
How to tokenize a column data of a table in sql?
How to trace a trigger using SQL Profiler?
How to tranfer a column with TimeStamp datatype
How to troubleshoot performance issues due to FETCH API_CURSOR ?
How to truncate extra decimal places?
How to update a query when subquery returned more than 1 value
how to update decimal values in sql server?
How to update foreign key...
how to update multiple columns of a record using subquery ? plz guide
How to update only month part of a datetime
How to Update only the year (yyyy) in the datetime data type using SQL Query?
How to update previously NULL columns using MERGE statement
How to update remote table using openquery
how to update sql table by passing datatable to stored procedure
how to update table rows with random number values?
How to update the date when value in the column Changes
How to update varbinary (max) column
How to use " Use Database " inside stored procedure.
How to use "WITH RESULT SETS" clause in SQL 2012 for dynamic column names.
How to use a CTE in a CASE statement?
How to use a variable as a tablename in INSERT INTO statement
how to use case statement in Split function
How to use comma separated value list in the where clause?
How to use conditional union?
How to Use CTE function in Where Clause or Where In Clause
How to use EXEC with UNION Operator.
How to use execute a procedure with TRUNCATE statement without db-owner right in sql server 2000?
How to use GROUP by When Creating View in TSQL 2008
How to use If condition in Joins
How to use if else condition in case statement using sql server 2008?
how to use IF statement in subquery
how to use IF-THEN-ELSE in a inline table-valued function
how to use iif in sql server 2008?
How to use like operator in dynamic query?
How to use LIKE operator with Varible in Stored Procedure
How to use local variable in a group by clause
How to use local variables in a View?
How to use max(Datetime) in where clause
How to Use Min(date) in case statement)
How To Use More Than 10 Case Statements
How to use multiple 'not like' in a query?
How to use openquery for UTF-8 character
how to use order by in pivot table ?
how to use parameter value as a column name
How to use Regular Expression in SQL Azure
How to Use Sequence Object Inside User-defined Function In SQL Server
How to use SQL Hints within CTE/subquery
How to use switch statement in Stored procedure in sql server 2005
How to use temporary table in WHERE clause?
how to use use coalesce with 0
How to use WITH (NOLOCK) command when querying remote sql server without having linked server
how to use xp_cmdshell to write to text file
How to validate SQL Login Credientials - Userid and Password using tsql
How to validate three digits before decimal and after decimal point six digits in SQL Server
How to verify execute permission on stored procedure using query
How to verify Valid Social Security Numbers
How to wait for event to finish execution?
How to work out the difference of two numbers in SQL table.
How to write a sql query to remove non-printable characters in a column but keeping the carriage return?
How to write a trigger to update uniqueidentifier field?
How to write EXEC in select statement
How to write If-Else Condition inside cursor
How to write query to access multiple databases.
How to write SQL Delete script with Row_number
How to write SQL Query and running in parallel within stored procedure ?
how to write string lines to a text file from a T-SQL script?
How to: 1) Insert a range of values into a table with a single identity column 2) Rank the results without using any functions
How To: Save a string with more than 255 characters?
How use "Description" as a column name
how we can see existing table definition
HOW-TO Change "text" column to "ntext" that is NOT NULL
How-To Copy SQL Agent Jobs between servers with script.
HTML Code Inside SQL
HTML formatting using TSQL
HTTP POST WITH FORM DATA
i am getting error as An explicit value for the identity column in table 'product' can only be specified when a column list is used and IDENTITY_INSERT is ON.
I can add 1 to Charindex() function, but I can't minus 1
i hav 10 tables how many join conditions are possible
I have columns in my database that are zero length but not null
I keep getting this error: Msg 142, Level 15, State 2, Line 0 Incorrect syntax for definition of the 'TABLE' constraint
I need a ZEROFILL in SQL SERVER 2005!!
I need help understanding the difference between cursors and set based querying
I need to filter out non-latin characters. For example, thai and chinese.
I need to null the numeric and decimal fields in a table (SQL 2008)
I need to pull only text from the RTF data of a column in a table
I need to select only value which starts with number using sql query
I ran dbcc checkdb on one testdatabase ,getting following errors, how to fix it?
I Want to create a table variable from another TABLE
I want to highlight the rows having Invalid status using SQL HTML
I want to raiserror within a function
ICD-10 Code Ranges for Diagnoses
Identify and Stop stored proc from running
identify which query or stored procedure is causing locks
Identity auto-increment column per/based another column
identity column in union query
IDENTITY_INSERT in transaction?
IDENTITY_INSERT not working
IF condition JOIN this or this
IF ELSE and TEMP TABLES
If Error do nothing ELSE process the query
IF EXISTS .......Incorrect syntax near ')'.
if exists ..drop table on linked server.
IF Exists Then Drop Job
If I stop a Microsoft SQL query before completion could any rows be affected?
IF NOT EXIST and IF EXISTS question
IF NOT EXISTS and CREATE SCHEMA
if nvarchar(50) actual size is 100 then what should i state in .NET SQL Paramerer variable?
IF STATEMENT WITH A CASE STATEMENT WITHIN A SQL SELECT
if there's any errors stop running the remaining of the script possible?
IFNULL replacement function
Ignore error row when update or insert ms sql server
ignore first row of data file in bulk insert
Ignore milliseconds on SELECT query?
ignore null valued in union
Ignore primary key violation when inserting to table
Implicit conversion from data type nvarchar to varbinary is not allowed. Use the CONVERT function to run this query.
Implicit Conversion from data type sql_variant to datetime is not allowed.
Implicit conversion from data type sql_variant to varchar is not allowed. Use the CONVERT function to run this query.
Implicit conversion from data type varbinary to datetime2 is not allowed
Implicit conversion from data type varchar to varbinary is not allowed. Use the CONVERT function to run this query
Implicit conversion from datetime to float not allowed
Implicit conversion of varchar value to varchar cannot be performed because the collation of the value is unresolved due to a collation conflict.
Implimenting SCD type 2 without Merge
import csv file using stored procedure
Import only first row from CSV file
Import Tab Delimited file
Import xlsb and xlsx files into SQL Server 2005 table using Import task.
Import/Export of CSV files takes default varchar data types
importing parquet file in SQL Server
Improve performance of insert query using linked server
IN clause extremely slow
In Clause in Stored Procedure
IN CLAUSE not working
In SQL can we pass optional parameter to the function
In T-SQL, Want to replace , (Comma) with ',' (Single quote & Comma). It is throwing Error
In WHICH year where the MOST NUMBER of programmer born?
IN,EXISTS or INNER JOIN - which one is the best (performance wise)
Include NULL values in GROUP BY selection
Include table name in column header?
Incorrect date format being used on SQL Server database
Incorrect Syntax error when using #temp table
Incorrect syntax near ','
Incorrect Syntax near '|'
Incorrect syntax near 'DISTRIBUTION'. Unable to use the word DISTRTIBUTION in TRANSACT_SQL
Incorrect syntax near 'END'
Incorrect syntax near 'GO' in dynamic SQL
Incorrect Syntax near 'in'. Expecting ID error message
incorrect syntax near microsoft sql server error 102
Incorrect syntax near the keyword 'CROSS'.
Incorrect syntax near the keyword 'DECLARE'.
Incorrect syntax near the keyword 'DROP'.
Incorrect syntax near the keyword 'ELSE'.
Incorrect syntax near the keyword 'EXEC'
Incorrect syntax near the keyword 'FROM'
Incorrect syntax near the keyword 'identity'.
Incorrect syntax near the keyword 'IF'. please Help
Incorrect syntax near the keyword 'PROCEDURE'
Incorrect Syntax near the Keyword 'RETURN'
Incorrect syntax near the keyword 'SELECT'
Incorrect syntax near the keyword 'SET'.
Incorrect syntax near the keyword 'WHILE'.
Incorrect Syntax near the keyword CONVERT when the syntax is correct - Why?
incorrect syntax near try, expecting conversation
Incorrect Syntax: Create Procedure must be the only statement in the batch
Increasing timeout in a stored procedure
Increment value using Cursor or Update statement
Incrementing numbers based on previous record values
Index hint in delete statement?
index or multiply columns PK in table-valued function?
Index usage in Linked server queries
Indexed View with Union operator between my tables
indexes lost in common table expressions??
INFORMATION_SCHEMA.Columns vs. sys.columns
INNER JOIN After LEFT OUTER JOIN
INNER JOIN from an OPENQUERY
Inner join not working OR I am a stupid
INNER JOIN or LEFT JOIN using CASE expression value
INNER JOIN through View extremely slow
Inner Join with a SELECT Statement and outside WHERE clause throws unexpected error
Inner Join with a table Variable
Inner join with different type data
Inner join with table brought from stored procedure
Inner Join without Foreign key
Inner joins using case or if-else statement
INNER LOOP JOIN
INSERT ... SELECT should I always use WITH (TABLOCK) and how can i verify if minimal logging was performed?
Insert "dummy" record into each group
Insert 100 million records from one table to another in batches
Insert a count(*) into a temp table
Insert a new record into a table that has a primary key
Insert a PDF file into a table with SQL
Insert and Update at the same time
Insert data in parent and child table (one row in parent table and multiple rows in child table)
Insert data to Parent and Child table
insert data to table from batch file?
Insert Empty row depending on group data
INSERT EXEC failed because the stored procedure altered the schema of the target table.
INSERT EXEC Statement cannot be nested
INSERT failed because the following SET options have incorrect settings: 'ARITHABORT'
INSERT failed because the following SET options have incorrect settings: 'QUOTED_IDENTIFIER'
Insert Hexstring Values into table of binary datatype
Insert huge data from one table to another table in batches
Insert images into image datatype using SQL
INSERT INTO as SELECT with ORDER BY
insert into does not insert in order?
INSERT INTO in batches
Insert into table from another stored procedure does not work when stored procedure has timestamp column
insert into table one or Multiple result sets from stored procedure
INSERT INTO table using dynamic sql
Insert Into Table Variable Slow
insert into temporary table by splitting string in sql
INSERT INTO using SELECT with OUTPUT INTO - multi-part identifier could not be bound
insert into varchar(max) truncation issue
Insert Into Where Not Exists
insert into with cast datetime
Insert into with dynamic SQL and Cursor for variable table/columns according to update list
insert millions of records
insert more than 1000 rows
insert mulitple comma seperated values in a temp table
Insert null instead of empty string
Insert on Not exist trigger
insert only time in sql server database
Insert Query not inserting new record at the end of table.
Insert row into a table with a date in dd/mm/yyyy format
Insert row only if table is empty
INSERT Same record 1000 times
INSERT script to allow ampersands and apostrophes
Insert SQL Stmt with datetime conversion
INSERT statement conflicted with COLUMN FOREIGN KEY SAME TABLE constraint
Insert turkish character problem
Insert Word document file into SQL Server table
INSERT...SELECT command with a timestamp column
Inserting .png file as VARBINARY (no c#)
Inserting a large amount of data in SQL table
Inserting an Image using OPENROWSET
inserting data into another table using OPENQUERY
Inserting default value instead of null
Inserting million of rows with help of while loop
Inserting multiple rows from Comma separated list in a variable
Inserting rows into remote server with identity column
Inserting to column of type "time". Getting error "Parameter Validation Failed, Invalid time error"
inserting unicode text into varchar column ?
Inserting varbinary into a table
Inserts only if not exists in the highly concurrent system.
Instead Of Insert Trigger check 2 table before insert
instrrev function in T-SQL
Insufficient result space to convert uniqueidentifier value to char
Integer to Hex & Hex to String
Intermittent "Unable to complete login process due to delay in opening server connection."
Internal Query Processor Error: The query processor could not produce a query plan. For more information, contact Customer Support Services.
Invalid column name
Invalid column name after Adding New Column
Invalid column name although the column exists in SQL 2008
Invalid Column name error coming up when trying to delete a row
Invalid column name for GROUP BY...
Invalid Format Specification: '%'
invalid in the HAVING clause because it is not contained in either an aggregate function or the GROUP BY clause question
Invalid length parameter passed to the LEFT or SUBSTRING function
Invalid object name '##Temp_Data_Final'
Invalid object name '#TmpTable' whenselecting from temporary table made using INTO from exec(@str)
Invalid object name 'INFORMATION_SCHEMA.tables'
Invalid use of a side-effecting operator 'INSERT EXEC' within a function
Invalid use of a side-effecting operator 'newid' within a function
Invoke-Sqlcmd : Incorrect syntax near ','.
Is "select * into Table from exec Stored_Procedure" really working?
is a BEGIN TRAN / COMMIT usefull without ROLLBACK?
Is index on uniqueidentifier useful?
Is it necessary to clean up (drop) temporary tables in stored procedures?
Is it possible to allow NULL values in foreign key?
Is it possible to create table variable by copying structure of existing table?
Is it possible to declare a temp table with all columns and with one identity column.
Is it possible to force the query to use parallelism?
Is it possible to format date without leading zeros?
Is it possible to have a stored procedure with optional user-defined table type parameters?
Is it possible to pass TABLE as the output parameter in stored procedure
Is it possible to select columns conditionally in the SELECT clause of a T-SQL query?
Is it Possible to Use dense_Rank and Where Clauses Regarding dense_Rank in One Statement?
Is it Possible to use XMLNAMESPACES and a CTE at the Same Time?
Is not a recognized cursor option
Is SQL SERVER database can allow a NON-UNIQUE PRIMARY KEY.
is the word "description" a reserved word in sql server?
Is there a basic function for calculating a trend in SQL 2000?
Is there a built in unique identifier for records in an SQL Server table?
Is there a fast(er) way to retrieve a MAX(value) from myHugeTable Where something = x ? (sql server 2005)
Is there a function like SUBSTRING but for integers?
Is There a Keyword or Function Opposite of TOP? How Do I get Various LOWEST/BOTTOM Values?
Is there a reason for these WITH NOCHECK / CHECK CONSTRAINT
Is there a SQL Server 2005 equivalant function to excel's function MROUND?
Is there a way of adding bold font in T-SQL?
Is there a way to convert varchar to decimal
Is there a way to determine stored procedure complexity?
Is there a way to insert the output of 'RESTORE HEADERONLY' or 'RESTORE FILELISTONLY' to a table?
Is there a way to use a conditional where clause
Is there a way to use aliases in a calculation?
Is there a work-around to create indexes for a view defined by a sub-query, derived table, or CTE?
Is there anyway to rollback single T-SQL in SQL Server Management Studio?
Is there anyway to see the content in a temp table while debuging a stored procedure in VS.NET
Is there way to get last updated column name/id in sql server ?
Is Truncate a DDL command or DML command?
Is UNION ALL a costly query?
Is WITH (HOLDLOCK) still needed for using MERGE as an upsert
ISNULL not working???
ISNULL(DISTINCT...
isnumeric/isdate in a case statement doesnt do what i thought it would
Issue When Converting sql_variant to nvarchar (Msg 257, Level 16, State 3, Line 16)
Issue when use for xml path and HTML tag
Issue with xp_instance_regread
It is possible to alter multiple columns within a single alter table statement?
Iterate stored procedure for each row of CTE output
Iterate through all databases in my instance
Iterate through table valued parameter and update the table having same id in table and table valued parameter
Iterating over the inserted table of an insert trigger
Iterating through a group.
Its maximum row size exceeds the allowed maximum of 8060 bytes. INSERT or UPDATE to this table will fail if the resulting row exceeds the size limit.
Japanese Character Bulk Insert
Job fails from warnings? Null value is eliminated by an aggregate
Job problem : The process could not be created for step 1 ...
Join between view and table
JOIN ON varchar VS join on int
Join Tables on Condition if the parameter is not null
Join Two table and create an insert store procedure
Join Two Tables on Closest Date
Joining on columns with float data types
Joining to an excel spreadsheet?
Joining two subqueries or joining a query with a subquery
JSON_MODIFY reference path from declared varible as array index
Julian Date in SQL Statement
Julian Date to Date(time) Conversion
Keeps asking for rpt file when executing store procedure
Kill all connections with SET SINGLE_USER for different DB
kill just connections to a table instead of database ?
Kill process error: only user processes can be killed
Kill with status only shows 'Estimated rollback completion: 0%. Estimated time remaining: 0 seconds'
KILLED/ROLLBACK session
LAG & LEAD functions... Any Way to Retrieve the 1st non-NULL Values?
Lag and Lead not recognized
Large Dynamic SQL Statement being truncated.
Large Table - Move to different Filegroup - Best and Fast way
Last Login Date/Time of All SQL Server Logins From sys.server_principals
Last Modified date of the database
LCK M SCH S lock waiting time
ldf size bigger than mdf
Left Join - only first 'match' ...
Left join Eliminating NULL values
left join on linked server
LEFT OUTER JOIN behaving like INNER JOIN
LEFT OUTER JOIN without a JOIN condition
length of nvarchar column in system tables
LIKE '% [a-z]%'
LIKE '%[^0-9]%' behaviour
LIKE NULL + '%' ?
LIKE operator not working!
Like operator with Integers
LIKE query on varchar(max) or nvarchar(max) columns
Like vs. CharIndex
Limit to number of INSERT statements or VALUES clauses
Limiting a column to alpha-numeric values
Line Break in Concatenation
Line break or Carriage return in a Delimited Field in Sql
Linked Server Authentication Error - [SQLSTATE 42000] (Error 7303)
linked server error
Linked Server Error
linked server exec stored procdure results in Transaction context in use by another session.
Linked Server Giving an Error Message: The OLE DB provider "SQLNCLI11" for linked server "LinkedServerName" reported an error. Execution terminated by the provider because a resource limit was reached.
Linked Server Performance vs Open Query
Linked server permissions error
Linked Server to comma delimted Text Files
Linked Servers OPENQUERY error "Deferred prepare could not be completed"
List all filegroups for all databases ?
List all weeks StartDate, EndDates of given month and year (2014-01-01)
List of integers as single parameter in Stored procedure
List tables and column names a stored procedure is querying
localhost sql server installation
Lock request timeout period exceeded error when expand table list in SSMS 2008 R2
log files doesn't clear after full backup
Logging messages even if transaction is rolled back
login as windows authentication using sqlcmd
Looking for a Guid() pattern in TSQL
Loop through parameters inside Stored Procedure
Loop through Query Results and Send Dynamic Content mail from DB Mail
Loop through string value t-sql
loop through temp table
loop through the folder and load all the files into a sql table
Looping Cursor through columns of a Row
Looping through column names and make alias names using CURSOR
Looping through month in a range of dates?
Looping through SELECT statement results to assign to variable
losing digits when divide two values with decimal data type
LTRIM and RTRIM does not remove spaces.
making sql server database read -write from read only
Making the INSERT script Re-runnable
many ways to calculate the first day of the year in T-SQL
master.sys.xp_DirTree
Max number of elements allowed in an IN clause.
max value for int identity column
Max Value from Zero (Positive or Negative) Help
max value on IDENTITY
MAX(Date) from Multiple Tables
Maximum impersonation nesting level exceeded
maximum length of a sql statement
Maximum Number of Index per Table & Max No Of Columns in Non-Cluster Index in SQL Server 2005/2008/2012?
Maximum Parameters in Where Clause
Maximum Row should return in Join condition Right,Left and Inner
Meaning of "Grant Alter to <User>" ?
Merge error handling
MERGE for Remote Table
Merge for soft delete - Datawarehouse
MERGE ON 1=0
Merge overlapping date ranges, keep adjacent in tact
Merge statement conflict with FK
Merge Statement Taking Long Time
MERGE statement throws Violation of PRIMARY KEY constraint ''. Cannot insert duplicate key in object '' exception in SQL Server 2008
merge the output of two stored procedures
Microsoft SQL Server Error 5170 when creating table
Migrate an execution plan from one sql server instance to another
Migrate BLOB from text data type to Varbinary(max)
Millisecond resolution in DATETIME comparison
min(rank) and max(rank) over partitioned Row_Number
Minutes between two dates excluding holiday's and outside work hours
Missing Headers - Exporting SQL query result set to Excel file
Missing statistic
mm/yyyy format sorting
Modify Computed Columns Using T-SQL
Modify the COMPUTED COLUMN to PERSISTED
Month & Year as parameter in SQL query?
More columns name than defined...?! Problem in a view...
Most efficient way: Checking for an invalid character in a database field
Move Data from Temp TAble to Flat File
move files from one location to another using xp_cmdshell
Msg 102, Level 15, State 1, Line 1, Incorrect syntax near ','.
Msg 102, Level 15, State 1, Line 2 Incorrect syntax near 'MODIFY'
Msg 105, Level 15, State 1
Msg 110, There are fewer columns in the INSERT statement than values specified in the VALUES clause. The number of values in the VALUES clause must match the number of column
Msg 15135, Procedure sp_addextendedproperty, Object is invalid. Extended properties are not permitted on
Msg 153, Level 15, State 1, Line 4 Invalid usage of the option filename in the CREATE/ALTER DATABASE statement.
Msg 156, Level 15, State 1, Line 4 Incorrect syntax near the keyword 'VIEW'.
Msg 208, Level 16, State 6, Procedure VB_SW_updates, Line 113. Invalid object name
Msg 242, Level 16, State 3, Line 2 The conversion of a datetime2 data type to a datetime data type resulted in an out-of-range value
MSG 3154 The backup set holds a backup of a database other than the existing database.
Msg 3609, Level 16, State 1, Line 1 The transaction ended in the trigger. The batch has been aborted.
Msg 3616 Transaction doomed, Triggers and Error logging
Msg 4145, Level 15, State 1, Line 1 An expression of non-boolean type specified in a context where a condition is expected, near 'Name'.
Msg 468, Level 16, State 9, Procedure "procedurename", Line 129 Cannot resolve the collation conflict between "Latin1_General_CI_AS" and "SQL_Latin1_General_CP1_CI_AS" in the equal to operation.
Msg 512, Level 16, State 1, Line 1 Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
Msg 7399 and Msg 7303 - Cannot initialize the data source object of OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "(null)"
Msg 7601, Level 16, State 2, Line 1 Cannot use a CONTAINS or FREETEXT predicate on table or indexed view 'content' because it is not full-text indexed.
Msg 8115, Level 16, State 2, Line 1 Arithmetic overflow error converting expression to data type datetime.
Msg 8115, Level 16, State 2, Line 1 Arithmetic overflow error converting expression to data type int.
Msg 8120, Level 16, State 1, Line 20
Msg 8120, Level 16, State 1, Line 7: Aggregate Function or Group By Error
Msg 8631 Internal error: Server stack limit has been reached on SQL Server 2012 from T-SQL script that runs on SQL Server 2008 R2
Msg 911, Level 16, State 1, Line 1 Database 'databasename' does not exist. Make sure that the name is entered correctly.
Msg, Level, State, Line
Multi UNPIVOT
Multi-threading options in SQL for stored procedure
Multiple columns are specified in an aggregated expression containing an outer reference...
Multiple Cross Apply
Multiple date parameters in WHERE clause
multiple if conditions
Multiple LIKE statements in one WHERE Clause (was:LIKE)
Multiple Select statements in Single Stored Procedure
Multiple select with single CTE
Multiple SELECTs into a temp table not working
Multiple sp_rename in Transact-SQL Script won't work
Multiple String Comparison using LIKE and IN
Multiple Tables with a CURSOR
multiple transactions on the same table ?
Multiple update statements within a Merge Statement
Must declare the scalar variable "@StartDate"
mysterious results using NULLS and UNION statements.
Naming a Sub Query
naming conventions for constraints
need a function to split parameter in ssrs report.
NEED ALTER TABLE ALTER COLUMN FOR DATE FORMAT
need decimal data after division
Need help inserting multiple records and grabbing their scope_identity for another insert
NEED Help SQL Use CASE and a JOIN Statement
need help with case statements with overlapping rules
Need help with running javascript in stored procedure within the html body
Need help with trigger for looping through multiple values from inserted
Need help! Issue getting TempDB files removed
Need powershell script to run sql query import result to Excel
need string part after second hyphen?
Need table count, index count, views count, procedures count for all databases
Need to Capitalize the First Letter ONLY, and leave the rest lower case. Help please.
Need to combine month and year to get date YYYY-MM-DD format
Need to convert a NVARCHAR YYYYMMDDHHMM string to SQL Server DATETIME -3d
Need to find an ip address pattern in a column
Need to generate update queries from existing table
need to get the date culture info of DATETIME column
Need to know the table creation date
Need to read Binary Data as Little Endian instead of Big Endian
Need to select column with line breaks as separate records
Need to use dynamic column names in select statement of any tables
need to write reverse to coalesce function
Need week Number for 'x' month starting week on Monday
Negative VARCHAR to negative NUMERIC SQL Server
NESTED IF
NESTED IF ELSE SQL STORED procedure
Nested select order by
Nested Stored Procedures Try/Catch Error Handling
NET_ADDRESS in the master.dbo.sysprocesses table
New Line and Carriage return lost when string variable is passed to Stored procedure
New Line Character IN SQL
New line is not working in Sql Query
Newbie to SQL: How to group Varchar columns like with GROUP BY
No column name was specified for column 2 of 'cte1'.
No duplicates exist but get Msg 2627, Cannot insert duplicate key in object
No logging in sql server
No way to: SELECT * FROM MY_TABLE ORDER BY PRIMARY KEY??
NOLOCK and COUNT(*)
NOLOCK or WITH(NOLOCK) SQL SEVER 2012
Non Ansi style Left Outer Join
non breaking space characters
Non-Unique index
None of the result expressions in a CASE specification can be NULL
Normalize data in Excel Spreadsheet and create SQL tables.
NORMSDIST equivalent in T-SQL?
Not able to drop Unique Non Clustered Index
Not able to insert special character like 'ł', 'ş' in SQL SERVER.
NOT Exists with Select 1 - Confusing!!!
NOT IN filter in SQL behaviour based on data type
Not IN with multiple columns
NULL recognized as int?
Null value in bit field.
Null value is eliminated by an aggregate or other SET
Null value is not accepting when use Hashbytes
NULL Values in Foreign Keys? Best Practice
Numbers Increment inside a CTE
Numeric (19,5) increase precision to 7 decimal places
Numeric vs int and bigint
NVARCHAR (MAX) TO PRINT DYNAMIC SQL QUERY TO A SQL FILE
Nvarchar of length -1. what does this signify ?
NVarchar(max)
NVARCHAR(MAX) return type value in User defined function truncated
nvarchar(max) still being truncated
nvl in sqlserver
OBJECT_ID for a PK or Index
OBJECT_ID('tempdb..#foo')
objectlock lockPartition=0 - does that mean lock partitioning is turned on?
Obtain table output table variable in a dynamic tsql
OFFSET FETCH is not working in SQL Sever 2012
OFFSET FETCH NOT WORKING
OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "(null)" returned message "Unspecified error".
OLE DB provider "SQLNCLI11" for linked server "192.168.0.7" returned message "The partner transaction manager has disabled its support for remote/network transactions.".
OLE DB provider "SQLNCLI11" for linked server "Deferred prepare could not be completed."
On OPENQUERY Usage with LOCAL Server
On SQL_Latin1_General_CP1_CI_AS SQL Server 2008 Default Collation
One trigger for all tables
One-part name VS two-part name
Only functions and extended stored procedures can be executed from within a function.
Open Query VS Exec at
OPENJSON returning NULL
OPENQUERY and Active Directory problem
openquery concatenation
OPENQUERY Error when calling usp - object has no columns or the current user does not have permissions
OpenQuery in a FUNCTION
OpenQuery Limitation, Max 8000 character
OPENQUERY parameter length limitation of 8000 characters
openquery update and optimistic concurrency
Openquery Update with a parameter
OPENQUERY with quotes in the query string
Openrow set and dynamic query
OPENROWSET & Multiple files
OPENROWSET error MSDASQL
OPENROWSET getting column names
openrowset stored procedure passing parameters
openrowset using sql server authentication
OpenXML and Cross Apply Query Help !
Operand data type bit is invalid for max operator Error
Operand data type date is invalid for subtract operator.
operand data type nvarchar is invalid for minus operator
Operand data type nvarchar is invalid for sum operator
Operand data type varchar is invalid for sum operator
Operand type clash: int is incompatible with date
Operand type clash: uniqueidentifier is incompatible with bigint
Operand type clash: uniqueidentifier is incompatible with int
Operating system error code 5(failed to retrieve text for this error. Reason: 15105)
Operator used tempdb to spill data during execution with spill level 1
Opposite of INNER JOIN
Optimize the query which use UNION ALL
Optimizing a FULL OUTER JOIN
Optimizing a very slow "delete" instruction
optional parameters in dynamic sql query
Order by (select 0) meaning
Order by A sort column can include an expression but the expression cannot resolve to a constant.
ORDER BY and TOP or FOR XML
Order By Causes Extremely slow performace
Order by clause in Table-valued functions doesn't work as expected
Order by datetime (datatype varchar)
ORDER BY list of RANGE window frame
Order columns in dynamic pivot
Order of Execution of SQL Queries
organization chart with recursive sql
OUTPUT Clause Syntax Error
Output File Cleanup reported: Unable to open Step output file.
Output results to text file using T-SQL
Output SQL Server Agent job step to a file
OUTPUT variable from dynamic query with openquery
Over/Partition By - Multiple Partitioning's?
Pad String to the Right with Spaces
Parameterized queries running much slower than ones with hardcoded values
Parameterized Views in SQL Server
Parameters were not supplied for the function 'sys.dm_exec_sql_text'.
Parition column for a unique index must be a subset of index key
Partition a table weekly on date column and create Clustered index on the Identity column
Partition by and where condition
Partition on UNIQUEIDENTIFIER Data Type
Partition Scheme Error, Invalid Object.
Partitioned View not updatable ???
Pass a list to a sql function/procedure
Pass ColumnName in User Defined Function
Pass in multiple dates with variable
Pass Null Parameter to Dynamic SQL query
Pass Parameter to Job which calls a SP with the Parameter provided?
Pass parameters to ssis package through agent job.
Passing a decimal to a stored procedure
Passing a integer variable in a dynamic query
Passing a parameter to a CmdExec step
Passing a stored procedure parameter to an xp_cmdshell - sqlcmd line
Passing a sub-query as a parameter to the Stored procedure
Passing an array of GUIDs to a stored procedure
passing array of guids into stored procedure
Passing Comma separated input to stored procedure in IN clause
Passing cursor as a parameter to the stored procedure in SQL Server
passing database name as sql parameter
Passing DatePart variable to DateAdd()
Passing input parameter with single quote in Stored Procedure
Passing JSON Data in Stored procedure parameter
Passing null values to parameters
Passing nulls and uniqueidentifier parameters to stored procedure from C#
Passing the float value to stored procedure
Passing variable in a path - SQL Query
Passing XML data from C# application to store procedure taking long time
Past midnight datediff
PATINDEX and Regular Expression
Pattern matching with multiple values
percentage difference between two numbers
Performance difference between view and stored procedure
Performance efficient function to strip punctuation marks
Performance issue with ISNULL function
Performance Issue with Pivot
Performance of GROUP BY vs. PARTITION BY
Performance of SQL PIVOT Query Against Large Tables
Performance problem with date range JOINs
Performance: delete rows VS update rows state
Permissions Enable Disable Trigger inside a store procedure
Permissions needed to use xp_cmdshell
permissions to query sys.sql_expression_dependencies
PIVOT and get unique values rather than aggregate
pivot error column specified multiple times
Pivot grouping columns must be comparable.
PIVOT Query Conversion For Varchar(40) to int or Decimal
Pivot query returns all NULLs?
Pivot Query With String value
pivot string concatenation
Pivot table with no numeric aggregation?
Pivot table: saving it after creation: insert into or select into
PIVOT versus UNION for de-flattening (normalizing?) some (but not other) columns of a flat table
Pivot with unknown number of column in SQL
Pivot with using a Subquery
Pivoting varchar columns
Plan Stability - KEEP PLAN vs KEEPFIXED PLAN
PLEASE HELP ME TO FETCH LAST 3Weeks data in SQL
Please help with Floating Point problem... An invalid floating point operation occurred.
PMT Calculation with T-SQL
PMT function in SQL Server using T-SQL
poor performance in using UNPIVOT
Possible to declare a variable within a View?
possible to do sp_executesql on table variable
Possible to SELECT non-aggregate columns with SUM without GROUP BY?
Possible to suppress (sub)procedure SELECT output?
powershell invoke-sqlcmd with a long parameter fails with is too long. Maximum length is 128.
PowerShell Script to Catch Empty Query Results
Powershell Script to run T-sql files and capture messages from ssms
PREEMPTIVE_OLEDBOPS when I run my update query having linked server hence need help in framing the update query
Prefix alias for columns in select query
Preserve row order of a text file when inserting into a table using bulk insert (20160906)
Preserve text formatting in sql
Prevent update in column if not Null (trigger)
preventing table lock in insert
Previous year Year To Date with partial current year Year To Date Calculation SQL Server
Primary key auto incrementing by 1000 instead of 1
Primary key incremented even when insert fails.
Primary Key on Calculated Column
Primary Keys - int's vs. varchar
print float value
Print Hex value as string without 0x
PRINT within WHILE loop is not being displayed...
Problem : Cannot resolve the collation conflict between ...
PROBLEM export SQL Server data to Text Files-utf 8 unicode--’…†‰€
Problem in resizing the varchar columns inside a table
Problem printing @@ROWCOUNT
problem returning decimal value from stored procedure
Problem saving column default value of NEWSEQUENTIALID()
Problem to call sp_executesql inside function
Problem trying to rename db attached to the SSMS.
problem while executing remote procedure with table-valued
Problem with Bulk Insert and Datetime Format
Problem with bulk insert from cvs using escape character '\;'
Problem with converting float to varchar
Problem with Linked Server
Problem with PATINDEX function for case-sensitive information
Problem with procedure, everything seems works but it does not update the field
Problem with STORE PROCEDURE, There is already an object named, "GetCustomersPageWise" in the database
Problem with Turkish 'i'
Problems while executing OPENROWSET 'Microsoft.ACE.OLEDB.12.0'
Problems with SP_TRACE_CREATE
Procedure expects parameter '@parameters' of type 'ntext/nchar/nvarchar'
Procedure expects parameter '@statement' of type 'ntext/nchar/nvarchar'."
Produce DISTINCT values in STRING_AGG
Programmatically Write Results to CSV
progress bar in sql
Proper Case String
proper way to stop dbcc shrinkfile?
Property text is not available for DefaultConstraint. This property nay not exist for this object, or may not be retrievable due to insufficient access rights
pros and cons for WITH (NOLOCK).
Pros and Cons of Snapshot Isolation level
Pros and Cons of Temp Table Over CTE and Table Variable in Reoprt Development
provider: TCP Provider, error: 0 - No connection could be made because the target machine actively refused it.
Pull the Groups and Members from Active Directory (AD) Using T-SQL
Put NOLOCK into VIEW
Querey to find connections on SQL Server and history of connections
Queries from multiple databases on the same server
Query a NVARCHAR(MAX) column in the SELECT statement
Query a Table with Japanese Characters returns always 0 results
query AD from sql using linked server-not returning all records
Query AD With No Linked Server
query completed with errors ?
Query error when run in SQLCMD mode
query for checking if a last run of a job succeeded or failed
Query for Copying all objects from one schema to another schema
query for enable CDC on all tables in SQL server ?
Query for expired password for Active directory user account?
Query for Historical Locks, Blocks, or Deadlocks
Query from SQL to AS400 0206 and 0420 errors
Query need to Delete rows older than 2 months
Query performance unions vs temp tables
Query Performance using OPENQUERY with LInked Server Joined to local table
Query plan shows clustered index scan - need to add index? why did it not just do a table scan?
Query processor could not produce a query plan
Query processor could not produce a query plan because of the hints defined in this query. Resubmit the query without specifying any hints and without using SET FORCEPLAN.
Query question with Substring by tilt character ('~')
Query the registry
Query timeout expired
Query to Check DatabaseMailUserRole Permission To A Login
query to convert exponential to number
query to convert percentage value to number
Query to count ACTIVE records for each month
Query to determine overlapping date ranges (by category)
Query to dynmaically pass the last 36 months date to loop
Query to extract multiple words from a string(Varchar)
Query to extract non english characters
Query to find First sunday of march and Second Sunday of November in SQL 2008
Query to find Last Business Day Previous Month Date Key
Query to find long running transaction and high memory consumed process
query to find most frequently used objects (tables, indexes, etc)
query to find the list of tables with clustered index
Query to find the user mapping for a specific login
Query to find unique record , those that are not duplicated even once.
Query to get list of jobs running during specified time
Query to get salary range count by Department
Query to List All Logins (SQL Server login and Windows Login) and Last Password Change Date
Query to remove decimal from a number and introduce commas ??
Query to select values from table 1 where column1, column2 is in Table2(col1, col2)
querying a global temp table on another server
Querying a linked server having a LIKE operator
Querying for Database Names that Contain Spaces
Querying on a dynamic column name in a stored procedure - SQL Server 2005
Question: IF statement in Scalar Function
Questions mark instead of data
Quick easy way to see if data in sql server has changed
Quick key shortcut to apply comma
Quick key shortcut to apply single quotes?
RAISEERROR to stop execution
Raiserror behavior in TRY-CATCH block
Rank Over Partition - Ignoring null columns in the partition
RANK without counting null values
Rank() and using WHERE clause on results
Re-name SQL Server Database Physical .mdf and .ldf files
RE: Query Output messages being displayed in Messages tab versus Results tab
Read Excel file using TSQL
Read file from Network Drive
Read unicode character using OPENROWSET
Reading @@ROWCOUNT after a Merge statement execution - SQL Server 2016
real story on join precedence
Rebuild Index MaintenancePlan [SQLSTATE 01000] (Message 2528)
Recent executed queries for a specific database
Record Count on MERGE Statement on Insert,Update,Delete
Record creation date without a column for it
Recover unsaved queries older than a month
Recovering a deleted view. How?
Recursive CTE (In Reverse)
Recursive CTE for Start and End date upto last 12 Months only using getdate() --2qsns
Recursive query without using CTE
Reference Created Column Name in Select Statement
Referencing a case stement in another case statement
RegEx in TSQL - replace non-alphanumeric characters etc
Relationships AdventureWorks database
Remote function reference ' is not allowed, and the column name 'hvme' could not be found or is ambiguous.
Remote function reference is not allowed
Remote table-valued function calls are not allowed.
Remove ----,----,-------,---- from the csv file
Remove 0x from binary values using t-sql
Remove all characters before "\"
Remove all leading Zeros
Remove Blank Rows from SQL server Table
Remove Characters from a Date
Remove Comma from SQL String
Remove DATE from datetime SQL 2005
remove double quotes on bulk insert
Remove HTML tags from a field without using a function
Remove last Comma from the string
Remove Null or blank in STUFF sql
Remove seconds from datetime
remove space in columns on bcp out
Remove Spaces in columns in sql table
Remove spaces in middle of a string
Remove Unicode characters from Sql Server Table
removing a leading character from a comma separated list
Removing decimal places
Removing hidden CRLF only from end of text string
Removing seconds and milliseconds from datetime
removing white space from a SQL database using query.
Rename column with spaces in script (SQL Server 2016)
rename multiple tables in database
Renaming Pivot table column names dynamically
Reordering rows in a table
Repalce type Ntext is invalid for argument not working
Repeat row number for a group and increment row number when a specific column in the group changes.
Repeat rows in a query
Replace cursor using CTE in SQL Server
Replace First three character T SQL Query
Replace hex A0 wih space
Replace HOUR in DATETIME field.
replace if more than 1 space between words in a string
Replace invalid XML characters using SQL query
Replace Invisible Specuial characters issue in function
Replace NULL with a Blank space
REPLACE statement removing commas from a money convert... I do NOT want it to do this
Replacing numbers from a string
replacing self closing tag
Replacing XML Character in all the columns in a table
Require Query to Retrive data of Count of Applied leaves by Month wise in Horizontal way
reseed identity to 1, identity is reset again to max current column value in couple second
reseeding temporary tables or table data types with identity column
Reset RowNumber ONLY if previous value is changed in the group.
resetting identity column value back to 1
Resetting IDENTITY Seed in Table Variable
Restore Database .ndf files
Restore database failed with the operating system error 2 (failed to retrieve text for this error. Reason: 15105)
Restore Database from C# Application
Restore Database gives an error: Cannot open backup device
Restricted data type attribute violation
Results pane is disappearing in SQL Server 2008
retain old value while update data in sql
Retrieve all the filename present in one particular location in SQL
Retrieve GUID or SID FROM Active Directory via ADSI and T-SQL only?
Retrieve last 12 months data
Retrieve month name and last 2 digit of yr from date column
Retrieve the next auto-increment number
Retrieving a 2 digit month
Retrieving MAC address from NET_ADDRESS in master.dbo.sysprocesses returns different values for the same computer
Return a datatable from stored procedure asp.net
Return all records in 15 min intervals.
Return an Empty Value From a CASE Statement
Return NULL if no value is found on sql select statment
Return NULL values with INNER JOIN for INDEXED VIEWS
Return only numeric characters from a string column
Return Value from SQL Query if there is no data
Returnig BLOB(varchar(max), varbinary(max) ) from linked server
Returning multiple rows based on a date range in a single row
Returning 0 when no records exist in a sql query
Revert back of altered Stored Procedures or deleted records
Right Justify Money Column With Query To Grid.
Rollback Delete
round up or down to nearest dollar
Rounding Down Time to the 30 minutes
Rounding float issue
Rounding number with ending equals 5
Rounding the time from (DATEDIFF(n,minPour,maxPour))
Rounding Time to nearest Hour!!
Row comparison using TSQL
Row failed to retrieve on last operation
Row terminator for BULK INSERT
ROW_NUMBER and LEFT JOIN
ROW_NUMBER data type
ROW_NUMBER for a computed column
row_number vs max performance wise
Row_Number() And CTE
ROW_NUMBER() and MAX per PARTITION?
Row_Number() decreasing the performance of the query
ROW_NUMBER() How to Restart 'Counter' when same group is reached?
row_number() is not working properly
ROW_NUMBER() is very slow with a table that has a million records
ROW_NUMBER() OVER (ORDER BY ) is very slow with large dataset
Rowcount returns zero
Rowset does not support fetching backward.
Rowsize exceeds 8060 bytes
RowVersion/Timestamp to string
RTRIM/LTRIM is not working on a set of data
Run An Analysis Services Command(xlma) in T-SQL stored procedure
Run inline stored procedure
Run Query in ALL Database
Run Same SQL on multiple tables
Run Store procedure in multi threading
Run Stored Procedure From Trigger
Run Stored Procedure through Batch Files [CMD]
Running multiple SQL script files as a single batch
Running multiple update statements parallel on a single table
Running PL/SQL Syntax on Microsoft SQL Server 2008
Same Query in same database/server taking different execution time for different persons - please help!
Same query returns different result
Same Query, Different execution time on two environments
Sample query for a loop syntax to delete rows from multiple tables in a database
Save output messages to text file?
Save temp table to permanent table
Saving reports to csv with creation date in file name
scale greater than precision - not a valid instance of data type real
Scan count VS logical Reads
Schedule Script to Run without Job Agent
schema changes history by T-SQL
SCOPE_IDENTITY() returns null after paramerized INSERT
Script to simulate long running transaction
Script failed for StoredProcedure '????'. (Microsoft.SqlServer.Smo)
SCRIPT for Foreign Keys DROP and RE-CREATE for use with TRUNCATE
script out many stored procedures at once?
Script to create TSQL2012 sample database from book "Training kit (70-461) Querying Microsoft SQL server 2012" by Itzia-ben-Gan
script to disable multiple sql logins except for server logins
Script to find the list of Queries currently running in database with User Login Name and Host Name.
script to iterate to each database
Search a string accross multiple tables
Searching a whole database to find a single value in a unknown table
Searching partial and or full word from full-text search those might be precise or fuzzy (less precise) OR matching the meaning should return correct results
Select (and commit) 1000 rows at a time from/into a large temp table
SELECT * INTO #X FROM (SELECT * FROM TABLENAME)----AND ANOTHER NESTED SUBQUERY?
Select * into From One Server to Another
SELECT * to select only non empty columns
SELECT <values> FROM table WHERE specific column value = "active"
Select 1/0 does not show error when put in Exists
SELECT all characters/words after a specific word
Select All Rooms Available for Given Date Range
Select and convert all fields into string type
Select column by ordinal position
Select column value for last 5 working days
SELECT DATEADD (MM, DATEDIFF(MM,-1, GETDATE()),0) -1 AS [LastDayOfMonth]
Select datetime less then 10 minutes compare with now
SELECT DISTINCT - Ignore Specific Columns
SELECT DISTINCT Max(Date)
Select Distinct Month-Year Combinations?
Select distinct with ntext fields
SELECT failed because the following SET options have incorrect settin
Select from EXEC?
SELECT FROM View Takes Too Long
select into casting not null question
select into new table with today's date?
select last digit in sqlserver and check it ?
SELECT matching records from 2 tables
Select MAX value Then add 1 to it
SELECT MIN() does not select negative value
SELECT Month(getdate -1) -- in january -- do you get 12 ?
Select multiple columns from table but Group By one column
select only min and max rows for each group?
SELECT only numeric part of string
Select Query for 3rd decimal value graterthan zero.
Select query returns 0 for calculating percentage using division operator
Select query with Like matching exact word only?
Select query with multiple row coalesce subquery
SELECT query, 2 SUM functions with different conditions
Select records from the last hour
Select records greater than or equal to current date
Select Statement - just want the value, not the header
SELECT STRING AFTER A SPECIFIC CHARACTER
Select String after Character
SELECT string between comma
Select the last value from a comma separated value string in SQL
Select the numbers between two numbers
select the record with the lowest datediff()
SELECT TOP 1 in subquery
Select Top 10 Percent and 20 Percent
select top 100 to 200 records in sql server
SELECT TOP 50 with ORDER BY DESC Is much slower than writing it with ORDER BY ASC
Select values from temp table
Select with FOR SYSTEM_TIME ALL clause from a View
selecting a value of one column based on the max value of another in a subquery
Selecting last 52 weeks of data
Selecting records 1000-2000 out of a sql database
selecting records from one table excluding IDs from another table
Selecting the substring of a distinguished name
Selecting the timezone using the Zip code.
Selecting Unique Combinations of multiple row values
Semi-Colons in Stored Procedures
Send an email when the count is greater than 1
Send HTML as attachment in email in Stored Procedure
Send records from multiple tables to email using sp_Send_dbmail in table format.
Sending an image in E-mail as embedded image
Sending mails to mutliple recipients in sql server
Sending remote attachments using sp_send_dbmail as non-admin user
Seperate First and Second word from string into columns
Sequences and Merge-statement
Sequential Execution of Stored Procedure
Seriously performance issues on cross join
server can t find SP sp_MSforeachDB
serverproperty('ComputerNamePhysicalNetBIOS') equivalent in 2000
Set a flag if certain columns contain a value
Set A SQL Server Field to A DropDown?
Set a variable to current date/time
Set a variable using a CASE expression (inside a SELECT statement)
Set datatype of column within SELECT INTO query?
SET DATEFIRST to work for a view
SET DATEFORMAT within a stored procedure
Set Default Value for DATETIME COLUMN
Set Hours, Minute, Second and Millisecond Part to Zero in SQL
Set identity_insert on for multiple tables
Set multiple variables to one sql statement
SET options have incorrect settings: 'ANSI_NULLS, QUOTED_IDENTIFIER'
Set priority on t-sql statement
Set string value in where condition with variable using Dynamic SQL
Set Table Collation Using SELECT INTO
Set table column value as mandatory
set the result of execute() into a variable ?
Setting a database to single user isn't always working
setting current schema in SQL server
Setting date format for the entire SQL Server installation - SQL Server 2008 R2-2012
Setting time to zero in a datetime object
Sha256 Encryption possible in SQL?
shell script file call to Sql server procedure/function
shift decimal left to 2 positions.
should we specify collation while making #temp table.
Show Field types of a CTE
Show null value after using unpivot
Show/Hide columns based on criteria
Shrink Database while user accessing it
Shrinking a 4 tb DB with 2.8 tb free space
Similar to Initcap in SQL server T-SQL
Simple "WHERE x IS NOT NULL" query takes forever
Simple query on a table just hangs ...
simple stored procedure return null when data expected
single inverted comma insertion problem
Skip duplicate keys when inserting rows
skip row if error occurs and move to next row
skipping header in bcp
Skipping Rows and Columns With BULK INSERT
SLA Calculation Help needed in Excluding Weekends and Off business hours for calculation
Slow deleting from Temp Table
slow insert into temp table
Slow performance of sys.dm_db_index_physical_stats()
Slow query after removing 50% of table data
Slowly changing dimension type 2 using T-SQL ( NOT MERGE)
Some guidlines for posting questions...
Some records not updated during UPDATE command
SOME/ANY vs EXISTS
Sort Order with Special Characters
Sp help doubles the lenght of nchar and nvarchar...why?
sp to send email with csv
sp_add_job - adding jobs with TSQL
SP_EXECUTESQL / @@ROWCOUNT
sp_executesql extremely slow
sp_HelpText ==> "There is no text for object"
sp_helptext Equivalent for Tables?
sp_helptext format issue
sp_OACreate has not yet been called successfully for this command batch.
sp_OAMethod - ADODB.Stream - Write to file failed.
sp_OAMethod return/error code - unable to find out what it is!!
sp_OAMethod Send FAILED!
sp_rename - suppress warning message
sp_rename failure for renaming default constraints
sp_send_dbmail - attachment folder permissions
sp_send_dbmail - how to insert date into subject line of email
SP_SEND_DBMAIL error
sp_send_dbmail looses NEWLINE-s
sp_send_dbmail return codes?
sp_send_dbmail to include hyperlink
sp_who2 does not return all connections in a contained database
sp_xp_cmdshell_proxy_account returns error code 5
Special character ( < , > ) in XML Path (' ')
Special permission on Db_datareader user for execute sp_helptext
Specify code page in a SQL Query
Split data at particular character using t-sql
Split date range into months
Split datetime records with 5 minute intervals
Split IP address into four parts
Split name into first name last name and middle name(where exist)
Split one stored procedure to two stored procedures
Split row to multiple rows based on dates overlapping (SQL split dates)
Split string (with variable number of value) into different columns
SQL - Implicit conversion from datatype 'VARCHAR' to 'INT' is not allowed
SQL to split the string based on the space (Example -Split the first_name alone from the complete name , Name 'Pete Mahadevan Sankaran' should give result as 'Pete')
SQL - Drop table if exists
SQL - Group By with text?
SQL : Date Query for Next year
SQL : How can we keep the trailing zeros while inserting into a table with varchar field.
SQL : Query to Replace null with NEXT non-null values
SQL : UPDATE failed because the following SET options have incorrect settings: 'QUOTED_IDENTIFIER' error.
SQL 2005 LDAP Query Error: Msg 7321, Level 16
SQL 2008 R2: How to determine index create date?
SQL 2008 Restore Encryption database - Create Certificate invalid private key errror
SQL 2014 - Update varbinary column to string value
SQL 2016 - PRIMARY KEY VIOLATION IN IDENTITY COLUMN
SQL bulk insert a single row from a text file
SQL Bulk insertion error
SQL Case wih Multiple Return Values
SQL Code to remove special characters
SQL Collation chnage
sql convert vertical table to horizontal (deep to wide)
sql converting julian date to calender date
SQL COUNT data by date, and then COUNT by date range
SQL database export to CSV with automated
sql datetime difference between two columns decimal
SQL Error - Column names in each table must be unique. Column name 'w' in table 'Table_1' is specified more than once.
SQL ERROR : 7346
SQL Error (Msg 6506, Level 16, State 10, Line 11 Could not find method 'STDISTANCE' for type 'Microsoft.SqlServer.Types.SqlGeography' in assembly 'Microsoft.SqlServer.Types')
SQL Error Message: Executing SQL; no cursor
Sql Error:Operand type clash: date is incompatible with int
SQL from another server underlined in red but works, can I remove the red underlines?
SQL Function for calculating IP Address
SQL Function to read varbinary word doc file and generate
SQL Fuzzy match (matching names not exact)
sql incorrect syntax near '<'
SQL Job failing with error [SQLSTATE 01000] Message ID 3621
SQL Job Fails Because of Invalid Object Name
SQL Job failure:Unable to determine if the owner (domain\user) of job ...
SQL Join - Convert char to Int
SQL Loop through multiple tables
SQL mail sp_send_dbmail include images from query into HTML table rows
SQL Merge - only update when specific column has changed?
SQL Not Equal clause ignores NULL value
SQL parameter value inside of brackets issue
SQL Pivot with Grand Total Row
SQL Programming, check if multiple values exist in database
SQL Queries for TFS
sql query for last 15 minutes updated or inserted records in a table
SQL Query for estimate number of the transactions per day
SQL Query for five-digit data
SQL Query for last week / previous week data
SQL QUERY FOR MAX SALES AND MIN SALES FOR EVERY YEAR WITH DATE
SQL query for Office First IN and Last OUT timing calculation
SQL Query for Phone Numbers
SQL Query How to Extract only text that has no Number associated with and Number with text or Text with Number
Sql query issue while connverting from oracle to SQL syntax
sql query permutations without repetition
SQL Query throwing Warning: The join order has been enforced because a local join hint is used.
SQL Query to add previous month amount to current month amount
SQL query to convert date from DD/MM/YYYY to YYYY-MM-DD
Sql Query to count numbers of consecutive dates.
SQL Query to create a Time Dimension at 15 mins granuality
sql query to find decimal
sql query to find exact matches
SQL QUERY TO FIND RECORDS BETWEEN AM AND PM
SQL Query to find sheet names in a excel file
sql query to find tables used in sql jobs
Sql Query to Find the Maximum occurance field on a column
SQL query to generate number with multiple of fixed numbers
SQL query to get last 10 records in the table?
Sql query to get next working day
SQL query to get the Datetime 06 hours prior to the table Datetime value
SQL query to group and create custom column
sql query to Load only new records,or update old records
sql Query to replace the square bracket and the whole text inside with a single charecter
SQL query to return the second word in a string
SQL query to sum values of previous rows
sql query which will create a text file on my system to export table data from sql server
SQL Query With Cross Apply Slow performance
SQL Query without using where clause
SQL remove Invalid Characters
SQL replace bullet points
SQL replace with a comma separated list
SQL Says 23:59:59:999 = 00:00:00:000
SQL Script to findout How much percentage databse restoration completed ??
SQL SELECT * FROM OPENROWSET with Variable
SQL select into variables
sql select statement to find percentage
sql server - delete query with union
SQL server - how to find Hexadecimal character in a table
SQL Server - Searching AD. Capture all AD Groups for All Logins
SQL Server - Transactions per second
SQL Server : Get middle initial only from the middle name.
SQL Server ( Output without Column name )
SQL Server 2005 Express: Weird error message running SELECT COUNT query
SQL Server 2008 multiple lines in a varchar(MAX) column?
Sql Server 2008 R2 keeps disconnecting after a few minutes -- how can I prevent this?
SQL Server 2008, what is the difference between (for/after) definition for trigger?
Sql Server 2012 Backup failed
SQL Server 2012 Row_Number Over Partition By Multiple Columns
SQL Server 2012 takes long time on simple alter to add NULL columns
SQL Server 2014 misleading error messages
SQL Server 2016 - Inserting a NULL field into a table with a foreign key constraint
Sql server 2016 storing foreign language data
SQL Server 2017 does not output CHAR(10) and CHAR(13)
SQL Server Agent 2016 is occupying high memory consumption.
Sql Server agent job stop Job after some time
Sql Server Agent last run duration in minutes
SQL Server backup to Googledrive
SQL Server blocked access to STATEMENT 'OpenRowset/OpenDatasource' of component 'Ad Hoc Distributed Queries' because this component is turned off as part of the security configuration
SQL Server cobian backup
SQL SERVER COLLATION TO SUPPORT CHINESE AND KOREAN LANGUAGE ALONG WITH ENGLISH
sql server database collation
SQL Server DELETE massively inflates transaction log
SQL server Equivalent to v$session in Oracle
SQL Server Error - HRESULT E_FAIL has been returned from a call to a COM component
SQL SERVER error 80040e57
sql server function to convert 2 digit year to 4 digit year
SQL Server has been using a process ID of 1968
SQL server is giving wrong result when rounding applies after type conversion in some cases
SQL Server LDAP QUERY to Active Directory : Search in the active directory where a user is located in a group
SQL Server management studio is not showing the entire data
SQL Server Query from Active Directory.
SQL server regex Expression to strip off all non-numeric characters
SQL Server returning -1 rows affected when Stored Procedure is ran
SQL Server Standard vs. Enterprise
SQL server throwing error for XML declaration
SQL Server try-catch inner exception message conundrum
SQL Server Unicode Characters in a column
SQL Server Varchar(Max) chopping off the data, help
SQL Server while loop on multiple conditions
SQL server: store procedure vs. SQL script template
SQL Server: What does mean database hit
SQL split string and create Abbreviation
SQL State: 37000 Native Error: 102 Incorrect Syntax near
SQL Statement for requesting date 60 days from date.today
SQL Statement Ignore Cascade Delete
SQL Statement to select one record.
SQL Subquery - Concatenate Results
SQL table column won't update
SQL table will not drop
SQL to convert decimal to varchar. Need to be separated by commas also
Sql to get military time
SQL to show average with decimal places
SQL Union Statement does not work as expected
SQL Union with empty columns
SQL version 661 and 665
sql view running slow
SQL Vs Oracle for Round different value why?
SQL_Latin1_General_CP1_CI_AS collation
SQL_Latin1_General_CP850_CI_AI vs. Latin1_General_CP850_CI_AI
SQL- Query to find maximum number of concurrent sessions
SQL: Generate random string values Alpha Numeric ONLY
SQL: How to extract table names from a SQL query in a column
Sql: need to return a row count but reset it at a change in value
SqlBulkCopy - Received an invalid column length from the bcp client ... ???
sqlcmd error - HResult 0xFFFFFFFF, Level 16, State 1
SQLCMD Invalid filename error
SQLCMD issues
sqlcmd parameter without header
SQLServer 2008 R2: The SCHEMA LOCK permission was denied on the object
SQLServer 2012 BCP Error: "Warning: BCP Import with a format file will convert empty strings in delimited columns to NULL"
SQLSERVER 2012 How to store old value before update and new values after update?
sqlstate 42S02 (error 208). Data Failed to retrieved from database.
SSMS - Index build suggestion/recommendation
SSMS 2008: BULK INSERT dbo.Project - Incorrect syntax near 'ROWTERMINATOR'. Why?
SSMS Ctrl+H Replace using Regular Expressions - how to replace NewLine, Carriage Return?
SSMS query causing "There is not enough space on the disk" error.
SSPI handshake failed with error code 0x8009030c.[CLIENT: <named pipe>].
SSRS phone number format
Standardized Street Address Using T-SQL
Start SQL job if not already running
StartService() returned error 5, 'Access is denied.' - xp_servicecontrol
STATISTICS_NORECOMPUTE = OFF in Rebuild Index Task
Step 1 of job is being queued with T-SQL subsystem
Steps to alter function used as computed column
Store output of SQL Server EXEC into a table
Stored procedure doesn't return the return value
Stored Procedure Executes, no row inserted!
Stored Procedure for SQL table update from flat file, use BULK INSERT
Stored Procedure for updating dynamic columns in a table
stored procedure header
Stored procedure not showing under list
Stored procedure output to a text file
Stored procedure scope: using sp from another database
Stored procedure sending duplicate emails to all recipients
Stored procedure slower than running query in sql server management studio
Stored Procedure to call .exe without xp_cmdshell
Stored Procedure to Print @@rowCount and Rollback on @@error
Stored Procedure- Multil level employee hierarchy in the same row
Stored Procedure, Optional Parameter + OUTPUT Parameter?
Storing value startign with 0 in bigint column
Stratified sampling
string comparison percentage
string or binary data would be truncated even when theres no records more than destination scheme size
String or binary data would be truncated - NVARCHAR(max) LIKE clause
STRING_AGG WITHIN GROUP syntax error
STRING_AGG() without ordering
string_split - Delimiter with multiple characters
STRING_SPLIT is not a recognized built-in function name
subquery returned more than 1 value on an insert into
Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
Subquery to get most recent record in one-many relationship (a better way?)
Subquery with union all
substitute for STRING_AGG in SQL 2016
substring before 2nd or 3rd occurance of character
SUBSTRING equivalent for a number/integer?
SUBSTRING START INDEX IS IT ZERO BASED
Substring with NVARCHAR
subtract negative number given positive number
Subtracting hours from DateTime
Subtracting minutes from a DateTime field
Sum a DATETIME field
Sum ans Count in one Pivot
Sum doubling the value..
Sum function with group by in outer Apply
Sum HH:MM:SS in Sql Server
Sum of a column with NULL values
SUM of all calculated columms on a joined child table
SUM returning too many decimal places
SUM(ISNULL(Total,0)) does not return 0
Super high performance SELECT last N records
suppressing messages in SSMS?
Syntax Error for Output clause with DELETE using JOIN
Syntax error in 'IDENTITY'
syntax error in CONSTRAINT clause?
Syntax to drop constraint if exists
sys.fn_varbintohexstr vs clr function.
sys.sysprocesses query cross join to sys.dm_exec_sql_text
System.ArgumentNullException: String reference not set to an instance of a String. Parameter name: s System.ArgumentNullException: at System.Text.Encoding.GetBytes(String s)
System.Data.SqlClient.SqlException: 'Could not find stored procedure 'False'.'
T SQL - Convert unicode Characters to be displayed in ASCII format
t sql to get max length of all nvarchars in a database
T-SQL [ON PRIMARY]
T-SQL CASE statement.. NOT in a SELECT query - ??
T-SQL Coding Standard: Pascal or camelCase for column names?
T-sql conditional where clause using case statement with parameter
T-SQL CREATE FUNCTION AS EXTERNAL NAME
T-SQL Equivalent For Group_Concat() Function
T-SQL Equivalent of VB.Net AndAlso and OrElse operators
T-SQL error: Adding a value to a 'smalldatetime' column caused overflow. SQL server bug?
T-SQL First Tuesday in a Month
t-sql for sql logins
T-SQL get substring after slash (\) character?
T-SQL HOW TO CONVERT HRS,MINUTES,SECONDS AMD MILLISECONDS INTO DAYS
t-sql OUTPUT clause vs. scope_Identity()
t-sql question how to order by length
T-SQL remove leading zeroes in a string
T-SQL Replace at End of String
T-SQL script to add columns dynamically to sql table
T-SQL Script to find the backup job details
T-SQL Stored Procedure: Calculating GPA based on a students ID
T-SQL to convert Datetime and DatetimeOffset to Zulu Format
T-SQL Where 1=1 and Where 1 = 0 , what is the puprose of this statement ?
T-SQL: Cursor is not advancing to next record
T-SQL: Performance Issues with View; runs slow
T-SQL: Using CASE Statement in WHERE Clause (Multiple conditions)
T-SQL: reformatting date from US to European
T'SQL Code for finding the SPID of running jobs (Sql 2000,2005)
Table UPDATE : getting this error The multi-part identifier could not be bound
Table updated while reading? Locking in SQL Server
Table Valued Function vs. View Performance
table variable in trigger
table variable in view
Table with 789.6 million records taking 5 minutes to return records by querying against 28.2 million records
Table-valued function run once for each row in a table variable.
Taking the results from two queries and dividing the output to receive a percentage
Temp Table in view
Temp Table with an index - How to delete the index?
TEMPDB running out of space
Temporal Table Errors in DACPAC Deployment
Text data type problem
The active result for the query contains no fields
The ALTER TABLE statement conflicted with the FOREIGN KEY constraint "FK_BookingHistory_BookingRef"
The awful SELECT COUNT(*)
The best book to learn T-sql
The client connection security context could not be impersonated. Attaching files require an integrated client login???
The conversion of a varchar data type to a datetime data type resulted in an out-of-range value.
The conversion of the nvarchar value ' 2012 ' overflowed an INT1 column. Use a larger integer column
The conversion of the nvarchar value '3001822585' overflowed an int column. Maximum integer value exceeded.
The conversion of the nvarchar value '4598554672' overflowed an int column
The current transaction cannot be committed and cannot be rolled back to a savepoint
The current transaction cannot be committed and cannot support operations that write to the log file. Roll back the transaction.
The data type of the datetime argument is invalid for argument 1 of the substring function. in SQL
The data types ntext and varchar are incompatible in the add operator.
The data types nvarchar and varchar are incompatible in the '&' operator.
The data types varchar and bit are incompatible in the add operator
The data types varchar and date are incompatible in the add operator
The data types varchar and image are incompatible in the equal to operator
The data types varchar and varchar are incompatible in the subtract operator
The database is in single-user mode
The database owner SID recorded in the master database differs from the database owner SID recorded in database 'DB'?
The Difference Between OPTION(LOOP JOIN) and FROM [Table] INNER LOOP JOIN [Table]?
The EXECUTE permission was denied on the object 'functionName', database 'db_name', schema 'dbo'.
The fractional part of the provided time value overflows the scale of the corresponding SQL Server parameter or column. Increase bScale in DBPARAMBINDINFO or column scale to correct this error
The incoming tabular data stream (TDS) remote procedure call (RPC) protocol stream is incorrect
The insert column list used in the MERGE statement cannot contain multi-part identifiers. Use single part identifiers instead.
The ltrim function requires 1 argument(s)
The mail could not be sent to the recipients because of the mail server failure.
The maximum size of ntext?
The mechanics of the WHERE clause
The metadata could not be determined because the statement
The multi-part identifier "alias.field" could not be bound???
The multi-part identifier "inserted.id" could not be bound
The ORDER BY clause is invalid in views, inline functions, derived tables, subqueries, and common table expressions
The PERCENTILE_CONT function is not allowed in the current compatibility mode.
The problem of xp_cmdshell_proxy_account
The Query in SQL Server 2019 is Very Slow
The query processor could not produce a query plan because a worktable is required, and its minimum row size exceeds the maximum allowable of 8060 bytes.
The query processor ran out of stack space during query optimization. Please simplify the query
The replace function requires 3 argument(s).
The ROLLBACK TRANSACTION request has no corresponding BEGIN TRANSACTION
the select permission was denied on the object 'sysjobs', database 'msdb', schema 'dbo'
The substring function requires 3 argument(s).
the sum of two columns with null values
The table-valued parameter is READONLY and cannot be modified
The target is not in the current database
The text data type cannot be selected as DISTINCT because it is not comparable.
The transaction associated with the current connection has completed but has not been disposed. The transaction must be disposed before the connection can be used to execute SQL statements.
The transaction log for database 'mydatabase' is full. To find out why space in the log cannot be reused, see the log_reuse_wait
The type of column " COLUMNNAME " conflicts with the type of other columns specified in the UNPIVOT list.
There are fewer columns in the INSERT statement than values specified in the VALUES clause. The number of values in the VALUES clause must match the number of columns specified in the INSERT statement.
There is already an object named '#Temp' in the database
There is already an object named '#test1' in the database, why?
There is any way to disable And Enable all the foreign keys of a database SQL server 2005.
There is insufficient result space to convert a money value to smallmoney.
This BACKUP or RESTORE command is not supported on a database mirror or secondary replica ?
This exceeds the maximum allowable table row size, 8060 - SQL 2008?
THROW is replacing RAISERROR, but what is alternative to RAISERROR('Send info to the client', 1, 1)
Throwing exception in Stored proc to catch in C# and rollback the transaction
Tick marks in Sql Statements
Time bucket in 30 minutes interval
Time Delay in a Cursor?
Timeout expired on Index Creation
Timeout when executing MERGE-statement in SQL Server 2016 in simple recovery model
TinyInt vs Char(1) preformance for a status like column
Tips for converting Excel Formula to SQL Server Expressions
To access a shared folder providing user name and password
To get the 8 digit NUMERICAL ID value from string column without any other special characters and alphabets(?,^,AA...)
To Pull First order and last order for all the customers from order table.
To update the value of a column having identity increment on
TO_CHAR equvilent
To_Char Function Exists in any of MSSQL Versions? {Urgent}
Today's date in where clause
Top 10 CPU, Disk IO, Memory consuming queries
Total cost of a stored procedure
transaction log drive full
Transaction log is not truncated even after log backup
Transactions and tracking with in while loop
transport-level error has occurred when receiving results from the server. (provider: TCP Provider, error: 0 - The specified network name is no longer available.
Transpose Single Row to single Column
Trigger - Table - Pre insert to check duplicate values
Trigger - Get values from updated
Trigger - The current transaction cannot be committed and cannot support operations that write to the log file. Roll back the transaction.
trigger - to capture data into history table
TRIGGER - TRY/CATCH - HOW TO IGNORE ERROR
Trigger AFTER UPDATE can I get the ID of this row?
Trigger Error, but please do the insert
Trigger on Restore
Trigger only after commit
trigger problem inserting null values??
Trigger returning 'The partner transaction manager has disabled its support for remote/network transactions.'
Trigger to insert a record only if there is a change in any value.
Trigger to update another database table based on table changes
Trigger with error handling
TRIGGERS :Cannot use text, ntext, or image columns in the 'inserted' and 'deleted' tables.
Triggers on system tables ?
Trim during inserts
Trim leading Zero
Trim leading zeros
Trim the data after space in a string
Triple single quote
Trouble w/ using SWITCH statement w/ partitions
Trouble with Create Schema statement
Truncate a Table from Linked Server
Truncate datetime to cut off minutes and seconds
Truncate in Stored Procedure
Truncate or dropping table take forever
truncate table not good idea for production
Truncate table statement is very slow
Truncate Table Taking too Long a Time
Truncating Table which has reference on Index View, How?
TRY CATCH exit Statements in CATCH
Try/Catch Finally block?
Trying to Import Excel Data from query
Trying to Load Data from Excel into SQL Server. 32-bit Excel and 64-bit SQL Server.
Trying to print text followed by INT variable output fails
Trying to Use COALESCE/ISNULL with CAST in Select Statement
TSQL date convert "MMM/yyyy" format
TSQL - Performance Issue with NVARCHAR(MAX) column
TSQL - Using ALTER TABLE - ALTER COLUMN to modify column type / Set Identity Column
TSQL Date Greater than or equal to today less 5 days
TSQL Exercises using AdventureWorks
TSQL how to convert/cast varbinary to datetime? (SQL 2005)
TSQL Merge - Multiple statements after THEN
TSQL NOT ISNULL(A,0)
Tsql Query to read data between brackets
TSQL Row number with case condition
TSQL to convert DDMMYYHHMMSS into datetime format
TSQL to Convert seconds into minutes and round up to next integer
tsql to parse/separate/split a decimal (float) column into two Int columns - whole number in one column and decimal part (as int) in another column?
TURN off Identity insert OFF for all tables
Turning off logging for table in SQL server
TVP Performance with high volume...
Two strings compare equal using '=' but fail in 'like' compare
Two Table in Select * FROM Table1,table2
txt file to sql table type using OPENROWSET "BULK"
Type conversion in expression - Warning
Types don't match between the anchor and the recursive part in column "StartDate" of recursive query "CTE".
Types of date format in Sql Server
UNABLE to ADD or DROP a Constraint - SQL Complains!
Unable to create index 'PK_Task' duplicate key was found for the object name 'dbo.Task' and the index name 'PK_Task'
Unable to drop temp tables
Unable to open BCP host data-file Error
Unable to open the physical file Operating system error 2
Unable to Query an External table using polybase.
Unable to retrieve data from a linked MySQL Server
Unable to Shrink database or Log File
unable to switch the encoding error when working with XML in SQL Server
Unable to update the datetime column
Uncommittable transaction is detected at the end of the batch. The transaction is rolled back.
Understanding db_securityadmin role
Undo a SQL Server update statement?
Unescaping Strings in T-SQL
Unexpected sort order when column values contain dash
Unicode support for Indian rupee symbol in sql server 2008 R2
Union All and CTE doesn't works.
UNION ALL and Group BY query
Union All issue over two databases
- [
UNION ALL producing error Conversion failed when converting the varchar value '
0' to data type int.](/archive/msdn-technet-forums/d0b95035-5d85-4ec4-bc48-b3e60e281c3a "UNION ALL producing error Conversion failed when converting the varchar value '
0' to data type int.") UNION ALL with IF...ELSE (Transact-SQL)
Union All with multiple exec(@query) with dynamic column name
UNION between two CTE result set
UNION Query - text and date time formatting issue
Union Query to get multiple rows in a single row - sql server 2008
Union results from Stored Procs
Union Select ALL query not returning all rows
UNION vs DISTINCT
Unique Identifier vs Varchar(36) for storing GUIDs
Unique integer based on unique string
uniqueidentifier and stored procedures
Unlock a stored procedure
Unpivot, Pivot without Aggregation
Unzip a file in TSQL from a variable
UPDATE - SET field+=value - ATOMIC / Concurrency safe ?
Update 700 Million Records Quickly
Update a column randomly based on values from another table
UPDATE alternatives - which method is most efficient?
Update column in table1 from table2
update column with a unique and random string
Update column with values from the same column
Update Date value alone of a date time field in sql
Update datetime filed with null
update datetime to date only
Update Fields in table only if the field is null
Update foreign key column
UPDATE is much faster than DELETE+INSERT sql server
Update multiple databases based on databasename
Update multiple rows in a table from a subquery
update multiple rows with subquery that use EXCEPT
Update Multiple using Select - Subquery returned more than 1 value
Update on one table takes too long
Update Openquery to Oracle with date
UPDATE OPENROWSET not working
Update or insert of view failed because it contains a derived or constant field
Update or insert of view or function 'Target' failed because it contains a derived or constant field
Update Primary Key column in Sql Server
UPDATE query - An aggregate may not appear in the set list of an UPDATE statement.
Update Query from One Database table to Another Database Table
Update query View or function 'a' is not updatable because the modification affects multiple base tables.
Update row in Date column to GETDATE() if the record is older than 24 months
update smalldatetime column
UPDATE Statement Failing on Unique Key Constraint
update statement with COALESCE
update stats with full scan on database
update table all null values to 0 single query
UPDATE TABLE FROM LINK SERVER
UPDATE TABLE using ROW_NUMBER() OVER...
Update Temp table with a While Loop
Update the same table in the trigger
Update timestamp column in existing table
Update TOP (1) ?
Update trigger -> not updating.
Update Trigger Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
update WITH (ROWLOCK)
Update with Select top n statement
Update with TOP 1 SELECT
Updating a temporary table from another table by matching column values.
Updating a varbinary field - extra leading zero added
Updating only one row
Updating SQL column value with previous row data?
Upper limit of open SQL cursor
UPSERT using MERGE or otherwise on very large tables
Urgently need to recover deleted/truncated data from tables
use a stored procedure in a select subquery
use CTE in left join
Use Database Name in Variable
Use dateDiff and how to take care of the value of end date is null
Use DateDiff to get Age In Months
Use of Count(*) in WHERE Clause?
Use of GO in a Stored Procedure
use of temp table in user defined functions (UDF) in SQL server
Use of the "updlock" hint with update and insert statements
Use of Update with (NOLOCK)
Use ROW_NUMBER as a join to in a query.
Use sequences and triggers for identity
Use Stuff and joins together
Use Table Name or Table Alias in Update Action Query
Use Table Variable In Dynamic SQL
Use trigger to set default values based on other columns
User cannot insert into Temp Table
User Defined Function created already is not able to modify
User input thru SSMS
Users granted in Linked Server
Using $(ESCAPE_NONE(JOBID)) in a Stored Procedure (SQL Server 2008 R2)
Using a CTE as a parameter for a table-value parameter
Using a CTE to delete rows
Using a CTE to Filter data
Using a parameter for the "IN" clause
Using a SQL variable name to refer to a file path.
Using a trigger to prevent a record from being deleted
Using a While inside a select statement
Using Alias in UPDATE SQL Statement
Using Alter Statemement to add a constraint to set a column 'Date' to be less than (<) today's date?
Using BCP utility in a Batch file.
using Bulk Insert, get error: Invalid column number in the format file
Using calculated field in the group by clause
using case in partition by (ranking function)
Using Case in Select with OpenQuery
Using CASE Statement to SET variable
Using CASE statement within GROUP BY
Using Cast and distinct together in query
Using CAST and SUM to calculate a Percentage
using CAST in computed field
Using COALESCE to select from multiple tables
Using Column Name Variable in Update Clause
Using COUNT(*) from SELECT statement for UPDATE qry
Using CROSS APPLY to convert COLUMNS to ROWS and skip COLUMNS with NULL values
Using CTE to get result without using while loop
Using Date values in Dynamic SQL within a WHERE clause
using decile ranking in sql server
Using DISTINCT with SELECT INTO
Using dynamic column names stored in a table in select statement
Using dynamic SQL in Transaction Block
Using Dynamic SQL with trigger and stored procedures
Using error handling techniques in cursor routine
Using EXEC master.dbo.xp_cmdshell to copy a file from path with dollar sign !??!?
using EXEC to execute a formula stored in a string
Using EXEC with a table variable?
Using EXEC/EXECUTE with an UPDATE T-SQL statement - not firing as expected
Using EXISTS in SELECT list
Using EXISTS with dynamic query
using exists with group by
using function in select query
Using get month against Financial Calendar
Using IF...Else and Rollback Transaction
Using INSERT with CASE and SELECT
Using ISNULL in CASE statement
Using Lag to get the last "non-null" value
Using Max and Sum functions within the same query
Using MAX() In Case Statement
Using Merge - SQL Data Warehouse
Using Min and MAX function on Bit Field
Using Multiple CTEs in a SQL view
Using new THROW statement
Using NOLOCK with in BEGIN TRANSACTION
Using NOT LIKE in a CASE statement
using OPEN QUERY in From clause and Joins
Using OPENQUERY with variables in the argument
Using OPENROWSET for csv files
Using OPENROWSET with a join expression results in MASSIVE (!) 10 min. nested loop
Using OPTION clause within CREATE FUNCTION statement for inline table functions
Using PATINDEX and SUBSTRING to extract 8-10 digits date?
Using PatIndex to find all numeric values
Using PIVOT with Multiple Aggregates
Using PRINT within a function
using raiserror to raise an error and exit
Using ranking function to get latest entry
Using ROUND with PIVOT
using rowcount and WHILE for mass data insert?
Using RowCount or similar to either commit or roll back a query
Using SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED in a view
Using sp_send_dbmail , bcc recipient is getting duplicate emails
Using sp_send_dbmail to send the query results in the excel sheet
Using SQL Delay inside Triggers
Using SQL to calculate the IRR
Using stored procedure in a Where clause.
Using Stored Procedure to Insert Data and Return Value
Using SUM result in a WHERE clause
using SUM with rank() over (partition
Using table variables with DELETE
Using TABLOCK
using temp table in function
using temporal as of clause in a join
Using the bcp command to export a table or view into an excel file
Using the results of a CAST in a WHERE clause
Using try catch in a stored proc thats using cursors
Using Union All when inerting into temp tables
using UniqueIdentifier list in Select * from table where UniqueIdentifierCol in UniqueIdentifierList
using UPDATE on a GROUP BY clause
Using varchar for primary key value ok?
Using Variable for Column name in sql store procedure
Using Variable in SQL IN Clause
Using Variables in Where Clause
Using While Loop for SQL Server Update
Using XP_CMDSHELL to send the file to a specific network destination
Using xp_dirtree to pass filenames to a loop
UTF8 / Codepage 65001 BULK INSERT failure
Validate Data is in YYYYMMDD format
Validate each field of every row in sql table. If the record is valid then send email saying valid record, if invalid then send email with validation failure details,
VARBINARY -vs- VARBINARY(MAX) truncate issue
Varbinary to xml conversion error
VARBINARY Truncates
Varbinary(Max) to UTF-8 ?
varchar(100) Vs varchar(1000)
variable assignment is not allowed in a cursor declaration
Variable based name for temp table during SP
Variable Exists check
variable substitution in sql server
variables on RAISERROR
Very slow execution for a MERGE statement - SQL Server 2012
View image stored in VARBINARY(MAX) column in SQL SERVER 2008
VIEW runs but cannot be edited - too many prefixes
View Temp table ownership
View-Schemabinding error-Names must be in two-part format and an object cannot reference itself.
Views or functions cannot reference themselves directly or indirectly.
Wait until sp_start_job completes
Want to remove specific charcters and number from 1 column
want to update one row at a time but all rows in the table. URGENT!
Web Service call from SQL Server
Week number in sql server
Weird stored procedure pre-execute JSON error: Msg 13609, Level 16, State 2, Procedure ..., Line ... [Batch Start Line ...] JSON text is not properly formatted. Unexpected character '.' is found at position 0.
what account does bulk-insert use when running from ssms?
What are SQL Server Binary Files?
What are the Pros and Cons of using the MERGE statement versus EXCEPT in identifying changed dimensional data
What are Weights in SQL Server?
What causes sp_procedure_params_100_managed to be called when a stored procedure with parameters is executed in SQL2012
What does "Estimated Operator Cost" mean?
what does "Must declare the scalar variable "@bExist" mean?
what does { } means in sql query
What does COLLATE Latin1_General_CI_AS NULL do?
What does exclamation (!) mark mean next to variable?
What does mean "DECIMAL(6,3)" in the following Stored Procedure
What does N' and U' mean in this code?
What does this percentage sign mean here?
What GRANT permission do I ask for to be able to see the SQL that went into a view
What is "with execute as caller" in SP?
What is a Domain account in Sql server. How do i create a Domain account?
What is alternative to Table PARTITIONING in sql server standard edition ?
What is CUBE and ROLLUP???
what is dbo.split?
What is difference between SP_WHO & SP_WHO2?
What is difference between the server name and instance Names
what is difference between views and table and stored procedure
What is function of the ignore_dup_key option?
What is INSERT BULK?
What is Logical File Name?
What is READPAST lock and how it works
what is table spool in execution plan ? how to avoid this ?
What is the alternative of LEAD in SQL Server 2008 R2
What is the available free space in database properties in SQL database and how it varies
What is the best practice when returning custom messages from stored procedure
What is the best way to get date and hour with zero minute and second ?
What is the best way to return boolean logic from a UDF?
what is the data type that accepts 1,000,000 characters in one cell ?
what is the difference between auto increment and identity
what is the difference between covering and included indexes ?
What is the difference between HOLDLOCK and UPDLOCK in sql server
what is the difference between Static cursor,Dynamic cursor and keyset cursor
what is the difference between using Cursors and aTemp table
what is the easiest way to drop all objects of a schema?
What is the equivalent of oracle function NEXT_DAY in sql server
What is the good solution for deleting a large number of rows in huge database without growing transaction log file?
What is the limitations for Pivot table in sql server ?
What is the meaning of IF @@trancount > 0 ROLLBACK TRANSACTION
What is the meaning of UPDATE and DELETE WITH(NOLOCK) statements?
What is the overhead of indexes?
What is the reason for not allowed to write delete statements in a function?
What is the result of "SELECT 2/2/4" in SQL ? And Why?
What is the use of table master.dbo.spt_values..
what is the way to compare two datetime columns in sql server table
What is this Job "syspolicy_purge_history" ? what does it do?
What is wrong with this merge statement
What permissions are needed to execute stored procedure?
What should be the naming convention for indexes?
What the maximum UNION can be use on a single SQL?
What's the best way to compare two numbers
what's Uncommittable Transaction?
Whats the best way to debug a user defined function
Whats the use Ragged right in flat file connection manager in SSIS
Whats this dollar sign next to my database name in my query?
when join two tables with Composite primary keys, what will be best performance, use some fields, or all fields
When was the last time a record was added/modified in a sql table?
When will CTE Query be executed
Where Clause comparing int with string literals
Where clause using a Uniqueidentifier datatype
Where Clause Using Relative Dates
Where condition in OpenQuery
Where does CTE results get stored?
WHERE DOES NOT CONTAIN
WHERE IN with composite key.
WHERE Statement with Time and Date (Previous Day After 7pm and Current Day up to 9am)
where to and where not to use WITH (NOLOCK)
Where, Group By, Having, Order --- Usage sequence?
Whether a column is nullable by default?
Which data type to store a UTC Date/Time?
Which Language is known by only one programmer? and their names. If possible all details
Which of the following SQL statements has correct syntax?
Which one of using Left join or using CTE is better in this instance query?
Which paging method (Sql Server 2008) for BEST performance ?
while loop and delete statement
While Loop Does not end when condition is no longer True
while loop for date
while loop in view
While Loop or CTE which one will give better performance.
while loop with case statement
while loop with variable in sql
WHILE Loop with WAITFOR DELAY
Who has accessed MS SQL Server? Which tables?
Who has accessed my Sql server databases objects and when?
Who modified my Stored Procedure?
Why am I getting "There is already an object named '#TempTable...' in the database." within my SQL Server IF Statement
Why am I receiving "No Join Predicate" warning
Why are there so many(106) Hungarian collations?
why bit type values displays as True or False?
Why can't I concat inside of RAISERROR?
Why DML operations are not allowed in functions in SQL Server?
Why does decimal(38, 20) not give 20 decimal places?
Why does SELECT INTO only work for tables that don't exist?
Why does this query timeout in an application but not in Management Studio?
Why does UPDATE of #Temp table w/300K rows in stored procedure generate 1.8 million more logical reads than UPDATE of similar permanent table?
Why Incorrect syntax near the keyword 'UNION'.
Why is coalesce converting my string to an int?
Why is function call returning 'Invalid object name'?
Why is JOIN on a temp table so much faster than a JOIN on a CTE?
Why is nvarchar(max) size limited to 4000 characters
Why is start_date blue when it isn't a reserved word?
Why is stored procedure slow, while same query fast?
Why is this TRY-CATCH block not catching the exception?
Why ISNULL in subquery works this way?
why RID lock will effect the other RID lock in which different data page.
why should primary key be the first column in a table
Why String Got Cut-off In Print Output
Why T-SQL compare strings case insensitively ?
Why we can't use order by in a view?
Why wrap just a SELECT statement in a TRANSACTION?
wideworldimporters in excel
Wierd error with transaction
Wildcard in stored procedures
will this degrade performance of query if you use Upper function?
Windowed functions do not support constants as ORDER BY clause expressions.
WITH (NOLOCK) improves the Performance?
WITH CHECK OPTION
Workaround for more than 4 parts with PARSENAME
Would like to convert Base64 string and convert it to an image in my TSQL.
Wrap function in SQL
Writing a temp table with BCP
Writing Data to a SYSLOG Server
XML data type not supported in Distributed Queries
xml encoding utf-16 not working in sqlserver
XML operation resulted an XML data type exceeding 2GB in size. Operation aborted.
XML Output when Blank, Space or Null
XML parsing: line 1, character 28, illegal qualified name character
XML query returning NULL values for the given query
XMLAGG equivalent in SQL server 2014
xp_cmdshell always returns NULL
xp_cmdShell DIR command to check if file exists
xp_cmdshell throws Access is Denied error
XP_CMDSHELL with net use is throwing error when used with proxy account
xp_fileexist - permission
xp_sqlagent_enum_jobs documentation?
Year To Date, quarter to date and Months to date sum in single query
You can only specify the READPAST lock in the READ COMMITTED or REPEATABLE READ isolation levels
You do not have permission to use the bulk load statement error