Skip to main content

Posts

Showing posts from September, 2025
 CREATE TABLE employees (emp_id NUMBER PRIMARY KEY, name VARCHAR(20), salary int city VARCHAR(20)); INSERT INTO employees (emp_id, name, salary,city) VALUES (101, INSERT INTO employees (emp_id, name, salary, city) VALUES (102, ABHAY, 55000, GREATER NOIDAL 'Abhishek', 50000, NOIDA) INSERT INTO employees (emp_id, name, salary, city) VALUES (103, JOHN', 53000, ΕΚΟΣ INSERT INTO employees (emp_id, name, salary, city) VALUES (104, 'KHUSHI, 550000, GONDA INSERT INTO employees (emp_id, name, salary,city) VALUES (105, 'AJAY', 500000, DELHI DESC employees; INSERT INTO employees (emp_id, name, salary salary, city) VALUES (106, 'KHUSHI' CH', 530000, LUCKNOW Select from employees;
 Got it 👍 You want the exact SQL commands that you can type and run in your SQL editor (like Oracle SQL, MySQL, or PostgreSQL). I’ll give you both DDL and DML commands properly written. --- 🔹 Data Definition Language (DDL) 1. Create a table CREATE TABLE employees (     emp_id NUMBER PRIMARY KEY,     name VARCHAR2(50),     salary NUMBER(10, 2),     hire_date DATE ); 2. Alter table 👉 Add a new column: ALTER TABLE employees ADD (department_id NUMBER); 👉 Modify column datatype: ALTER TABLE employees MODIFY (name VARCHAR2(100)); 3. Drop table DROP TABLE employees; 4. Truncate table TRUNCATE TABLE employees; 5. Rename table RENAME employees TO staff; --- 🔹 Data Manipulation Language (DML) 1. Insert data INSERT INTO employees (emp_id, name, salary, hire_date) VALUES (101, 'Alice Johnson', 55000, TO_DATE('2022-01-15', 'YYYY-MM-DD')); 2. Select data SELECT name, salary FROM employees WHERE salary > 50000; 3. Update data UPDATE employees SET sa...
 <!DOCTYPE html> <html> <head>     <title>Experiment No:2</title> </head> <body>     <h3>Experiment No:2 Objective: - Write an HTML program to design an entry form of student details.</h3>     <h2><u>STUDENT REGISTRATION FORM</u></h2>     <form>         <!-- Username -->         <label>USERNAME:</label>         <input type="text" name="username"><br><br>         <!-- Password -->         <label>PASSWORD:</label>         <input type="password" name="password"><br><br>         <!-- Address -->         <label>ADDRESS:</label>         <input type="text" name="address" placeholder="address">...
 Experiment No.-1 Objective: Write HTML Program for designing your institute website. Display department information of your institute on the website. <!DOCTYPE html> <html> <head> <title>             College Department Details </title> </head> <body bgcolor="lightgray"> <h1 align="center" style="color: black;">GNIOT, Greater Noida</h1> <h2 align="center" style="color: black;">NAAC A+</h2> <h3 align="center" style="color: black;">Afliated to Abdul Kalam Technical University</h3> <hr>  <h2 align="center" style="color: black;">About College </h2> <p style="font-family:courier";>Greater Noida Institute of Technology (GNIOT) is one of the premier Institutions in the field of Technical and Management Education. It has been formed by Shri Ram Educational Trust, Noida on no profit basis with a...
 #include <stdio.h> #include <stdlib.h> // Merges two subarrays of arr[]. // First subarray is arr[left..mid] // Second subarray is arr[mid+1..right] void merge(int arr[], int left, int mid, int right) {     int i, j, k;     int n1 = mid - left + 1;     int n2 = right - mid;     // Create temporary arrays     int leftArr[n1], rightArr[n2];     // Copy data to temporary arrays     for (i = 0; i < n1; i++)         leftArr[i] = arr[left + i];     for (j = 0; j < n2; j++)         rightArr[j] = arr[mid + 1 + j];     // Merge the temporary arrays back into arr[left..right]     i = 0;     j = 0;     k = left;     while (i < n1 && j < n2) {         if (leftArr[i] <= rightArr[j]) {             arr[k] = leftArr[i];       ...
 #include <stdio.h> void swap(int A[], int i, int j) {     int temp = A[i];     A[i] = A[j];     A[j] = temp; } // PARTITION(A, p, r) int partition(int A[], int p, int r) {     int x = A[r]; // pivot     int i = p - 1;     for (int j = p; j < r; j++) { // FIXED: j < r         if (A[j] <= x) {             i++;             swap(A, i, j);         }     }     swap(A, i + 1, r);     return i + 1; } // QUICKSORT(A, p, r) void quicksort(int A[], int p, int r) {     if (p < r) {         int q = partition(A, p, r);         quicksort(A, p, q - 1);         quicksort(A, q + 1, r);     } } int main() {     int n;     printf("ENTER THE NUMBER OF ELEMENTS: ");     scanf("%d", &n);...
 //quick sort #include <stdio.h> void swap(int A[],int i,int j){ int temp=A[i]; A[i]=A[j]; A[j]=temp; } //PARTITION(A,p,r) int partition(int A[],int p,int r){     int x= A[r]; //pivot     int i=p-1;     for(int j=p;j<=r;j++){         if(A[j]<=x){             i++;             swap(A,i,j);         }     }     swap(A,i+1,r);     return i+1;     //quick sort(A,p,r)     void quicksort(int a[],int p,int r){         if(p<r){             int q=partition(A,p,r);             quicksort(A,p,q-1);             quicksort(A,q+1,r);         }     }     int main(){         int n;         printf("ENTER THE NUMBER OF ELEMEN...