Ankith Reddy has Published 1070 Articles

How to measure actual MySQL query time?

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 08:08:48

4K+ Views

To measure actual MySQL query time, we can use the concept of profiling that must be set to 1 before executing the query.The order must be like this.Set profiling to 1 Then execute query Then show profilesNow, I am applying the above order to get the actual MySQL query time ... Read More

How to stop dragend's default behavior in drag and drop?

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 08:04:08

147 Views

To stop dragend’s default behavior, you need to detect if the mouse is over the drop target where you want to drop.This is what you should do only if you are hovering over my list − listContainer.insertBefore(source, myNode);Use jQuery −if ($(mylist).parent().find(":hover")) {    listContainer.insertBefore(source, myNode); }Read More

How to display all the tables in MySQL with a storage engine?

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 08:03:59

96 Views

We can display all the tables with the help of the WHERE clause. The syntax for that is as follows −SELECT table_name FROM INFORMATION_SCHEMA.TABLES WHERE engine = 'InnoDB';Now, the above syntax is applied to the given query −mysql> SELECT * from INFORMATION_SCHEMA.TABLES WHERE engine = 'InnoDB';The following is the output ... Read More

Detection on clicking bezier path shape with HTML5

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 07:54:28

157 Views

To detect Bezier path shape on click, try the following code −Examplevar l = boxes.length; for (var i = l-1; i >= 0; i--) {    drawshape(gctx, boxes[i], 'black', 'black');    var imgData = gctx.getImageData(mx, my, 1, 1);    var index = (mx + my * imgData.width) * 4;   ... Read More

How do I set the timezone of MySQL?

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 07:50:31

637 Views

To know the current time, we can use the now() function with SELECT statement. The query is as follows −mysql> SELECT now();After executing the above query, we will get the current time. The following is the output −+---------------------+ | now() ... Read More

HTML5 File API readAsBinaryString reads files as much larger and different than files on disk

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 07:49:37

93 Views

This may happen if you are reading your file as a binary string and forming the multipart/ form-data request manually.You need to try and use xhr.send(File) and work around xhr progress event, which is fired when all list items had been already created.ExampleThe following is our upload function −function display(url, ... Read More

How can I search (case-insensitive) in a column using LIKE wildcard?

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 07:44:36

170 Views

We can do this with the help of lower() with column name. Firstly, we will create a table with the help of CREATE command.Creating a table −mysql> CREATE table InCaseSensDemo -> ( -> Name varchar(100) -> ); Query OK, 0 rows affected (0.50 sec)Inserting records into the table with the ... Read More

How to select a column name with spaces in MySQL?

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 07:43:38

18K+ Views

To select a column name with spaces, use the back tick symbol with column name. The symbol is ( ` `). Back tick is displayed in the keyboard below the tilde operator ( ~).Firstly, create a table −mysql> CREATE table SpaceColumn -> ( -> `Student Name` varchar(100) -> ); Query ... Read More

How to take a snapshot of HTML5-JavaScript based video player?

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 07:42:59

644 Views

You can try to run the following code to take a snapshot of HTML5-JavaScript-based video player −Example                                       Snapshot                var video ... Read More

Animate CSS border-top-left-radius property

Ankith Reddy

Ankith Reddy

Updated on 25-Jun-2020 07:38:18

105 Views

To implement animation on the border-top-left-radius property with CSS, you can try to run the following codeExampleLive Demo                    table, th, td {             border: 2px solid black;          }     ... Read More

Advertisements