Skip to content

Commit ae003f0

Browse files
Prettier auto-format
1 parent db812ca commit ae003f0

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,11 @@ This repository contains solutions for database-related tasks involving SQL and
1212
## Task Descriptions
1313

1414
### Task 1: SQL Queries on Employee Table
15+
1516
This task involves creating a table `Empl` to store employee details and writing SQL queries to retrieve specific information.
1617

1718
#### Table Structure
19+
1820
- **Empl**:
1921
- `EName`: Employee name
2022
- `Sal`: Salary
@@ -24,6 +26,7 @@ This task involves creating a table `Empl` to store employee details and writing
2426
- Other fields as per standard employee details
2527

2628
#### Queries
29+
2730
1. Display `EName` and `Sal` of employees with a salary greater than or equal to 2200.
2831
2. Display details of employees who are not receiving a commission.
2932
3. Display `EName` and `Sal` of employees whose salary is not in the range of 2500 to 4000.
@@ -32,12 +35,15 @@ This task involves creating a table `Empl` to store employee details and writing
3235
6. Display `EName` of employees whose name ends with "S".
3336

3437
### Task 2: JDBC Program for Employee Data Insertion
38+
3539
This task involves writing a Java program using JDBC to connect to a database and insert employee data into the `Empl` table.
3640

3741
### MongoDB Day 1: Queries on Product Dataset
42+
3843
This task involves writing MongoDB queries on a product dataset provided in JSON format ([product.json](https://github.com/rvsp/database/blob/master/mongodb/product.json)).
3944

4045
#### Queries
46+
4147
1. Retrieve all information about each product.
4248
2. Find products with a price between 400 and 800.
4349
3. Find products with a price not between 400 and 600.
@@ -52,6 +58,7 @@ This task involves writing MongoDB queries on a product dataset provided in JSON
5258
## How to Run
5359

5460
### SQL Queries (Task 1)
61+
5562
1. **Set Up the Database**:
5663
- Create a database (e.g., using MySQL).
5764
- Create the `Empl` table with the appropriate columns.
@@ -60,6 +67,7 @@ This task involves writing MongoDB queries on a product dataset provided in JSON
6067
- Execute the queries to view the results.
6168

6269
### JDBC Program (Task 2)
70+
6371
1. **Set Up the Database**:
6472
- Ensure the `Empl` table exists in your database.
6573
- Configure your JDBC driver (e.g., MySQL Connector/J).
@@ -68,9 +76,11 @@ This task involves writing MongoDB queries on a product dataset provided in JSON
6876
javac Task2.java
6977
java Task2
7078
```
79+
7180
- Ensure your database credentials are updated in the code.
7281

7382
### MongoDB Queries (MongoDB Day 1)
83+
7484
1. **Set Up MongoDB**:
7585
- Install MongoDB and start the MongoDB server.
7686
- Import the `product.json` dataset into a MongoDB collection (e.g., `products`).

0 commit comments

Comments
 (0)