<< < 1 2 3 4 5 6 7 8 9 10 > >>   Sort: Rank

How To Enter Binary Numbers in SQL Statements
How To Enter Binary Numbers in SQL Statements? - MySQL FAQs - Introduction to SQL Basics If you want to enter character strings or numeric values as binary numbers, you can quote binary numbers with single quotes and a prefix of (B), or just prefix binary numbers with (0b). Binary numbers will be au...
2007-05-11, 9901👍, 0💬

How To Add a New Column to an Existing Table
How To Add a New Column to an Existing Table? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements If you have an existing table with existing data rows, and want to add a new column to that table, you can use the "ALTER TABLE ... ADD COLUMN" statement. The tutorial script below shows ...
2007-05-11, 4869👍, 0💬

How To Delete an Existing Column in a Table
How To Delete an Existing Column in a Table? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements If you have an existing column in a table and you do not need that column any more, you can delete it with "ALTER TABLE ... DROP COLUMN" statement. Here is a tutorial script to delete an e...
2007-05-11, 4635👍, 0💬

How To Write Date and Time Literals
How To Write Date and Time Literals? - MySQL FAQs - Introduction to SQL Date and Time Handling 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...
2007-05-11, 4955👍, 0💬

How To Concatenate Two Character Strings
How To Concatenate Two Character Strings? - MySQL FAQs - Introduction to SQL Basics 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...
2007-05-11, 11052👍, 0💬

What Are Date and Time Data Types
What Are Date and Time Data Types? - MySQL FAQs - Introduction to SQL Date and Time Handling MySQL supports the following date and time data types: DATE - A date in the range of '1000-01-01' and '9999-12-31'. Default DATE format is "YYYY-MM-DD". DATETIME - A date with the time of day in the range of...
2007-05-11, 4788👍, 0💬

How To Enter Characters as HEX Numbers
How To Enter Characters as HEX Numbers? - MySQL FAQs - Introduction to SQL Basics If you want to enter characters 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 charact...
2007-05-11, 6771👍, 0💬

What Are Date and Time Functions
What Are Date and Time Functions? - MySQL FAQs - Introduction to SQL Date and Time Handling MySQL offers a number of functions for date and time values: ADDDATE(date, INTERVAL expr unit) - Adding days to a date. Same as DATE_ADD(). ADDTIME(time1, time2) - Adding two time values together. CURDATE() -...
2007-05-11, 4782👍, 0💬

What Are Date and Time Intervals
What Are Date and Time Intervals? - MySQL FAQs - Introduction to SQL Date and Time Handling A date and time interval is special value to be used to increment or decrement a date or a time at a given date or time unit. A data and time interval should be expression in the format of "INTERVAL expressio...
2007-05-11, 4904👍, 0💬

How To Rename an Existing Table
How To Rename an Existing Table? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements If you want to rename an existing table, you can use the "ALTER TABLE ... RENAME TO" statement. The tutorial script below shows you a good example: mysql> ALTER TABLE tip RENAME TO faq; Query OK, 0 ro...
2007-05-11, 4547👍, 0💬

How To Decrement Dates by 1
How To Decrement Dates by 1? - MySQL FAQs - Introduction to SQL Date and Time Handling If you have a date, and you want to decrement it by 1 day, you can use the DATE_SUB(date, INTERVAL 1 DAY) function. You can also use the date interval subtraction operation as "date - INTERVAL 1 DAY". The tutorial...
2007-05-11, 8977👍, 0💬

How To Enter Numeric Values as HEX Numbers
How To Enter Numeric Values as HEX Numbers? - MySQL FAQs - Introduction to SQL Basics 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...
2007-05-11, 9101👍, 0💬

How To Rename an Existing Column in a Table
How To Rename an Existing Column in a Table? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements If you have an existing column in a table and you want to change the column name, you can use the "ALTER TABLE ... CHANGE" statement. This statement allows you to change the name of a colu...
2007-05-11, 4587👍, 0💬

