<< < 39 40 41 42 43 44 45 46 47 48 49 > >>   ∑:1328  Sort:Date

"SELECT" Statements - Reading the Data In a Table in SQL Server
How to read data in a table with "SELECT" statements in SQL Server? This is the fourth tutorial of a quick lesson on creating database objects with Transact-SQL statements. This lesson shows you how to create a database, create a table in the database, and then access and change the data in the tabl...
2016-12-02, 1587🔥, 0💬

Creating a New Table in MySQL
How To Create a New Table in MySQL? If you want to create a table, you can run the CREATE TABLE statement as shown in the following sample script: &lt;?php include "mysql_connection.php"; $sql = "CREATE TABLE fyi_links (" . " id INTEGER NOT NULL" . ", url VARCHAR(80) NOT NULL" . ", notes VARCHAR...
2017-10-08, 1586🔥, 0💬

Pass a Parameter to a Cursor in Oracle
How To Pass a Parameter to a Cursor in Oracle? When you define a cursor, you can set a formal parameter in the cursor. The formal parameter will be replaced by an actual parameter in the OPEN cursor statement. Here is a good example of a cursor with two parameters: CREATE OR REPLACE PROCEDURE FYI_CE...
2018-07-18, 1584🔥, 0💬

What Is SQL Standard in MySQL
What Is SQL Standard in MySQL? SQL, SEQUEL (Structured English Query Language), is a language for RDBMS (Relational Database Management Systems). SQL was developed by IBM Corporation. SQL became an ANSI standard, called SQL-87, in 1986. ISO made a major revision, called SQL-92, in 1992. The latest r...
2018-04-21, 1584🔥, 0💬

Use "mysql" to Run SQL Statements in MySQL
How To Use "mysql" to Run SQL Statements in MySQL? If you want to run SQL statement to your server with "mysql", you need to start "mysql" and enter your SQL statement at the "mysql" prompt. Here is a good tutorial exercise that shows you how to run two SQL statements with "mysql": &gt;cd \mysql...
2018-02-28, 1584🔥, 0💬

Retrieving MySQL Server information in MySQL
How To Get Some Basic Information Back from MySQL Servers in MySQL? Once you got a MySQL server connection object successfully, you can use mysql_get_server() and mysql_get_host_info() to get some basic information from your MySQL server. The tutorial exercise below is a good example: &lt;?php $...
2017-11-11, 1584🔥, 0💬

Index - Data Structure for Query Performance in Oracle
What Is an Index in Oracle? Index is an optional structure associated with a table that allow SQL statements to execute more quickly against a table. Just as the index in this manual helps you locate information faster than if there were no index, an Oracle Database index provides a faster access pa...
2019-05-10, 1583🔥, 0💬

Using SELECT Statements with Joins and Subqueries in SQL Server
Where to find answers to frequently asked questions on Using SELECT Statements with Joins and Subqueries in SQL Server? Here is a list of frequently asked questions and their answers compiled by FYIcenter.com DBA team on Using SELECT Statements with Joins and Subqueries in SQL Server. Clear answers ...
2016-10-30, 1583🔥, 0💬

Converting Dates to Character Strings in MySQL
How To Convert Dates to Character Strings in MySQL? You can convert dates to character strings using the DATE_FORMAT(date, format) function. MySQL supports the following basic formatting codes: %a Abbreviated weekday name (Sun..Sat) %b Abbreviated month name (Jan..Dec) %c Month, numeric (0..12) %D D...
2017-12-26, 1582🔥, 0💬

"DROP SCHEMA" - Dropping an Existing Schema in SQL Server
How To Drop an Existing Schema in SQL Server? If you want to delete a schema, you need to move all objects out of that schema, then use the "DROP SCHEMA" statement to delete the schema. The tutorial exercise below shows you how to drop schema "fyi": -- Login with "sa" USE FyiCenterData; GO -- Drop f...
2016-10-20, 1582🔥, 0💬

"RETURNS TABLE" - Creating Inline Table-Value Functions in SQL Server
How To Create an Inline Table-Valued Function in SQL Server Transact-SQL? To create an inline table-valued function, you need to use the "RETURNS TABLE" clause in the "CREATE FUNCTION" statement. There should be no function body, except for a RETURN statement with a SELECT subquery: An inline table-...
2016-12-18, 1581🔥, 0💬

"CREATE TABLE" Statement - Creating New Tables in SQL Server
How to create new table with "CREATE TABLE" statements in SQL Server? This is the second tutorial of a quick lesson on creating database objects with Transact-SQL statements. This lesson shows you how to create a database, create a table in the database, and then access and change the data in the ta...
2016-12-02, 1581🔥, 0💬

