---
title: Database Systems Pre-Lab 2
---
<h1 style='border: none'><center>Database Systems Pre-Lab 2</center></h1>
<h2 style='border: none'><center>RelaX - relational algebra calculator</center></h2>
<h5><center>The Islamic University of Gaza<br>Engineering Faculty<br>Department of Computer Engineering</center></h5>
<h6>Authors: Usama R. Al Zayan & Rasha E. Kahil<span style="float:right">2023/02/06</span></h6>
---
## Expecteed outcomes
1. Review The Relational Algebra Operations.
2. Install lab’s tool on student’s device locally.
## Lab 2: Time and Plan
| Tasks | Timing |
| -------- | -------- |
| Quiz 1 | 10 min |
| Task 1 | 35 min |
| Task 2 | 15 min |
| Task 3 | 15 min |
| Task 4 | 20 min |
## Introduction
<p style="text-align:justify">
In this Pre-lab, we are going to talk about how to run RelaX (relational algebra calculator) locally in your device. You can run online
<a href="http://clotho.uom.gr/relax/calc.htm">RelaX - relational algebra calculator</a> But We are not sure if there is internet in the lab room, so please make sure the site is running locally before attending the lab.</p>
## Student’s To Do list:
1. Read Section 2.6 (The Relational Algebra) in the Textbook.
2. Install node.js (v12.16.0).
3. Install Yarn.
4. Install Git.
5. Run RelaX - relational algebra calculator.
## Quiz in Lab 02
A quiz will be given at the beginning of lab 02 in Section 2.6 (The Relational Algebra).
## Install node.js (v12.16.0)
* Download this installation file [node-v12.16.0-x64](https://nodejs.org/download/release/v12.16.0/node-v12.16.0-x64.msi).
* Open the downloaded setup file, don’t think, and keep progressing with `Next`.
## Install Yarn
* Open cmd as Administrator.
<center>

</center>
* Run this command `npm i yarn`.

## Install Git
* Go to [Git - Downloading Package](https://git-scm.com/downloads).
* Open setup file, keep going with `next`.


## How to Run RelaX - relational algebra calculator
1. Create new folder, name it `Lab2`, and open it.
2. Click right on any place inside `Lab2` folder, and click `Git Bash Here`.

3. Clone relax repository as follows: `git clone https://github.com/dbis-uibk/relax.git`.

4. Download this file [uibk.txt](https://drive.google.com/file/d/1YEP4B7EsKQPIO0_Uy4abhPRawISu4-Lt/view?usp=sharing).
5. Replace `relax\src\calc2\data\uibk.txt` file with the downloaded `uibk.txt` file.
6. Try to run this command `yarn --version` if yarn command not found, run `npm install --global yarn` and try again.

7. Change directory to the new inner relax folder (`cd relax` ).
<!-- 8. Run this command `yarn add node-sass`.

-->
8. Run this command `yarn install`.

9. Run this command `yarn serve`.
<!-- 11. If you face this error `Error: error:0308010C:digital envelope routines::unsupported`, run this command `export NODE_OPTIONS=--openssl-legacy-provider` and try to run `yarn serve` again.
-->

10. Now, go to your browser, paste this URL, `http://localhost:8088/` and Click `Get Started`.


11. To stop the site, press Ctrl + C in Git Bash.
12. To run the site again open Git Bash in Relax folder and run this command `yarn serve`.
###### tags: `Database Systems` `Pre-Lab` `IUG` `Computer Engineering`
<center>End Of Pre-Lab 2</center>