- 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
Daniol Thomas has Published 212 Articles
Daniol Thomas
370 Views
You cannot do this with JavaScript since it takes the system time which displays the current date with Date object. However, you can change the current date by changing the timezone as in the following code −Example Live Demo var ... Read More
Daniol Thomas
154 Views
To declare optional function parameters in JavaScript, use the “default” arguments.ExampleYou can try to run the following code to declare optional parameters − // default is set to 1 function inc(val1, inc = 1) { return val1 + inc; } document.write(inc(10,10)); document.write(""); document.write(inc(10));
Daniol Thomas
175 Views
PHP provides us mysql_close() function with the help of which we can disconnect from the MySQL database anytime. This function takes a single parameter, which is a connection returned by the mysql_connect() function. Its syntax is as follows −Syntaxbool mysql_close ( resource $link_identifier );Here, if a resource is not specified, ... Read More
Daniol Thomas
67 Views
With the help of RAND() function used along with the ORDER BY clause, the set of rows or values can be randomized in the result set. To understand it considers a table ‘Employee’ having the following records −mysql> Select * from employee; +----+--------+--------+ | ID | Name | Salary ... Read More
Daniol Thomas
68 Views
It can be understood with the help of the following example using the table named ‘Student’ having the following description −mysql> DESCRIBE Student; +--------+-------------+------+-----+---------+-------+ | Field | Type | Null | Key | Default | Extra | +--------+-------------+------+-----+---------+-------+ | Name | varchar(20) | YES | ... Read More
Daniol Thomas
262 Views
With the help of SHOW CREATE FUNCTION statement, we can see the source code of a stored function. To make it understand we are using the stored function named Hello() in the query as follows −mysql> SHOW CREATE FUNCTION Hello\G *************************** 1. row *************************** ... Read More
Daniol Thomas
467 Views
Suppose one of the queries fails or generates errors and another query (s) properly executed the MySQL still commit the changes of the properly executed query(s). It can be understood from the following example in which we are using the table ‘employee.tbl’ having the following data −Examplemysql> Select * from ... Read More
Daniol Thomas
182 Views
If we have ALTER ROUTINE privileges for the procedure then with the help of DROP PROCEDURE statement we can drop a MySQL stored procedure. To demonstrate it, we are dropping a stored procedure named ‘coursedetails’ as follows −mysql> DROP PROCEDURE coursedetails; Query OK, 0 rows affected (0.68 sec)The above query will ... Read More
Daniol Thomas
260 Views
MySQL query optimizer is an important element of the MySQL server that makes an best question execution set up for a query. For a particular query, the query optimizer uses the stored key distribution and other factors to decide the order in which tables should be joined when you performing ... Read More
Daniol Thomas
362 Views
With the help of ‘mysqladmin’ program we would be able to shutdown our MySQL server. It can be used as follows on command line −C:\mysql\bin>mysqladmin -u root shutdownWe will see nothing after entering the above command because it will not print any message in command window. We should have to ... Read More