Deleting All Rows with DELETE Statements in SQL Server
How To Delete All Rows with DELETE Statements in SQL Server? If you want to delete all rows from a table, you have two options: Use the DELETE statement with no WHERE clause. Use the TRUNCATE TABLE statement. Here is an example of deleting all rows with a DELETE statement: SELECT COUNT(*) FROM fyi_l...
2016-10-30, 1581🔥, 0💬

Who Is the Owner of a Schema in SQL Server
Who Is the Owner of a Schema in SQL Server? When you create a schema in a database, SQL Server will assign a owner (a database user) to this schema. If your login name is mapped to the owner of a schema at the database level, you have the full permission on all objects in this schema. The following ...
2016-10-22, 1581🔥, 0💬

Apply Filtering Criteria at Group Level in MySQL
How To Apply Filtering Criteria at Group Level in MySQL? If you want to return only specific groups from the query, you can apply filtering criteria at the group level by using the HAVING clause inside the GROUP BY clause. Note group functions can also be used in HAVING conditions. The following tut...
2017-10-16, 1580🔥, 0💬

CREATE INDEX - Adding an Index on an Existing Table in SQL Server
How To Create an Index on an Existing Table in SQL Server? If you want to an index on an existing table, you can use the CREATE INDEX statement in a simple syntax: CREATE INDEX index_name ON table_name (column_name) The tutorial exercise below shows you how to add an index for the "in" column of the...
2016-11-15, 1580🔥, 0💬

"FETCH" - Transferring Data from Cursors to Variables in SQL Server
How To Transfer Data from a Cursor to Variables with a "FETCH" Statement in SQL Server Transact-SQL? By default, a FETCH statement will display the fetched row on the client program window. If you want to transfer the output data to variables, you can specify an INTO clause with a list of variables ...
2016-10-17, 1580🔥, 0💬

Drop an Existing Table in MySQL
How To Drop an Existing Table in MySQL? If you want to delete an existing table and its data rows, you can use the "DROP TABLE" statement as shown in the tutorial script below: mysql&gt; SELECT * FROM tipBackup; +----+-------------+---------- ---------------+-------------+| id | subject | descri...
2018-02-14, 1578🔥, 0💬

Query with a Left Outer Join in MySQL
How To Write a Query with a Left Outer Join in MySQL? If you want to query from two tables with a left outer join, you can use the LEFT OUTER JOIN ... ON clause in the FROM clause. The following query returns output with a left outer join from two tables: fyi_links and fyi_rates. The join condition ...
2017-09-28, 1578🔥, 0💬

PHP ODBC - Deleting Existing Rows in a Table
PHP ODBC - How To Delete Existing Rows in a Table? If you want to remove a row from a table, you can use the DELETE statement with a WHERE clause to identify the row. The following sample script deletes one row: &lt;?php $con = odbc_connect('FYI_SQL_SERVER', 'sa','FYIcenter');$sql = "DELETE FROM...
2024-05-05, 1576🔥, 0💬

Use "FOR" Loop Statements in Oracle
How To Use "FOR" Loop Statements in Oracle? If you have a block of codes to be executed repeatedly over a range of values, you can use the "FOR ... LOOP" statement. Here is a sample script on FOR statements: DECLARE total NUMBER := 0; BEGIN FOR i IN 1..10 LOOP total := total + i; END LOOP; DBMS_OUTP...
2018-07-13, 1576🔥, 0💬

Query with a Right Outer Join in MySQL
How To Write a Query with a Right Outer Join in MySQL? 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 condit...
2017-09-28, 1576🔥, 0💬

Getting Parts of DATETIME Values as Integers in SQL Server
How To Get Parts of DATETIME Values as Integers in SQL Server Transact-SQL? Sometimes, you want to one specific part of a DATETIME value as an integer to be used in your own date and time calculations. This can be done by using the DATEPART() function in the following format: DATENAME(datepart, date...
2017-02-14, 1576🔥, 0💬

Writing Date and Time Literals in MySQL
How To Write Date and Time Literals in MySQL? MySQL offers a number of formats for you to use to enter date and time literals: ANSI standard format: "YYYY-MM-DD HH:MM:SS". Non-standard limiters. Like: "YYYY/MM/DD HH^MM^SS" or "YYYY.MM.DD HH-MM-SS". No limiters. Like: "YYYYMMDD" for a date or "HHMMSS...
2017-12-26, 1575🔥, 0💬

<< < 39 40 41 42 43 44 45 46 47 48 49 > >>   ∑:1328  Sort:Date