- 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
Ayyan has Published 53 Articles
Ayyan
258K+ Views
Compiling and running a java program is very easy after JDK installation. Following are the steps −Open a command prompt window and go to the directory where you saved the java program (MyFirstJavaProgram.java). Assume it's C:\.Type 'javac MyFirstJavaProgram.java' and press enter to compile your code. If there are no errors ... Read More
Ayyan
109 Views
To match any string containing zero or one p’s with JavaScript RegExp, use the p? Quantifier.ExampleYou can try to run the following code to match any string containing zero or one p. Here p is considered a number of occurrences − JavaScript Regular Expression ... Read More
Ayyan
483 Views
To find carriage return character with JavaScript Regular Expression, use the following −\rExampleYou can try to run the following code to find a carriage return character. It returns the position where the carriage return (\r) character is found − JavaScript Regular Expression ... Read More
Ayyan
321 Views
As we know that we can modify a view by using ALTER VIEW statement but other than that we can also use CREATE OR REPLACE VIEW to modify an existing view. The concept is simple as MySQL simply modifies the view if it already exists otherwise a new view would ... Read More
Ayyan
457 Views
MySQL 5.7.2+ allows us to create multiple triggers for the same event and action time in a table. Both the triggers will activate sequentially when the event occurs. It can be understood with the help of an example −ExampleIn this example, we are creating multiple triggers for the same event ... Read More
Ayyan
242 Views
MySQL scalar subquery returns exactly one column value from one row and we can use it where a single column is permissible. Followings are the cases when scalar subqueries return value other than one row −Case1 − When it returns 0 rowsIn case if the subquery returns 0 rows then ... Read More
Ayyan
723 Views
We can update MySQL table after padding a string with the values of a column by using LPAD() or RPAD() function along with UPDATE clause. Following the example from ‘examination_btech’ table will make it clearer −ExampleSuppose if we want to append the values, in last, of column course with the ... Read More
Ayyan
44 Views
In case if ‘len’ is not within the length of the rest of the string then MySQL INSERT() function will continue to remove the characters until the end of the original string.Examplemysql> Select INSERT('myteststring',3,15,'name'); +------------------------------------+ | INSERT('myteststring',3,15,'name') | +------------------------------------+ | myname | +------------------------------------+ 1 row in set (0.00 sec)
Ayyan
119 Views
MySQL SUBSTRING_INDEX() function will return the same string as output if the argument ‘count’ has the value greater than the total number of occurrences of delimiter. It can be demonstrated with the following example −mysql> Select SUBSTRING_INDEX('My Name is Ram', 'a', 3); +-----------------------------------------+ | SUBSTRING_INDEX('My Name is Ram', 'a', 3) ... Read More
Ayyan
89 Views
In MySQL, we can use the following functions to calculate the Date −CURDATE() Function − Basically it returns the current date of the computer.YEAR() Function − It returns the year of the specified date.MONTH() function − It returns the month of the specified date.DAY() Function − It returns the day ... Read More