
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 6705 Articles for Database

4K+ Views
Big Data is basically a term that covers large and complex data sets. To handle it, one requires use of different data processing applications when compared with traditional types.While there are various applications that allow handling and processing of big data, the base framework has always been that of Apache Hadoop.What is Apache Hadoop?Hadoop is an open-source software framework written in Java and comprises of two parts, which are the storage part and the other being the data processing part. The storage part is called the Hadoop Distributed File System (HDFS) and the processing part is called MapReduce.We now look ... Read More

1K+ Views
Businesses around the world today are smart and do everything to get and retain their customers. They can identify malicious credit/debit card transactions, they can identify a person uniquely with face or eye detection as a password to unlock a device, offer what their customer are looking for in the least possible time, separate spams from regular emails, and predict within how much time one can reach their intended destination depending upon length of road, weather conditions, and traffic, etc.These challenging tasks are possible only when the algorithms carrying out such predictions are smart, and the learning approaches are the ... Read More

9K+ Views
As we know that in order to maintain the Big data and to get the corresponding reports in different ways from this data we use Hadoop which is an Open Source framework from Apache Software Foundation based on Java Programming Language.Now Apache introduces the next version of Hadoop which named as Hadoop 2 so as this post is focusing on differences between both of these versions.Following are the main differences between Hadoop 1 and Hadoop 2.Sr. No.KeyHadoop 1Hadoop 21New Components and APIAs Hadoop 1 introduced prior to Hadoop 2 so has some less components and APIs as compare to that ... Read More

14K+ Views
Data plays a crucial role in understanding the business trends. Many organizations generate and process huge volumes of data. This huge and complex data is referred to as "Big Data". Big data is of three types: structured data, semi structured data, and unstructured data. What is Structured Data? Structured data is generally stored in tables in the form of rows and columns. Structured data in these tables can form relations with another tables. Humans and machines can easily retrieve information from structured data. This data is meaningful and is used to develop data models. Structured data is used by ... Read More

543 Views
To convert a date format, use STR_TO_DATE() −mysql> create table DemoTable2010 ( DueDate varchar(20) ); Query OK, 0 rows affected (0.68 sec)Insert some records in the table using insert command −mysql> insert into DemoTable2010 values('12/10/2019 12:34:00'); Query OK, 1 row affected (0.13 sec) mysql> insert into DemoTable2010 values('12/12/2011 11:00:20'); Query OK, 1 row affected (0.21 sec) mysql> insert into DemoTable2010 values('31/01/2017 11:00:20'); Query OK, 1 row affected (0.23 sec)Display all records from the table using select statement −mysql> select * from DemoTable2010;This will produce the following output −+---------------------+ | DueDate | +---------------------+ | ... Read More

412 Views
Let us first create a table −mysql> create table DemoTable2009 ( Name varchar(20) ); Query OK, 0 rows affected (0.51 sec)Insert some records in the table using insert command −mysql> insert into DemoTable2009 values('John Doe'); Query OK, 1 row affected (0.13 sec) mysql> insert into DemoTable2009 values('Adam Smith'); Query OK, 1 row affected (0.23 sec) mysql> insert into DemoTable2009 values('John Smith'); Query OK, 1 row affected (0.13 sec) mysql> insert into DemoTable2009 values('David Miller'); Query OK, 1 row affected (0.18 sec)Display all records from the table using select statement −mysql> select * from DemoTable2009;This will produce the following output ... Read More

231 Views
Let us first create a table −mysql> create table DemoTable2008 ( Value int ); Query OK, 0 rows affected (10.59 sec)Insert some records in the table using insert command −mysql> insert into DemoTable2008 values(10); Query OK, 1 row affected (0.20 sec) mysql> insert into DemoTable2008 values(20); Query OK, 1 row affected (0.08 sec) mysql> insert into DemoTable2008 values(30); Query OK, 1 row affected (0.15 sec) mysql> insert into DemoTable2008 values(-31); Query OK, 1 row affected (0.16 sec) mysql> insert into DemoTable2008 values(-28); Query OK, 1 row affected (0.17 sec)Display all records from the table using select statement −mysql> select ... Read More

372 Views
To insert multiple records quickly, use a single INSERT and follow the below syntax −insert into yourTableName values(yourValue1, yourValue2, ...N), (yourValue1, yourValue2, ...N).....N;To understand the above syntax, let us create a table −mysql> create table DemoTable2007 ( Amount1 int, Amount2 int, Amount3 int ); Query OK, 0 rows affected (1.36 sec)Insert some records in the table using insert command −mysql> insert into DemoTable2007 values(450, 600, 700), (1000, 200, 3000), (800, 900, 1200), (1300, 1500, 2000), (40000, 50000, 6700); Query OK, 5 rows affected (0.11 sec) Records: 5 Duplicates: 0 Warnings: 0Display all records from the table ... Read More

445 Views
For this, you can use ORDER BY CAST(). Let us see an example −mysql> create table DemoTable2006 ( UserId int NOT NULL AUTO_INCREMENT PRIMARY KEY, UserCode varchar(20) ); Query OK, 0 rows affected (1.14 sec)Insert some records in the table using insert command −mysql> insert into DemoTable2006(UserCode) values('John_12'); Query OK, 1 row affected (0.20 sec) mysql> insert into DemoTable2006(UserCode) values('John_34'); Query OK, 1 row affected (0.14 sec) mysql> insert into DemoTable2006(UserCode) values('John_56'); Query OK, 1 row affected (0.12 sec) mysql> insert into DemoTable2006(UserCode) values('Chris_101'); Query OK, 1 row affected (0.16 sec) mysql> insert into DemoTable2006(UserCode) values('Chris_103'); Query ... Read More

391 Views
To get minimum value from a column with corresponding duplicate ids, use GROUP BY and MIN() −select min(yourColumnName) from yourTableName group by yourColumnName;To understand the above syntax, let us create a table −mysql> create table DemoTable2005 ( Id int, Price float ); Query OK, 0 rows affected (0.71 sec)Insert some records in the table using insert command −mysql> insert into DemoTable2005 values(1, 56.88); Query OK, 1 row affected (0.12 sec) mysql> insert into DemoTable2005 values(1, 120.56); Query OK, 1 row affected (0.23 sec)Display all records from the table using select statement −mysql> select * from DemoTable2005;This will produce ... Read More