AmitDiwan has Published 11365 Articles

HTML onoffline Event Attribute

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 11:31:26

55 Views

The HTML onoffline event attribute is triggered when the browser starts to work offline.SyntaxFollowing is the syntax −Let us see an example of HTML onoffline event Attribute−Example Live Demo    body {       color: #000;       height: 100vh;       background: linear-gradient(62deg, #FBAB7E 0%, ... Read More

HTML onload Event Attribute

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 11:28:16

177 Views

The HTML onload event attribute is triggered when an object has been loaded in an HTML document.SyntaxFollowing is the syntax −Let us see an example of HTML onload event Attribute−Example Live Demo    body {       color: #000;       height: 100vh;       ... Read More

HTML onbeforeprint Event Attribute

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 11:21:27

53 Views

The HTML onbeforeprint event attribute is triggered when a page is about to be printed or before the print dialog box appears in the HTML document.SyntaxFollowing is the syntax −Let us see an example of HTML onbeforeprint event Attribute−Example Live Demo    body {       color: ... Read More

HTML onafterprint Event Attribute

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 11:18:04

47 Views

The HTML onafterprint event attribute is triggered when a page has started printing or if the print dialog box has been closed in the HTML document.SyntaxFollowing is the syntax −Let us see an example of HTML onafterprint event Attribute−Example Live Demo    body {       color: ... Read More

HTML Form method Attribute

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 11:11:23

278 Views

The HTML form method attribute defines how to send form-data that means to be sent as URL variable or to be sent as an HTTP post transaction.SyntaxFollowing is the syntax −Here get sends the form data as URL variable and post sends the form data as an HTTP post transaction.Let ... Read More

HTML Location assign( ) Method

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 11:08:20

98 Views

The HTML Location assign() method loads a new HTML document without replacing the URL of the current HTML document from the document history.SyntaxFollowing is the syntax −location.assign(URL)Let us see an example of HTML Location assign() Method−Example Live Demo    body {       color: #000;       ... Read More

Get all the tables from a MySQL database having a specific column, let’s say xyz?

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 08:00:45

156 Views

Let’s say we have a database “web” and we need to get all the tables having a specific column ’StudentFirstName’.For this, below is the query −mysql> select myColumnName.table_name from information_schema.columns myColumnName where myColumnName.column_name = 'StudentFirstName' and table_schema='web';This will produce the following output −+---------------+ | TABLE_NAME | +---------------+ ... Read More

Convert MySQL timestamp to UNIX Timestamp?

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 07:58:58

1K+ Views

To convert MySQL timestamp to UNIX Timestamp, use the UNIX_TIMESTAMP(). Following is the syntax −select unix_timestamp(yourColumnName) from yourTableName;Let us first create a table −mysql> create table DemoTable(    Duetimestamp timestamp ); Query OK, 0 rows affected (2.66 sec)Insert some records in the table using insert command −mysql> insert into DemoTable ... Read More

How can I replace & with an ampersand in my MySQL database?

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 07:57:41

592 Views

To replace & with an ampersand, use MySQL REPLACE(). Let us first create a table −mysql> create table DemoTable(    Id int NOT NULL AUTO_INCREMENT PRIMARY KEY,    Value varchar(100) ); Query OK, 0 rows affected (1.06 sec)Insert some records in the table using insert command −mysql> insert into DemoTable(Value) ... Read More

Find average on the basis of corresponding duplicate VARCHAR values in MySQL

AmitDiwan

AmitDiwan

Updated on 27-Sep-2019 07:56:21

65 Views

Let us first create a table −mysql> create table DemoTable(    Value int,    Value2 varchar(100) ); Query OK, 0 rows affected (0.84 sec)Insert some records in the table using insert command −mysql> insert into DemoTable values(10, '999.999.999.999'); Query OK, 1 row affected (0.18 sec) mysql> insert into DemoTable values(20, ... Read More

Advertisements