ALTER TABLE Projects
ADD PRIMARY KEY (P_id);
Explanation:
The ALTER TABLE statement modifies the structure of the table.
The ADD PRIMARY KEY command assigns the primary key constraint to the P\_id column, ensuring that it uniquely identifies each record in the table.
Query (ii): Change the language to Python for the project with ID P002.
UPDATE Projects
SET Language = "Python"
WHERE P_id = "P002";
Explanation:
The UPDATE statement modifies existing records in the table.
The SET clause updates the Language column to "Python" for the row where the P\_id is "P002".
The WHERE clause ensures that only the specified row is updated.
Query (iii): Delete the table Projects along with its data.
DROP TABLE Projects;
Explanation:
The DROP TABLE statement permanently deletes the table Projects from the database, including all its data and structure.
This action cannot be undone, so use it with caution.
The SELECT statement when combined with \(\_\_\_\_\_\_\) clause, returns records without repetition.
print(16 * 5 / 4 * 2 / 5 - 8)
myStr[:4] extracts the first 4 characters, which are "MISS".myStr[-5:] extracts the last 5 characters, which are "SIPPI"."#" in between, resulting in "MISS#SIPPI".In SQL, the aggregate function which will display the cardinality of the table is \(\_\_\_\_\_\).
print(16 * 5 / 4 * 2 / 5 - 8)
a = 20
def convert(a):
b = 20
a = a + b
convert(10)
print(a)
Select the correct output from the given options:
Fill in the blank:
\(\_\_\_\_\_\_\_\_\) is a set of rules that needs to be followed by the communicating parties in order to have a successful and reliable data communication over a network.