
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
AmitDiwan has Published 10744 Articles

AmitDiwan
189 Views
For this, use Regular Expression in MySQL as in the below syntax −select * from yourTableName where yourColumnName regexp '\land[\land ]+[ ]+[\land ]+$';The above query will work when the two words are separated by a space. Let us first create a table −mysql> create table DemoTable1412 -> ( ... Read More

AmitDiwan
675 Views
To call stored procedures within a stored procedure, the syntax is as follows −If yourInputValue > 100 then call yourProcedureName1(); else call yourProcedureName2(); end If ; ENDLet us implement the above syntax. In order to implement the above concept, let us create ... Read More

AmitDiwan
110 Views
To get the specified members of the current Type, the code is as follows −Example Live Demousing System; using System.Reflection; public class Demo { public static void Main() { Type type = typeof(Subject); try { FieldInfo fieldInfo = type.GetField("SubName"); ... Read More

AmitDiwan
437 Views
For this, use REGEXP_REPLACE(). Let us first create a table −mysql> create table DemoTable1595 -> ( -> StudentCode varchar(50) -> ); Query OK, 0 rows affected (0.44 sec)Insert some records in the table using insert command −mysql> insert into DemoTable1595 values('200 John'); Query OK, 1 row affected ... Read More

AmitDiwan
306 Views
To select the nth highest value in MySQL, following is the syntax −select distinct(yourColumnName) from yourTableName order by yourColumnName DESC limit (NthValue-1), 1;Let us first create a table −mysql> create table DemoTable1594 -> ( -> Marks int -> ); Query OK, 0 rows affected (0.49 sec)Insert some ... Read More

AmitDiwan
95 Views
To create a Queue from another collection, the code is as follows −Example Live Demousing System; using System.Collections.Generic; public class Demo { public static void Main() { Queue queue = new Queue(); queue.Enqueue("One"); queue.Enqueue("Two"); queue.Enqueue("Three"); ... Read More

AmitDiwan
699 Views
Use IF() method as an alternative to CASE WHEN in MySQL. Let us first create a table −mysql> create table DemoTable1593 -> ( -> PlayerScore int -> ); Query OK, 0 rows affected (0.44 sec)Insert some records in the table using insert command −mysql> insert into DemoTable1593 ... Read More

AmitDiwan
610 Views
To count the total number of elements in the List, the code is as follows −Example Live Demousing System; using System.Collections.Generic; public class Demo { public static void Main(String[] args) { List list = new List(); list.Add("One"); list.Add("Two"); ... Read More

AmitDiwan
253 Views
For this, set conditions using MySQL IF(). Let us first create a table −mysql> create table DemoTable1592 -> ( -> StudentMarks int -> ); Query OK, 0 rows affected (0.76 sec)Insert some records in the table using insert command −mysql> insert into DemoTable1592 values(56); Query OK, 1 ... Read More

AmitDiwan
476 Views
For this, you can use TIME_FORMAT(). Let us first create a table −mysql> create table DemoTable1591 -> ( -> ArrivalTime varchar(20) -> ); Query OK, 0 rows affected (0.58 sec)Insert some records in the table using insert command −mysql> insert into DemoTable1591 values('1620'); Query OK, 1 row ... Read More