Pawandeep Kaur has Published 35 Answers

How can you perform full join on two tables using MySQL in Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:53:59

We can join two tables in SQL based on a common column between them or based on some specified condition. There are different types of JOIN available to join two SQL tables.Here, we will discuss about the FULL join on two tables. In the FULL JOIN, all the records from ... Read More

How can you perform right join on two tables using MySQL in Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:51:42

We can join two tables in SQL based on a common column between them or based on some specified condition. There are different types of JOIN available to join two SQL tables.Here, we will discuss about the RIGHT join on two tables.In the RIGHT JOIN, all the records from the ... Read More

How can you perform left join on two tables using MySQL in Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:49:45

We can join two tables in SQL based on a common column between them or based on some specified condition. There are different types of JOIN available to join two SQL tables.Here, we will discuss about the LEFT join on two tables. The tables can be joined using the LEFT ... Read More

How can you perform inner join on two tables using MySQL in Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:49:08

We can join two tables in SQL based on a common column between them or based on some specified condition. There are different types of JOIN available to join two SQL tables.Here, we will discuss about the inner join on two tables.JOIN and INNER JOIN both work the same way. ... Read More

How can you avoid getting an error if you are deleting a table which does not exist using Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:46:49

There might be a scenario where you might be deleting a table which actually does not exist in your database. It is possible that while executing the command to delete a table from the database, we may give wrong name of the table which doesnot exist in our database. The ... Read More

How can you retrieve a particular number of records from a table starting from some specified row number in Python MySQL?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:38:52

Most frequently, we do not require to select all the rows from the table. We may at times need to retrieve a particular number of records from a table, starting from some specific index. Suppose, we have a table of 10 records. We need to select 5 rows from the ... Read More

How can you update certain values in a table in MySQL using Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:38:34

The data in the table may be outdated and we may require to change the data after some time. Suppose, we have a table of Students and one of the students have changed their address. We require to change the address of the student in the database to avoid any ... Read More

How can you delete a table from a database in MySQL Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:38:16

It can be at times required to delete the whole table from the database. It is bad use of the storage to keep the unwanted data in the database. Suppose, we have a table named “Employees” in our database and due to some reasons , we do not require this ... Read More

Explain the use of SELECT DISTINCT statement in MySQL using Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:37:56

Inside SQL tables, columns usually contain duplicate values. We may sometimes need to get only the distinct or different values present in a column in our table since the duplicate values makes it difficult for us to analyze the results returned by the query.Example:Suppose, we have a table named Customers ... Read More

How can you delete a record from a table using MySQL in Python?

Pawandeep Kaur

Pawandeep Kaur

Updated on 10-Jun-2021 12:37:21

We may at times need to delete certain rows from a table. Suppose, we have a table of details of students in the class. It is possible that one of the students left the class and hence, we do not require the details of that particular student. Hence, we need ... Read More

Advertisements