![Trending Articles on Technical and Non Technical topics](/images/trending_categories.jpeg)
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
AmitDiwan has Published 11367 Articles
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
306 Views
Let us first create a table −mysql> create table DemoTable(DueDate varchar(100)); Query OK, 0 rows affected (0.78 sec)Insert some records in the table using insert command −mysql> insert into DemoTable values('10-01-2019 10:19:20'); Query OK, 1 row affected (0.17 sec) mysql> insert into DemoTable values('12-03-2018 11:00:00'); Query OK, 1 row affected ... Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
395 Views
Let us first create a table −mysql> create table DemoTable726 (Value varchar(100)); Query OK, 0 rows affected (0.60 sec)Insert some records in the table using insert command −mysql> insert into DemoTable726 values('100'); Query OK, 1 row affected (0.18 sec) mysql> insert into DemoTable726 values('10'); Query OK, 1 row affected (0.15 ... Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
1K+ Views
You cannot give underscore in table name. If you still want to create a new table with underscore, surround it using backticks, not single quotes.However, let us first try to set quotes around a table name with underscore. Following is an example −mysql> create table 'Demo_Table725'( ClientId int NOT ... Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
798 Views
Let us first create a table −mysql> create table DemoTable724 (Value int); Query OK, 0 rows affected (0.79 sec)Insert some records in the table using insert command −mysql> insert into DemoTable724 values(101); Query OK, 1 row affected (0.16 sec) mysql> insert into DemoTable724 values(183); Query OK, 1 row affected (0.15 ... Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
368 Views
Let us first create a table −mysql> create table DemoTable723 (Value int); Query OK, 0 rows affected (0.58 sec)Insert some records in the table using insert command −mysql> insert into DemoTable723 values(100); Query OK, 1 row affected (0.13 sec) mysql> insert into DemoTable723 values(200); Query OK, 1 row affected (0.13 ... Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
308 Views
Let us first create a table −mysql> create table DemoTable ( Code varchar(100) ); Query OK, 0 rows affected (1.16 sec)Insert some records in the table using insert command −mysql> insert into DemoTable values('100-677-9876'); Query OK, 1 row affected (0.21 sec) mysql> insert into DemoTable ... Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
146 Views
Yes, we can all the reserved words in MySQL using the command-line utility. Following is the syntax −select *from mysql.help_keyword;Let us implement the above syntax in order to get list of all the reserved words in MySQL.Following is the query −mysql> select *from mysql.help_keyword;This will produce the following output -Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
236 Views
Let us first create a table −mysql> create table DemoTable722 ( StudentId int NOT NULL AUTO_INCREMENT PRIMARY KEY, StudentName varchar(100), StudentAge int ); Query OK, 0 rows affected (1.84 sec)Insert some records in the table using insert command −mysql> insert into DemoTable722(StudentName, StudentAge) values('Chris Brown', 23) ; ... Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
100 Views
Yes, SELECT with an IF/ELSE is possible in MySQL.Let us first create a table −mysql> create table DemoTable721 ( Id int NOT NULL AUTO_INCREMENT PRIMARY KEY, FirstName varchar(100), Marks int, CountryName varchar(100) ); Query OK, 0 rows affected (0.57 sec)Insert some records in the table using ... Read More
![AmitDiwan](https://www.tutorialspoint.com/assets/profiles/123055/profile/60_187394-1565938756.jpg)
AmitDiwan
464 Views
Use trigger BEFORE INSERT on the table to prevent having a zero value in a MySQL field. Let us first create a table −mysql> create table DemoTable(Value int); Query OK, 0 rows affected (0.85 sec)Let us create a trigger to prevent having a zero value in a MySQL field −mysql> ... Read More