<< < 1 2 3 4 5 6 7 8 9 10 11 > >>   ∑:509  Sort:Date

EXECUTE - Executing Stored Procedures in SQL Server
How To Execute a Stored Procedure in SQL Server Transact-SQL? If you want execute a stored procedure created previously, you can use the EXECUTE statement in the following formats: EXEC procedure_name; EXECUTE procedure_name; The key word EXEC is actually optional. So you can execute a stored proced...
2017-01-05, 2262🔥, 0💬

"sys.columns" - Getting a List of Columns in a Table in SQL Server
How To Get a List of Columns using the "sys.columns" View in SQL Server? If you have an existing table, but you don't remember what are the columns defined in the table, you can use the "sys.columns" system view to get a list of all columns of all tables in the current database. In order to a list o...
2016-11-17, 2258🔥, 0💬

Versions of SQL Server Transact-SQL
How do I tell what version of Transact-SQL my SQL Server is using? The Transact-SQL version is the same as the SQL Server. You can determine the SQL Server version using the following Transact-SQL statement: SELECT @@version ------------------------------ ------------------------------ ------------Mi...
2017-06-16, 2247🔥, 0💬

"sp_columns" - Getting a List of Columns in a View in SQL Server
How To Get a List of Columns in a View using the "sp_columns" Stored Procedure in SQL Server? If you have an existing table, but you don't remember what are the columns defined in the view, you can use the "sp_columns" stored procedure to get a list of all columns of the specified view. The followin...
2016-11-05, 2247🔥, 0💬

Generating CREATE PROCEDURE Scripts on Existing Stored Procedures in SQL Server
How To Generate CREATE PROCEDURE Script on an Existing Stored Procedure in SQL Server Transact-SQL? If you want to know how an existing stored procedure was created, you can use SQL Server Management Studio to automatically generate a "CREATE PROCEDURE" script The following tutorial shows you how to...
2017-01-05, 2246🔥, 0💬

sys.sql_modules - Getting Trigger Definitions Back in SQL Server
How To Get the Definition of a Trigger Back in SQL Server? If you want get the definition of an existing trigger back from the SQL Server, you can use the catalog view called sys.sql_modules, which stores definitions of views, stored procedures, and triggers. The sys.sql_modules holds trigger defini...
2016-10-24, 2245🔥, 0💬

General Questions on Microsoft SQL Server Transact-SQL
Where to find answers to frequently asked questions in general areas of Microsoft SQL Server Transact-SQL? I am new to Transact-SQL. Here is a list of frequently asked questions and their answers compiled by FYIcenter.com team in general areas of Microsoft SQL Server Transact-SQL: What Is SQL Langua...
2017-06-16, 2237🔥, 0💬

Converting Binary Strings into Character Strings in SQL Server
Can Binary Strings Be Converted into Character Strings in SQL Server Transact-SQL? Binary strings and character strings are convertible. But there are several rules you need to remember: Binary strings can be converted implicitly to character strings by assignment operations. Binary strings can not ...
2017-02-28, 2224🔥, 0💬

"ALTER INDEX ... REBUILD" - Defragmenting Indexes in SQL Server
How To Rebuild Indexes with ALTER INDEX ... REBUILD in SQL Server? When an index is defragmented to a large percentage, like &gt; 30%, you can use the "ALTER INDEX ... REBUILD" statement to rebuild the index. Here is a tutorial exercise on rebuilding indexes: USE FyiCenterData; GO UPDATE fyi_lin...
2016-11-08, 2220🔥, 0💬

Date/Time Operations and Functions in SQL Server Transact-SQL
Where to find answers to frequently asked questions on Date/Time Operations and Functions in SQL Server Transact-SQL? Here is a list of frequently asked questions and their answers compiled by FYIcenter.com DBA team on Date/Time Operations and Functions in SQL Server Transact-SQL. Clear answers are ...
2017-02-25, 2219🔥, 0💬

Creating a Large Table with Random Data for Indexes in SQL Server
How To Create a Large Table with Random Data for Index Testing in SQL Server? If you want to see how index can be used to improve data search performance, you have to build some large tables, which requires large amount of random data. This tutorial exercise helps you to build a large table with pur...
2016-11-13, 2218🔥, 0💬

"sys.objects" - Listing All Objects in a Given Schema in SQL Server
How To List All Objects in a Given Schema in SQL Server? If you are wonder what objects are stored in a given schema as an object container, you can use view "sys.objects" to get a list of all objects in a schema. The tutorial exercise shows you how to list all objects in schema "fyi" and "dbo": -- ...
2016-10-22, 2213🔥, 0💬

"SELECT ... INTO" - Creating New Tables With Queries in SQL Server
How to create new tables with "SELECT ... INTO" statements in SQL Server? Let's say you have a table with many data rows, now you want to create a backup copy of this table of all rows or a subset of them, you can use the "SELECT ... INTO" statement. The tutorial script below gives you a good exampl...
2016-11-17, 2187🔥, 0💬

Selecting Some Specific Columns from a Table in SQL Server
How To Select Some Specific Columns from a Table in a Query in SQL Server? If you want explicitly tell the query to return some specific columns, you can specify the column names in the SELECT clause. The following select statement returns only three columns, "id", "created" and "url" from the table...
2016-10-26, 2180🔥, 0💬

sys.sql_modules - Getting View Definitions Back in SQL Server
How To Get the Definition of a View Out of the SQL Server in SQL Server? If you want get the definition of an existing view back from the SQL Server, you can use the system view called sys.sql_modules, which stores definitions of views and procedures. The sys.sql_modules holds view definitions ident...
2016-11-05, 2158🔥, 0💬

"DROP USER" - Deleting a Database User in SQL Server
How To Delete an Existing Database User in SQL Server? If you don't want to keep a database user any more, you should delete the user by using the "DROP USER" statement. This tutorial exercise shows how to delete "Dba_User": -- Login with "sa" USE FyiCenterData; GO DROP USER Dba_User; GO -- List all...
2022-01-24, 2155🔥, 0💬

sys.views - List of Existing Views in SQL Server
How To See Existing Views in SQL Server? If you want to know how many views you have created in a database, you use the system view called sys.views to get a list of views defined in the current database. The tutorial exercise shows you how many views in database FyiCenterData: USE FyiCenterData; GO...
2016-11-05, 2155🔥, 0💬

Overflow Errors on Converting Big Values to NUMERIC in SQL Server
What Happens When Converting Big Values to NUMERIC Data Types in SQL Server Transact-SQL? If you are converting a numeric expression to a NUMERIC data type and the value is too big for the storage size, you will get an arithmetic overflow error as shown in the following examples: -- Overflow error o...
2017-03-22, 2152🔥, 0💬

"DISABLE TRIGGER" - Disabling Triggers in SQL Server
How To Disable Triggers using "DISABLE TRIGGER" in SQL Server? If want to stop the execution of an existing trigger temporarily, you can use the "DISABLE TRIGGER" statement to disable it. The disabled trigger will be kept in the database. If you want to resume the execution of a disabled trigger, yo...
2016-10-24, 2150🔥, 0💬

Data Literals in SQL Server Transact-SQL
Where to find answers to frequently asked questions on data literals in Microsoft SQL Server Transact-SQL? I am new to Transact-SQL and SQL Server. Here is a list of frequently asked questions and their answers compiled by FYIcenter.com team on data literals in Microsoft SQL Server Transact-SQL: Con...
2017-05-20, 2149🔥, 0💬

What Causes Index Fragmentation in SQL Server
What Causes Index Fragmentation in SQL Server? Index fragmentation is usually caused by deleting of existing rows or updating existing values of the indexed column. Inserting new rows should not cause any index fragmentation. This tutorial exercise shows you how update statements of 50000 rows on th...
2016-11-08, 2138🔥, 0💬

sys.indexes - Viewing Existing Indexes on an Given Table in SQL Server
How To View Existing Indexes on an Given Table using sys.indexes in SQL Server? Another way to view existing indexes defined for a given table is to use the system view called "sys.indexes". The tutorial exercise shows you how many indexes were defined from the previous tutorial on table "fyi_links"...
2016-11-15, 2118🔥, 0💬

"RIGHT OUTER JOIN ... ON" - Writing Queries with Right Outer Joins in SQL Server
How To Write a Query with a Right Outer Join in SQL Server? If you want to query from two tables with a right outer join, you can use the RIGHT OUTER JOIN ... ON clause in the FROM clause. The following query returns output with a right outer join from two tables: fyi_links and fyi_rates. The join c...
2016-10-30, 2103🔥, 0💬

Setting New Values to Parts of a DATETIME Value in SQL Server
How To Set Different Parts of a DATETIME Value in SQL Server Transact-SQL? In SQL Server, you can get different parts of a DATETIME value with the DATEPART() functions. But there is no function that allows you to set different parts to a DATETIME value. For example, you a date_of_birth column as DAT...
2017-02-08, 2099🔥, 0💬

<< < 1 2 3 4 5 6 7 8 9 10 11 > >>   ∑:509  Sort:Date