Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • W Wiki
  • Project information
    • Project information
    • Activity
    • Labels
    • Planning hierarchy
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Excedentes
  • Wiki
  • Wiki
  • Banco de Dados

Banco de Dados · Changes

Page history
Update Banco de Dados authored Apr 06, 2024 by Adriana Anacleto Serpa's avatar Adriana Anacleto Serpa
Hide whitespace changes
Inline Side-by-side
Banco-de-Dados.md
View page @ 1797a5b1
...@@ -27,7 +27,7 @@ Optamos por criar um banco de dados relacional, tendo em vista que o banco possu ...@@ -27,7 +27,7 @@ Optamos por criar um banco de dados relacional, tendo em vista que o banco possu
### Modelo ER ### Modelo ER
![image](uploads/2dbad2c28570b026c46d7e174d910646/image.png) ![image](uploads/c2b8ec891f0bc362bfa81b228efca390/image.png)
Para ver com mais detalhes sobre este modelo, clique [aqui](https://dbdiagram.io/d/Copy-of-Untitled-Diagram-660c745903593b6b61017b26) Para ver com mais detalhes sobre este modelo, clique [aqui](https://dbdiagram.io/d/Copy-of-Untitled-Diagram-660c745903593b6b61017b26)
...@@ -38,10 +38,12 @@ Table clientes { ...@@ -38,10 +38,12 @@ Table clientes {
id integer [increment, primary key] id integer [increment, primary key]
tipo_cliente enum('Pessoa Fisica', 'Pessoa Juridica') [not null] tipo_cliente enum('Pessoa Fisica', 'Pessoa Juridica') [not null]
nome varchar2 [not null] nome varchar2 [not null]
cpf_cnpj varchar2 [not null, primary key] cpf_cnpj varchar2 [not null]
email varchar2 [not null] email varchar2 [not null]
senha varchar2 [not null] senha varchar2 [not null]
createdAt date [not null] createdAt date [not null]
updatedAt date [not null]
deletedAt date
} }
``` ```
...@@ -52,6 +54,8 @@ Table pedidos { ...@@ -52,6 +54,8 @@ Table pedidos {
valor_total double [not null] valor_total double [not null]
data date [not null] data date [not null]
createdAt date [not null] createdAt date [not null]
updatedAt date [not null]
deletedAt date
} }
``` ```
...@@ -69,7 +73,9 @@ Table alimentos { ...@@ -69,7 +73,9 @@ Table alimentos {
foto varchar2 foto varchar2
cod_barras varchar2 cod_barras varchar2
createdAt date [not null] createdAt date [not null]
deleted bool updatedAt date [not null]
deletedAt date
deleted bool [not null]
} }
``` ```
...@@ -82,6 +88,9 @@ Table item_pedido { ...@@ -82,6 +88,9 @@ Table item_pedido {
quantidade integer [not null] quantidade integer [not null]
preco_unitario double [not null] preco_unitario double [not null]
createdAt date [not null] createdAt date [not null]
updatedAt date [not null]
deletedAt date
} }
``` ```
...@@ -89,12 +98,14 @@ Table item_pedido { ...@@ -89,12 +98,14 @@ Table item_pedido {
Table empresas { Table empresas {
id integer [increment, primary key] id integer [increment, primary key]
nome varchar2 [not null] nome varchar2 [not null]
cnpj varchar2 [not null, primary key] cnpj varchar2 [not null]
email varchar2 [not null] email varchar2 [not null]
senha varchar2 [not null] senha varchar2 [not null]
horario_comercial varchar2 [not null] horario_comercial varchar2 [not null]
id_endereco integer [not null] id_endereco integer [not null]
createdAt date [not null] createdAt date [not null]
updatedAt date [not null]
deletedAt date
} }
``` ```
...@@ -110,6 +121,8 @@ Table enderecos { ...@@ -110,6 +121,8 @@ Table enderecos {
latitude double [not null] latitude double [not null]
longitude double [not null] longitude double [not null]
createdAt date [not null] createdAt date [not null]
updatedAt date [not null]
deletedAt date
} }
``` ```
...@@ -122,6 +135,7 @@ Ref: item_pedido.id_empresa > empresas.id ...@@ -122,6 +135,7 @@ Ref: item_pedido.id_empresa > empresas.id
Ref: alimentos.id_empresa > empresas.id Ref: alimentos.id_empresa > empresas.id
Ref: item_pedido.id_pedido > pedidos.id Ref: item_pedido.id_pedido > pedidos.id
Ref: item_pedido.id_alimento > alimentos.id_alimento Ref: item_pedido.id_alimento > alimentos.id_alimento
``` ```
......
Clone repository
  • Banco de Dados
  • arquitetura
  • codigo
  • configuracao
  • design_mockups
  • escopo
  • gerencia
  • Home
  • materiais_de_estudo
  • processo
  • requisitos
  • sprints