Fendadis John has Published 81 Articles

How to use REPLACE() function with column’s data of MySQL table?

Fendadis John

Fendadis John

Updated on 20-Jun-2020 10:52:56

116 Views

For using it with column’s data we need to provide column name as the argument of REPLACE() function. It can be demonstrated by using ‘Student’ table data as follows −Examplemysql> Select Id, Name, Subject, REPLACE(Subject, 's', ' Science') from Student WHERE Subject = 'Computers'; +------+--------+-----------+-----------------------------------+ | Id   | Name ... Read More

How to add two or more strings in MySQL?

Fendadis John

Fendadis John

Updated on 20-Jun-2020 08:18:58

700 Views

A string function called CONCAT() is used to concatenate two or more strings as a single string in MySQL.SyntaxCONCAT(String1, String2, …, StringN)Here, the arguments of CONCAT functions are the strings which need to be concatenated as a single string.Examplemysql> Select CONCAT('Ram', 'is', 'a', 'good', 'boy') AS Remarks; +---------------+ | ... Read More

How can we use WHERE clause with MySQL INSERT INTO command?

Fendadis John

Fendadis John

Updated on 20-Jun-2020 06:17:22

5K+ Views

We can use conditional insert i.e. WHERE clause with INSERT INTO command in the case of new row insertion. It can be done with following ways −With the help of dummy tableIn this case, we insert the value from dummy table along with some conditions. The syntax can be as ... Read More

What is the difference between MySQL TRUNCATE and DELETE command?

Fendadis John

Fendadis John

Updated on 20-Jun-2020 06:02:15

286 Views

As we know that TRUNCATE will remove all the rows without removing table’s structure from the database. Same work can be done with the help of DELETE command on removing all the rows from the table. But there is a significant difference of re-initialization of PRIMARY KEY AUTO_INCREMENT between both ... Read More

How to get the difference between two arrays in JavaScript?

Fendadis John

Fendadis John

Updated on 18-Jun-2020 08:23:34

188 Views

To get the difference between two arrays in JavaScript, try to run the following code. Here, we’re using some method like split(), indexOf(), sort(), etc to get the elements, which aren’t the same in both the arrays &mnus;ExampleLive Demo           JavaScript Dates         ... Read More

Advantages and Disadvantages of the TCP/IP Model

Fendadis John

Fendadis John

Updated on 17-Jun-2020 12:44:08

22K+ Views

The advantages of TCP/IP protocol suite areIt is an industry–standard model that can be effectively deployed in practical networking problems.It is interoperable, i.e., it allows cross-platform communications among heterogeneous networks.It is an open protocol suite. It is not owned by any particular institute and so can be used by any ... Read More

The Session Layer of OSI Model

Fendadis John

Fendadis John

Updated on 17-Jun-2020 12:41:55

8K+ Views

The session layer (layer 5) is responsible for establishing, managing, synchronizing and terminating sessions between end-user application processes.The main functions of the session layer are as follows −It works as a dialog controller. It allows the systems to communicate in either half-duplex or full-duplex mode of communication.It is responsible for ... Read More

The Network Layer of OSI Model

Fendadis John

Fendadis John

Updated on 17-Jun-2020 12:21:13

3K+ Views

The network layer (Layer 3) controls the source to destination delivery of data packets across multiple hops (nodes). It controls the operation of the subnet.The main functions of the network layer are as follows −It is responsible for routing packets from the source host to the destination host. The routes ... Read More

How to add a YouTube Video to your Website?

Fendadis John

Fendadis John

Updated on 16-Jun-2020 08:20:41

565 Views

To add a YouTube Video to your website, you need to embed it. To embed a video in an HTML page, use the element. The source attribute included the video URL. For the dimensions of the video player, set the width and height of the video appropriately.The Video URL ... Read More

Java variable declaration best practices

Fendadis John

Fendadis John

Updated on 15-Jun-2020 05:46:54

1K+ Views

Following are the best practices while declaring a variable.Variables names should be short or long enough as per the scope. For example, loop counter variable, i is fine whereas employee as a loop variable.Specific words should not be used as equals, compare, data.Use meaningful names which can explain the purpose ... Read More

Advertisements