Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create PostGreSQL Script #39

Closed
kirubeltadesse opened this issue Jun 11, 2022 · 8 comments · Fixed by #46
Closed

Create PostGreSQL Script #39

kirubeltadesse opened this issue Jun 11, 2022 · 8 comments · Fixed by #46
Assignees
Milestone

Comments

@kirubeltadesse
Copy link
Collaborator

kirubeltadesse commented Jun 11, 2022

Description

Create a PostgreSQL Script for all the tables and their relationship.

Acceptable Criteria

  • Create a PostgreSQL script (including all the tables and relationships)
  • Create a script to populate fake data

Related Story

Use the table naming and relationship from this #19

Technical Info

There are different ways of creating the script
using lucid diagram
or
you can use the PostgreSQL tool

@kirubeltadesse kirubeltadesse added this to the Alpha Release milestone Jun 11, 2022
@dinaolmelak dinaolmelak self-assigned this Jun 16, 2022
@dinaolmelak
Copy link
Collaborator

Updated the ER_diagram documentation in the following PR #43

@dinaolmelak
Copy link
Collaborator

dinaolmelak commented Jun 19, 2022

I had used Lucidchart create the following diagram based on the ER_Diagram in the documentation. I will be exporting it as a POSTGREsql schema and create the databases.

Image

@dinaolmelak
Copy link
Collaborator

dinaolmelak commented Jun 23, 2022

I just created the database based on the above diagram. The script I exported from Lucid Chart worked fine. However, I had to change the string to VARCHAR, because POSTGREsql does not have string datatype.

Image

@kirubeltadesse
Copy link
Collaborator Author

@dinaolmelak yes, the datatypes are different between language and database language. VARCHAR seems the right type for string you can refer to here for more information.

I believe what is remaining now is creating a script to populate the tables using fake data.

@dinaolmelak
Copy link
Collaborator

For tracking the database table structures and fake data.

/sap/resources/script.sql
/sap/resources/schema.sql

should it be stored like that?

@kirubeltadesse
Copy link
Collaborator Author

Let me ask you this thing where is the /sap folder going to be?

@dinaolmelak
Copy link
Collaborator

dinaolmelak commented Jun 27, 2022

By /sap I meant ./ (i.e ./resources/script.sql and ./resources/schema.sql)

@kirubeltadesse
Copy link
Collaborator Author

kirubeltadesse commented Jun 27, 2022

By /sap I meant ./

I guess for now you can put it inside /sap-web/sapweb/resources/ which means you need to create the resources folder under the already existing sapweb folder.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants