<< < 41 42 43 44 45 46 47 48 49 50 51 > >>   ∑:1288  Sort:Date

Deleting Multiple Rows with One DELETE Statement in SQL Server
How To Delete Multiple Rows with One DELETE Statement in SQL Server? You can delete multiple rows from a table in the same way as deleting a single row, except that the WHERE clause will match multiple rows. The tutorial exercise below deletes 3 rows from the fyi_links table: -- view rows to be dele...
2016-10-30, 1445🔥, 0💬

Entering Character Strings in MySQL
How To Include Character Strings in SQL statements in MySQL? If you want to include character strings in your SQL statements, you need to quote them in one of the following formats: Using single quotes. For example 'FYIcenter.com'. Using double quotes. For example "FYI Center". Using single quotes p...
2018-04-12, 1443🔥, 0💬

Create a New View in MySQL
How To Create a New View in MySQL? You can create a new view based on one or more existing tables by using the "CREATE VIEW viewName AS selectStatement" statement as shown in the following script: mysql&gt; CREATE TABLE comment (faqID INTEGER, message VARCHAR(256)); Query OK, 0 rows affected (0....
2018-01-24, 1443🔥, 0💬

Shutdown MySQL Server Properly in MySQL
How To Properly Shutdown MySQL Server Daemon mysqld in MySQL? The proper way to shutdown your MySQL server is to the use "mysqladmin shutdown" command. Other ways to shutdown your server include: Enter "mysqladmin -u root -ppassowrd shutdown" command with options in a command window. Use Windows Tas...
2017-12-04, 1443🔥, 0💬

Concatenating Character Strings in MySQL
How To Concatenate Two Character Strings in MySQL? If you want concatenate multiple character strings into one, you need to use the CONCAT() function. Here are some good examples: SELECT CONCAT('Welcome',' to') FROM DUAL; Welcome to SELECT CONCAT('FYI','center','.com') FROM DUAL; FYIcenter.com   ⇒ E...
2018-04-07, 1442🔥, 0💬

Testing DML Triggers in SQL Server
How To Test a DML Trigger in SQL Server? To test a DML trigger defined on a table, you just need to execute several INSERT, UPDATE and DELETE statements on that table as shown in this tutorial example: USE FyiCenterData; GO INSERT INTO fyi_users (name) VALUES ('FYI Admin'); GO Records are inserted, ...
2016-10-25, 1442🔥, 0💬

Merge Outputs from Two Queries in MySQL
How To Use UNION to Merge Outputs from Two Queries Together in MySQL? If you have two queries that returns the same row fields, you can merge their outputs together with the UNION operator. The following tutorial exercise shows you how to return all links that were created since year 2006 plus the o...
2017-12-21, 1439🔥, 0💬

Types of Table Joins in MySQL
How To Join Two Tables in a Single Query in MySQL? Two tables can be joined together in a query in 4 ways: Inner Join: Returns only rows from both tables that satisfy the join condition. Left Outer Join: Returns rows from both tables that satisfy the join condition, and the rest of rows from the fir...
2017-12-31, 1438🔥, 0💬

Counting Groups Returned with the GROUP BY Clause in SQL Server
How To Count Groups Returned with the GROUP BY Clause in SQL Server? If you use the COUNT(*) function on groups returned with the GROUP BY clause, it will count the number of rows within each group, not the number of groups. If you want to count the number of groups, you can put the GROUP BY query i...
2016-10-29, 1437🔥, 0💬

Converting Character Strings to Dates in MySQL
How To Convert Character Strings to Dates in MySQL? If you have a character string that represents a date, and you want to convert it into a date value, you can use the STR_TO_DATE(string, format) function. STR_TO_DATE() shares the same formatting codes with DATE_FORMAT() function. The tutorial exer...
2017-12-26, 1434🔥, 0💬

Using Subqueries with the EXISTS Operators in SQL Server
How To Use Subqueries with the EXISTS Operators in SQL Server? A subquery can be used with the EXISTS operator as "EXISTS (subquery)", which returns true if the subquery returns one or more rows. The following statement is a good example of "EXISTS (subquery)". It returns rows from fyi_links table t...
2016-10-29, 1433🔥, 0💬

Update Values in a Table in Oracle
How To Update Values in a Table in Oracle? If you want to update some values in one row or multiple rows in a table, you can use the UPDATE statement. The script below shows a good example: UPDATE fyi_links SET counts = 999, notes = 'Good site.' WHERE id = 101; 1 row updated. SELECT * FROM fyi_links...
2020-01-21, 1432🔥, 0💬

What Are Views in SQL Server
What Are Views in SQL Server? A view is a database object that represents the data in one or more tables in the same structure as a separate table. Here are some basic rules about views: Tables store real data. Views do not store real data. Views must have underlying tables to provide data. Each vie...
2016-11-08, 1429🔥, 0💬

Assign Names to Query Output Columns in MySQL
How To Name Query Output Columns in MySQL? Each column in the query output has a default name. If you don't like the default name, you can specify a new name for any column in the query output by using the AS clause. The following statement shows you a good example: mysql&gt; SELECT tag AS Categ...
2017-09-28, 1427🔥, 0💬

LIKE - Matching a Pattern in a Character String in SQL Server
What To Perform Pattern Match with the LIKE Operator in SQL Server Transact-SQL? Pattern match is a very important operation for search records base on character string columns. SQL Server 2005 offers the LIKE operator to perform pattern match operations in two formats: target_string LIKE pattern --...
2017-01-21, 1425🔥, 0💬

Primary Key - Default Indexes of Tables in SQL Server
Is the PRIMARY KEY Column of a Table an Index in SQL Server? If you define a primary key on a table, an index for the primary key column will be created by default. The tutorial exercise below shows you the index created as part of the primary key column of "fyi_links": USE FyiCenterData; GO -- Drop...
2016-11-13, 1425🔥, 0💬

Categories of Functions Based on Return Modes in SQL Server
How Many Categories of Functions based Their Return Modes in SQL Server Transact-SQL? SQL Server supports 2 categories of user defined functions based on their return modes: 1. Scalar-valued Functions - A function that returns a single value. Scalar-valued functions can be used in scalar expressions...
2016-12-18, 1424🔥, 0💬

Accessing a Schema Not Owned by You in SQL Server
What Happens If You Are Trying to Access a Schema Not Owned by You in SQL Server? In general, if you are trying to access an object in schema owned by another database user, you will get a "permission denied" error, unless that you have been granted access permission to that object explicitly. Here ...
2016-10-22, 1422🔥, 0💬

"DROP FUNCTION" - Dropping an Existing User Defined Function in SQL Server
How To Drop an Existing User Defined Function in SQL Server Transact-SQL? If you have an existing user defined function that you don't want to use it anymore, you should delete it from the SQL Server by using the "DROP FUNCTION" statement as shown in the tutorial example below: USE FyiCenterData; GO...
2016-12-24, 1418🔥, 0💬

Writing Inner Joins with the WHERE Clause in SQL Server
How To Write an Inner Join with the WHERE Clause in SQL Server? If you don't want to use the INNER JOIN ... ON clause to write an inner join, you can put the join condition in the WHERE clause as shown in the following query example: SELECT l.id, l.url, r.comment FROM fyi_links l, fyi_rates r WHERE ...
2016-10-29, 1418🔥, 0💬

Filerting out Duplications in Returning Rows in MySQL
How To Filter Out Duplications in Returning Rows in MySQL? If there are duplications in the returning rows, and you want to remove the duplications, you can use the keyword DISTINCT in the SELECT clause. The DISTINCT applies to the combination of all data fields specified in the SELECT clause. The t...
2018-01-06, 1415🔥, 0💬

Selecting Other User's Database in MySQL
Can You Select Someone Else Database in MySQL? If your MySQL server is provided by an Internet service company, they will provide you one database for your use only. There are many other databases on the server for other users. But your user account will have no privilege to select other databases. ...
2017-10-23, 1414🔥, 0💬

Running SQL Server 2005 Books Online on Your Local System in SQL Server
How to run SQL Server 2005 Books Online on your local system in SQL Server? SQL Server 2005 Books Online can be accessed by a Web browser over the Internet. But you can also download it and read it on your local system. If you have downloaded and installed SQL Server 2005 Books Online package, you f...
2016-12-04, 1413🔥, 0💬

Entering Numeric Values as HEX Numbers in MySQL
How To Enter Numeric Values as HEX Numbers in MySQL? If you want to enter numeric values as HEX numbers, you can quote HEX numbers with single quotes and a prefix of (X), or just prefix HEX numbers with (0x). A HEX number string will be automatically converted into a numeric value, if the expression...
2018-03-31, 1412🔥, 0💬

<< < 41 42 43 44 45 46 47 48 49 50 51 > >>   ∑:1288  Sort:Date