How To Get a List of All Tables in a Database
How To Get a List of All Tables in a Database? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements If you want to see the table you have just created, you can use the "SHOW TABLES" command to get a list of all tables in database. The tutorial script gives you a good example: mysql> SH...
2007-05-11, 4669👍, 0💬

How To Increment Dates by 1
How To Increment Dates by 1? - MySQL FAQs - Introduction to SQL Date and Time Handling If you have a date, and you want to increment it by 1 day, you can use the DATE_ADD(date, INTERVAL 1 DAY) function. You can also use the date interval add operation as "date + INTERVAL 1 DAY". The tutorial exercis...
2007-05-11, 6601👍, 0💬

How Many Ways to Get the Current Time
How Many Ways to Get the Current Time? - MySQL FAQs - Introduction to SQL Date and Time Handling There are 8 ways to get the current time: SELECT NOW() FROM DUAL; 2006-07-01 10:02:41 SELECT CURRENT_TIME() FROM DUAL; 10:02:58 SELECT SYSDATE() FROM DUAL; 2006-07-01 10:03:21 mysql> SELECT CURRENT_TIMES...
2007-05-11, 4899👍, 0💬

How To Enter Boolean Values in SQL Statements
How To Enter Boolean Values in SQL Statements? - MySQL FAQs - Introduction to SQL Basics If you want to enter Boolean values in SQL statements, you use (TRUE), (FALSE), (true), or (false). Here are some good examples: SELECT TRUE, true, FALSE, false FROM DUAL; +------+------+-------+------- +| TRUE ...
2007-05-11, 8959👍, 0💬

How To Create a Testing Table
How To Create a Testing Table? - MySQL FAQs - Understanding SQL INSERT, UPDATE and DELETE Statements If you want to practice DML statements, like INSERT, UPDATE and DELETE, you should create a testing table. The tutorial exercise shows you a good example: mysql> CREATE TABLE fyi_links (id INTEGER PR...
2007-05-11, 4610👍, 0💬

How To Drop an Existing Index
How To Drop an Existing Index? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements If you don't need an existing index any more, you should delete it with the "DROP INDEX indexName ON tableName" statement. Here is an example SQL script: mysql> DROP INDEX tip_subject ON tip; Query OK, ...
2007-05-11, 4803👍, 0💬

How To Drop an Existing Table
How To Drop an Existing Table? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements 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> SELECT * FROM tipBackup; +----+-------------+---------- ---...
2007-05-11, 4624👍, 0💬

How To Drop an Existing View
How To Drop an Existing View? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements If you have an existing view, and you don't want it anymore, you can delete it by using the "DROP VIEW viewName" statement as shown in the following script: mysql> DROP VIEW faqComment; Query OK, 0 rows ...
2007-05-11, 4748👍, 0💬

How To Create a Table Index
How To Create a Table Index? - MySQL FAQs - Understanding SQL CREATE, ALTER and DROP Statements If you have a table with a lots of rows, and you know that one of the columns will be used often as a search criteria, you can add an index for that column to improve the search performance. To add an ind...
2007-05-11, 4747👍, 0💬

How To Use LIKE Conditions
How To Use LIKE Conditions? - MySQL FAQs - Introduction to SQL Basics A LIKE condition is also called pattern patch. There are 3 main rules on using LIKE condition: '_' is used in the pattern to match any one character. '%' is used in the pattern to match any zero or more characters. ESCAPE clause i...
2007-05-11, 4668👍, 0💬

How To Use CASE Expression
How To Use CASE Expression? - MySQL FAQs - Introduction to SQL Basics There are 2 ways to use the CASE expression. The first way is to return one of the predefined values based on the comparison of a given value to a list of target values. The second way is to return one of the predefined values bas...
2007-05-11, 4724👍, 0💬

<< < 1 2 3 4 5 6 7 8 9 10 > >>   Sort: Rank