Abhinaya has Published 61 Articles

How do you launch the JavaScript debugger in Google Chrome?

Abhinaya

Abhinaya

Updated on 23-Jun-2020 06:40:20

204 Views

To launch JavaScript debugger in Google Chrome, try any of the following ways,Press Ctrl + Shift + JGo to Settings and click More Tools. After that, click Developer Tools.For more, refer the official website of  Chrome Dev Tool,

How to return an object from a JavaScript function?

Abhinaya

Abhinaya

Updated on 23-Jun-2020 06:07:20

6K+ Views

To return an object from a JavaScript function, use the return statement, with this keyword.ExampleYou can try to run the following code to return an object from a JavaScipt function − Live Demo                    var employee = {             ... Read More

How can we simulate the MySQL INTERSECT query having WHERE clause?

Abhinaya

Abhinaya

Updated on 22-Jun-2020 12:49:51

142 Views

Since we cannot use INTERSECT query in MySQL, we will use IN operator to simulate the INTERSECT query. It can be understood with the help of the following example −ExampleIn this example, we are two tables namely Student_detail and Student_info having the following data −mysql> Select * from Student_detail; +-----------+---------+------------+------------+ ... Read More

How can I display MySQL query result vertically?

Abhinaya

Abhinaya

Updated on 22-Jun-2020 11:03:30

565 Views

With the use of ego, \G option at end of a statement, we can get the result set in vertical format. Consider the following example −mysql> Select * from Student where name = 'Aarav'\G *************************** 1. row ***************************   Name: Aarav RollNo: 150  Grade: M.SC 1 row in set (0.00 sec)

How can MySQL IF ELSEIF ELSE statement be used in a stored procedure?

Abhinaya

Abhinaya

Updated on 22-Jun-2020 05:45:27

10K+ Views

MySQL IF ELSEIF ELSE execute the statements based on multiple expressions Its syntax is as follows −IF expression THEN    statements; ELSEIF elseif-expression THEN    elseif-statements; … … … … ELSE   else-statements; END IF;The statements must end with a semicolon.To demonstrate the use of IF ELSEIF ELSE statement within MySQL ... Read More

How MySQL prevents unauthorized clients from accessing the database system?

Abhinaya

Abhinaya

Updated on 20-Jun-2020 11:51:30

185 Views

MySQL implements a sophisticated access control and privilege system that allows us to create comprehensive access rules for handling client operations and effectively preventing unauthorized clients from accessing the database system.The MySQL access control has two stages when a client connects to the server −Connection verification A client, which connects to ... Read More

How can we calculate the difference between two time values in MySQL?

Abhinaya

Abhinaya

Updated on 20-Jun-2020 06:28:18

149 Views

With the help of TIMEDIFF() MySQL function the difference between two-time values can be calculated.Examplemysql> Select TIMEDIFF('04:05:45','03:05:45') AS ‘Difference in Time’; +---------------------------------+ | Difference in Time              | +---------------------------------+ | 01:00:00                        | +---------------------------------+ 1 row in set (0.00 sec)

How MySQL performs date arithmetic with addition and subtraction operators?

Abhinaya

Abhinaya

Updated on 19-Jun-2020 13:45:14

413 Views

MySQL can perform date arithmetic with addition and subtraction operators by adding together INTERVAL keyword with a unit of time, date or datetime.Example1Adding 2 days to a particular date.mysql> Select '2017-05-20' + INTERVAL 2 day; +-------------------------------+ | '2017-05-20' + INTERVAL 2 day | +-------------------------------+ | 2017-05-22         ... Read More

What is onerror() Method in JavaScript?

Abhinaya

Abhinaya

Updated on 19-Jun-2020 08:54:39

2K+ Views

The onerror event handler was the first feature to facilitate error handling in JavaScript. The error event is fired on the window object whenever an exception occurs on the page.ExampleYou can try to run the following code to implement onerror() method in JavaScript −           ... Read More

What is ternary operator (? X : Y) in C++?

Abhinaya

Abhinaya

Updated on 18-Jun-2020 13:45:52

203 Views

The conditional operator (? :) is a ternary operator (it takes three operands). The conditional operator works as follows −The first operand is implicitly converted to bool. It is evaluated and all side effects are completed before continuing.If the first operand evaluates to true (1), the second operand is evaluated.If ... Read More

Advertisements