hecha entrega para analisis3
This commit is contained in:
594
Analisis III/entregaanalisis.html
Normal file
594
Analisis III/entregaanalisis.html
Normal file
@@ -0,0 +1,594 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||
<head>
|
||||
<!-- 2024-07-07 dom 19:42 -->
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>Analisis 3 - Entrega</title>
|
||||
<meta name="author" content="Grupo 1" />
|
||||
<meta name="generator" content="Org Mode" />
|
||||
<style type="text/css">
|
||||
#content { max-width: 60em; margin: auto; }
|
||||
.title { text-align: center;
|
||||
margin-bottom: .2em; }
|
||||
.subtitle { text-align: center;
|
||||
font-size: medium;
|
||||
font-weight: bold;
|
||||
margin-top:0; }
|
||||
.todo { font-family: monospace; color: red; }
|
||||
.done { font-family: monospace; color: green; }
|
||||
.priority { font-family: monospace; color: orange; }
|
||||
.tag { background-color: #eee; font-family: monospace;
|
||||
padding: 2px; font-size: 80%; font-weight: normal; }
|
||||
.timestamp { color: #bebebe; }
|
||||
.timestamp-kwd { color: #5f9ea0; }
|
||||
.org-right { margin-left: auto; margin-right: 0px; text-align: right; }
|
||||
.org-left { margin-left: 0px; margin-right: auto; text-align: left; }
|
||||
.org-center { margin-left: auto; margin-right: auto; text-align: center; }
|
||||
.underline { text-decoration: underline; }
|
||||
#postamble p, #preamble p { font-size: 90%; margin: .2em; }
|
||||
p.verse { margin-left: 3%; }
|
||||
pre {
|
||||
border: 1px solid #e6e6e6;
|
||||
border-radius: 3px;
|
||||
background-color: #f2f2f2;
|
||||
padding: 8pt;
|
||||
font-family: monospace;
|
||||
overflow: auto;
|
||||
margin: 1.2em;
|
||||
}
|
||||
pre.src {
|
||||
position: relative;
|
||||
overflow: auto;
|
||||
}
|
||||
pre.src:before {
|
||||
display: none;
|
||||
position: absolute;
|
||||
top: -8px;
|
||||
right: 12px;
|
||||
padding: 3px;
|
||||
color: #555;
|
||||
background-color: #f2f2f299;
|
||||
}
|
||||
pre.src:hover:before { display: inline; margin-top: 14px;}
|
||||
/* Languages per Org manual */
|
||||
pre.src-asymptote:before { content: 'Asymptote'; }
|
||||
pre.src-awk:before { content: 'Awk'; }
|
||||
pre.src-authinfo::before { content: 'Authinfo'; }
|
||||
pre.src-C:before { content: 'C'; }
|
||||
/* pre.src-C++ doesn't work in CSS */
|
||||
pre.src-clojure:before { content: 'Clojure'; }
|
||||
pre.src-css:before { content: 'CSS'; }
|
||||
pre.src-D:before { content: 'D'; }
|
||||
pre.src-ditaa:before { content: 'ditaa'; }
|
||||
pre.src-dot:before { content: 'Graphviz'; }
|
||||
pre.src-calc:before { content: 'Emacs Calc'; }
|
||||
pre.src-emacs-lisp:before { content: 'Emacs Lisp'; }
|
||||
pre.src-fortran:before { content: 'Fortran'; }
|
||||
pre.src-gnuplot:before { content: 'gnuplot'; }
|
||||
pre.src-haskell:before { content: 'Haskell'; }
|
||||
pre.src-hledger:before { content: 'hledger'; }
|
||||
pre.src-java:before { content: 'Java'; }
|
||||
pre.src-js:before { content: 'Javascript'; }
|
||||
pre.src-latex:before { content: 'LaTeX'; }
|
||||
pre.src-ledger:before { content: 'Ledger'; }
|
||||
pre.src-lisp:before { content: 'Lisp'; }
|
||||
pre.src-lilypond:before { content: 'Lilypond'; }
|
||||
pre.src-lua:before { content: 'Lua'; }
|
||||
pre.src-matlab:before { content: 'MATLAB'; }
|
||||
pre.src-mscgen:before { content: 'Mscgen'; }
|
||||
pre.src-ocaml:before { content: 'Objective Caml'; }
|
||||
pre.src-octave:before { content: 'Octave'; }
|
||||
pre.src-org:before { content: 'Org mode'; }
|
||||
pre.src-oz:before { content: 'OZ'; }
|
||||
pre.src-plantuml:before { content: 'Plantuml'; }
|
||||
pre.src-processing:before { content: 'Processing.js'; }
|
||||
pre.src-python:before { content: 'Python'; }
|
||||
pre.src-R:before { content: 'R'; }
|
||||
pre.src-ruby:before { content: 'Ruby'; }
|
||||
pre.src-sass:before { content: 'Sass'; }
|
||||
pre.src-scheme:before { content: 'Scheme'; }
|
||||
pre.src-screen:before { content: 'Gnu Screen'; }
|
||||
pre.src-sed:before { content: 'Sed'; }
|
||||
pre.src-sh:before { content: 'shell'; }
|
||||
pre.src-sql:before { content: 'SQL'; }
|
||||
pre.src-sqlite:before { content: 'SQLite'; }
|
||||
/* additional languages in org.el's org-babel-load-languages alist */
|
||||
pre.src-forth:before { content: 'Forth'; }
|
||||
pre.src-io:before { content: 'IO'; }
|
||||
pre.src-J:before { content: 'J'; }
|
||||
pre.src-makefile:before { content: 'Makefile'; }
|
||||
pre.src-maxima:before { content: 'Maxima'; }
|
||||
pre.src-perl:before { content: 'Perl'; }
|
||||
pre.src-picolisp:before { content: 'Pico Lisp'; }
|
||||
pre.src-scala:before { content: 'Scala'; }
|
||||
pre.src-shell:before { content: 'Shell Script'; }
|
||||
pre.src-ebnf2ps:before { content: 'ebfn2ps'; }
|
||||
/* additional language identifiers per "defun org-babel-execute"
|
||||
in ob-*.el */
|
||||
pre.src-cpp:before { content: 'C++'; }
|
||||
pre.src-abc:before { content: 'ABC'; }
|
||||
pre.src-coq:before { content: 'Coq'; }
|
||||
pre.src-groovy:before { content: 'Groovy'; }
|
||||
/* additional language identifiers from org-babel-shell-names in
|
||||
ob-shell.el: ob-shell is the only babel language using a lambda to put
|
||||
the execution function name together. */
|
||||
pre.src-bash:before { content: 'bash'; }
|
||||
pre.src-csh:before { content: 'csh'; }
|
||||
pre.src-ash:before { content: 'ash'; }
|
||||
pre.src-dash:before { content: 'dash'; }
|
||||
pre.src-ksh:before { content: 'ksh'; }
|
||||
pre.src-mksh:before { content: 'mksh'; }
|
||||
pre.src-posh:before { content: 'posh'; }
|
||||
/* Additional Emacs modes also supported by the LaTeX listings package */
|
||||
pre.src-ada:before { content: 'Ada'; }
|
||||
pre.src-asm:before { content: 'Assembler'; }
|
||||
pre.src-caml:before { content: 'Caml'; }
|
||||
pre.src-delphi:before { content: 'Delphi'; }
|
||||
pre.src-html:before { content: 'HTML'; }
|
||||
pre.src-idl:before { content: 'IDL'; }
|
||||
pre.src-mercury:before { content: 'Mercury'; }
|
||||
pre.src-metapost:before { content: 'MetaPost'; }
|
||||
pre.src-modula-2:before { content: 'Modula-2'; }
|
||||
pre.src-pascal:before { content: 'Pascal'; }
|
||||
pre.src-ps:before { content: 'PostScript'; }
|
||||
pre.src-prolog:before { content: 'Prolog'; }
|
||||
pre.src-simula:before { content: 'Simula'; }
|
||||
pre.src-tcl:before { content: 'tcl'; }
|
||||
pre.src-tex:before { content: 'TeX'; }
|
||||
pre.src-plain-tex:before { content: 'Plain TeX'; }
|
||||
pre.src-verilog:before { content: 'Verilog'; }
|
||||
pre.src-vhdl:before { content: 'VHDL'; }
|
||||
pre.src-xml:before { content: 'XML'; }
|
||||
pre.src-nxml:before { content: 'XML'; }
|
||||
/* add a generic configuration mode; LaTeX export needs an additional
|
||||
(add-to-list 'org-latex-listings-langs '(conf " ")) in .emacs */
|
||||
pre.src-conf:before { content: 'Configuration File'; }
|
||||
|
||||
table { border-collapse:collapse; }
|
||||
caption.t-above { caption-side: top; }
|
||||
caption.t-bottom { caption-side: bottom; }
|
||||
td, th { vertical-align:top; }
|
||||
th.org-right { text-align: center; }
|
||||
th.org-left { text-align: center; }
|
||||
th.org-center { text-align: center; }
|
||||
td.org-right { text-align: right; }
|
||||
td.org-left { text-align: left; }
|
||||
td.org-center { text-align: center; }
|
||||
dt { font-weight: bold; }
|
||||
.footpara { display: inline; }
|
||||
.footdef { margin-bottom: 1em; }
|
||||
.figure { padding: 1em; }
|
||||
.figure p { text-align: center; }
|
||||
.equation-container {
|
||||
display: table;
|
||||
text-align: center;
|
||||
width: 100%;
|
||||
}
|
||||
.equation {
|
||||
vertical-align: middle;
|
||||
}
|
||||
.equation-label {
|
||||
display: table-cell;
|
||||
text-align: right;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.inlinetask {
|
||||
padding: 10px;
|
||||
border: 2px solid gray;
|
||||
margin: 10px;
|
||||
background: #ffffcc;
|
||||
}
|
||||
#org-div-home-and-up
|
||||
{ text-align: right; font-size: 70%; white-space: nowrap; }
|
||||
textarea { overflow-x: auto; }
|
||||
.linenr { font-size: smaller }
|
||||
.code-highlighted { background-color: #ffff00; }
|
||||
.org-info-js_info-navigation { border-style: none; }
|
||||
#org-info-js_console-label
|
||||
{ font-size: 10px; font-weight: bold; white-space: nowrap; }
|
||||
.org-info-js_search-highlight
|
||||
{ background-color: #ffff00; color: #000000; font-weight: bold; }
|
||||
.org-svg { }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="content" class="content">
|
||||
<h1 class="title">Analisis 3 - Entrega</h1>
|
||||
<div id="table-of-contents" role="doc-toc">
|
||||
<h2>Table of Contents</h2>
|
||||
<div id="text-table-of-contents" role="doc-toc">
|
||||
<ul>
|
||||
<li><a href="#org6cb7cfa">1. Narrativa</a></li>
|
||||
<li><a href="#orgfa6493a">2. Analisis de Entidad-Relacion</a></li>
|
||||
<li><a href="#org91a1d5a">3. Entidades Identificadas</a></li>
|
||||
<li><a href="#orgb6fddc0">4. Codigo Sql</a></li>
|
||||
<li><a href="#org91c8dba">5. Diagrama Pata de gallo</a></li>
|
||||
<li><a href="#org377f853">6. Marco Teorico Normalizacion</a>
|
||||
<ul>
|
||||
<li><a href="#orgb19d55f">6.1. Primera Forma Normal (1FN)</a></li>
|
||||
<li><a href="#org411a8e0">6.2. Segunda Forma Normal (2FN)</a></li>
|
||||
<li><a href="#orgb6f84dd">6.3. Tercera Forma Normal (3FN)</a></li>
|
||||
<li><a href="#orgb55c926">6.4. Cuarta Forma Normal (4FN)</a></li>
|
||||
<li><a href="#org2c3b7d8">6.5. Quinta Forma Normal (5FN)</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a href="#orgf49dd95">7. Diagrama de clases</a></li>
|
||||
<li><a href="#orgef2db9d">8. Diagrama Entidad-Relacion</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org6cb7cfa" class="outline-2">
|
||||
<h2 id="org6cb7cfa"><span class="section-number-2">1.</span> Narrativa</h2>
|
||||
<div class="outline-text-2" id="text-1">
|
||||
<p>
|
||||
La creación de este sistema surge como una herramienta que pueda servir de intermediario para que los usuarios puedan contactar de manera rápida y efectiva con distintos profesionales que se encarguen de brindar servicios, tales como: Electricista, gasista, plomero, etc.
|
||||
En primera medida permite el registro de los profesionales en la aplicación, donde podrán dejar su currículum, que tipo de servicios se encarga de proveer, disponibilidad horaria, tarifa, de esta manera será mucho más fácil encontrar de forma inmediata los servicios que requiere el cliente, el profesional deberá entregar los certificados necesarios para avalar sus habilidades en el tipo de servicio que brindará.
|
||||
El administrador del sistema podrá gestionar los servicios disponibles dentro de la aplicación, podrá agregar, modificar y eliminar servicios. Las publicaciones van a estar basadas única y exclusivamente en estos servicios.
|
||||
El profesional tendrá acceso a un sistema de tareas donde deberá realizar una cierta cantidad de trabajos y ganará nivel, el cual le permitirá ser recomendado en trabajos futuros.
|
||||
El profesional podrá realizar publicaciones especificando el servicio, la ubicación de trabajo y la tarifa.
|
||||
Luego se podrán registrar los propios usuarios, que tendrán una cuenta dentro del sistema que le permitirá acceder a todas sus funcionalidades, el registro podrá ser con una cuenta en el mismo sistema o mediante una red social, además podrán eliminar o modificar los datos de su cuenta en caso de algún error o imprevisto.
|
||||
El sistema cuenta con un servicio de filtrado, donde el cliente podrá elegir que tipo de servicio está buscando, que tarifas es capaz de manejar y en qué horarios podría acordar una cita, de esta manera la aplicación se torna mucho más flexible y eficiente, donde se le otorga un gran poder de elección al usuario.
|
||||
Una vez que selecciona el tipo de servicio aparecerán todos las publicaciones que se encuentran disponibles en ese momento, donde podrá observar de los mismos sus trabajos previos, calificaciones y comentarios de opinión.. Además, la aplicación cuenta con un sistema de mensajería interno que permite la comunicación directa y en tiempo real con los profesionales. Otra manera de contactarlos es mediante un sistema donde el usuario podrá ponerse en “Alerta”, qué hará saber a los profesionales que necesita un servicio en especial, de ésta manera será visto en el mapa y se le pondrá enviar distintas propuestas de trabajos con su tarifa, es así que el cliente tendrá una lista con los trabajos que le proponen sobre cierto servicio social y elegir el que le sea más conveniente, ya sea por tarifa o experiencia del trabajador.
|
||||
Una vez que el usuario selecciona la publicación que desea, se genera un precontrato, que requerirá de la confirmación por parte del profesional para transformarse en contrato.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Los usuarios deberán pagar la cita dentro de la aplicación, ya sea con tarjeta o depósito en efectivo, es aquí donde el sistema cobra un plus sobre la tarifa original del profesional.
|
||||
El sistema se encargará de retener el dinero por un tiempo determinado, esto lo hará con la finalidad de prever posibles reclamos por parte de los clientes antes situaciones como: Servicio de mala calidad, mal trato por parte del profesional, no cumplió con sus expectativas,etc.
|
||||
Es así como el usuario tendrá un tiempo específico para solicitar la devolución del dinero de manera exitosa, en caso contrario el pago será realizado al profesional y quedará fuera del alcance del sistema poder satisfacer las necesidades del cliente con respecto a la solicitud de reclamo.
|
||||
Cada día llegará un recordatorio al cliente de las citas que tiene pendiente junto con los datos tales como: tarifa, tipo de servicio, hora, fecha, lugar, de ésta manera el usuario podrá saber cuáles son las citas que tiene pendientes.
|
||||
Una vez culminado el servicio por parte del profesional, el usuario podrá evaluar su experiencia tanto con la aplicación como con los servicios brindados, podrá dejar comentarios que ayuden a otros clientes en el uso de este sistema.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgfa6493a" class="outline-2">
|
||||
<h2 id="orgfa6493a"><span class="section-number-2">2.</span> Analisis de Entidad-Relacion</h2>
|
||||
<div class="outline-text-2" id="text-2">
|
||||
<p>
|
||||
En este apartado se realizará un análisis exhaustivo sobre las distintas entidades que forman parte de la aplicación que
|
||||
se encarga de proveer servicios esenciales, haremos un esquema con las entidades que intervienen en el mismo, así
|
||||
como también las relaciones que existen entre las mismas. Además, haremos visiones de contexto que nos permitan
|
||||
comprender de una manera mucho más sencilla que relaciones existen entre las distintas entidades y observar el
|
||||
sistema desde otro punto de vista.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org91a1d5a" class="outline-2">
|
||||
<h2 id="org91a1d5a"><span class="section-number-2">3.</span> Entidades Identificadas</h2>
|
||||
<div class="outline-text-2" id="text-3">
|
||||
<ol class="org-ol">
|
||||
<li>Profesionales</li>
|
||||
<li>Administradores</li>
|
||||
<li>Usuarios</li>
|
||||
<li>Reseñas</li>
|
||||
<li>Servicios-Publicacion</li>
|
||||
<li>Estado</li>
|
||||
<li>Formas-Pago</li>
|
||||
<li>Pre-Contratos</li>
|
||||
<li>Pre-Contratos-Confirmaciones</li>
|
||||
<li>Comprobantes-De-Pago</li>
|
||||
<li>Contratos</li>
|
||||
<li>Recordatorios</li>
|
||||
<li>Publicaciones</li>
|
||||
<li>Permisos</li>
|
||||
<li>Administradores-Permisos</li>
|
||||
<li>Cambios</li>
|
||||
<li>Administradores-Cambios</li>
|
||||
<li>Categorias</li>
|
||||
|
||||
<li>Se sabe que para los profesionales tendrán un código único que los identifique, los mismos podrán realizar muchas publicaciones al mismo tiempo, además tendrán un email y teléfonos únicos de contacto, tendrán la posibilidad de confirmar o rechazar los pre-Contratos generados por los usuarios interesados en dicha publicación.</li>
|
||||
<li>Los usuarios tendrán un DNI, que los identificará inequívocamente del resto, también contarán con un email y teléfono de contacto únicos.</li>
|
||||
<li>Las categorías contarán con una descripción única, que permitirán saber de que tipo es el servicio que se brindará.</li>
|
||||
<li>El administrador, tendrá un Número que lo identificará, además contará con varios permisos, los cuales le permitirán realizar distintos cambios dentro del sistema.</li>
|
||||
<li>Para los permisos se saben que cuentan con una descripción única que detallará que acción podrá realizar el administrador que posea el mismo.</li>
|
||||
<li>Se sabe que las publicaciones se basarán en un único servicio, contarán con una descripción, fecha de inicio, estado actual, que profesional realizó dicha publicación y horas estimadas de trabajo por parte del profesional.</li>
|
||||
<li>Se sabe de la reseña que tendrá un comentario, los usuarios podrán realizar cuantas reseñas deseen, pero la reseña se puede hacer por un solo usuario, sobre una publicación específica.</li>
|
||||
<li>Los comprobantes de pago, contarán con un código, el método por el cual se realizó el mismo, y además la publicación que se pagó con dicho comprobante.</li>
|
||||
<li>Los precontratos contarán con un código único, además los usuarios podrán estar involucrados en varios PreContratos, así como también los profesionales que se encuentran en la publicación en la cual se basa el pre-Contrato.</li>
|
||||
<li>Los contratos, contarán con un código único, el usuario y publicación, el profesional, el comprobante de pago de dicho contrato y el pre-contrato en el cual se basa el mismo.</li>
|
||||
<li>Los reclamos tendrán un código único, el usuario que lo realiza, de que contrato, el motivo, la fecha y el estado de este reclamo. Visiones de Contexto</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgb6fddc0" class="outline-2">
|
||||
<h2 id="orgb6fddc0"><span class="section-number-2">4.</span> Codigo Sql</h2>
|
||||
<div class="outline-text-2" id="text-4">
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-sql"> <span style="color: #ff2afc; font-weight: bold;">create</span> database App_Servicios;
|
||||
use App_Servicios;
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Formas_Pago</span>(
|
||||
Num_Forma_Pago <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
descripcion nvarchar (<span style="color: #ffd400; font-weight: bold;">40</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Beneficios nvarchar (<span style="color: #ffd400; font-weight: bold;">30</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Categorias_Servicios</span>(
|
||||
Num_Categoria <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Nombre nvarchar (<span style="color: #ffd400; font-weight: bold;">20</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Descripcion nvarchar (<span style="color: #ffd400; font-weight: bold;">30</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Permisos</span>(
|
||||
Num_Permiso <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Descripcion nvarchar (<span style="color: #ffd400; font-weight: bold;">30</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Estados</span>(
|
||||
Num_Estado <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Descripcion nvarchar (<span style="color: #ffd400; font-weight: bold;">30</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Profesionales</span>(
|
||||
Num_Profesional <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Dni <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Email nvarchar (<span style="color: #ffd400; font-weight: bold;">30</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Telefono <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Nombre nvarchar (<span style="color: #ffd400; font-weight: bold;">25</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Apellido nvarchar (<span style="color: #ffd400; font-weight: bold;">25</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Credenciales</span>(
|
||||
Num_credencial <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Titulo nvarchar (<span style="color: #ffd400; font-weight: bold;">50</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Imagen_Titulo nvarchar (<span style="color: #ffd400; font-weight: bold;">150</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Especializacion nvarchar (<span style="color: #ffd400; font-weight: bold;">40</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Num_Profesional <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Profesionales (Num_Profesional),
|
||||
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Usuarios</span>(
|
||||
Num_Usuario <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Nombre nvarchar (<span style="color: #ffd400; font-weight: bold;">25</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Apellido nvarchar (<span style="color: #ffd400; font-weight: bold;">25</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Email nvarchar (<span style="color: #ffd400; font-weight: bold;">30</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Telefono <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Administradores</span>(
|
||||
Num_Administrador <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Dni <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Nombre nvarchar (<span style="color: #ffd400; font-weight: bold;">25</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Apellido nvarchar (<span style="color: #ffd400; font-weight: bold;">25</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Email nvarchar (<span style="color: #ffd400; font-weight: bold;">30</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Telefono <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Administradores_Permisos</span>(
|
||||
<span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span> (Num_Administrador,Num_Permiso),
|
||||
Num_Administrador <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Administradores (Num_Administrador),
|
||||
Num_Permiso <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Permisos (Num_Permiso),
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Servicios_Publicaciones</span>(
|
||||
Num_Servicio <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Descripcion nvarchar (<span style="color: #ffd400; font-weight: bold;">50</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Num_Categoria <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Categorias_Servicios (Num_Categoria)
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Publicaciones</span>(
|
||||
Num_Publicacion <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
<span style="color: #ff2afc; font-weight: bold;">unique</span> (Num_Profesional,Num_Servicio),
|
||||
Num_Profesional <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Profesionales (Num_Profesional),
|
||||
Num_Servicio <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Servicios_Publicaciones (Num_Servicio),
|
||||
Fecha_Publicacion_Inicial datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Tarifa <span style="color: #ffd400;">decimal</span> (<span style="color: #ffd400; font-weight: bold;">5</span>,<span style="color: #ffd400; font-weight: bold;">2</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Horas_De_Trabajo <span style="color: #ffd400;">decimal</span> (<span style="color: #ffd400; font-weight: bold;">2</span>,<span style="color: #ffd400; font-weight: bold;">1</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Reseñas</span>(
|
||||
Num_Reseña <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Calificacion <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
<span style="color: #ff2afc; font-weight: bold;">unique</span> (Num_Usuario,Num_Publicacion),
|
||||
Num_Usuario <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Usuarios (Num_Usuario),
|
||||
Comentario nvarchar (<span style="color: #ffd400; font-weight: bold;">100</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Num_Publicacion <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Publicaciones (Num_Publicacion),
|
||||
Fecha_Reseña datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Comprobantes_Pago</span>(
|
||||
Num_Comprobante <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Num_Forma_Pago <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Formas_Pago (Num_Forma_Pago),
|
||||
Fecha_Emision datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Pre_Contratos</span>(
|
||||
Num_Pre_Contrato <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Num_Usuario <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Usuarios (Num_Usuario),
|
||||
Num_Publicacion <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Publicaciones (Num_Publicacion),
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Pre_Contratos_Confirmaciones</span>(
|
||||
Cod_Aceptacion <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Num_Precontrato <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Pre_Contratos (Num_Pre_Contrato),
|
||||
Num_Estado <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Estados (Num_Estado),
|
||||
Fecha_Aceptacion datetime,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Administradores_Cambios</span>(
|
||||
Num_Administrador <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Administradores (Num_Administrador),
|
||||
Cambio_Realizado nvarchar (<span style="color: #ffd400; font-weight: bold;">200</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Fecha_Cambio datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Contratos</span>(
|
||||
Num_Contrato <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Num_Comprobante <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Comprobantes_Pago (Num_Comprobante) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Num_Profesional <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Profesionales (Num_Profesional),
|
||||
Num_Usuario <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Usuarios (Num_Usuario),
|
||||
Num_Publicacion <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Publicaciones (Num_Publicacion),
|
||||
|
||||
<span style="color: #ffd400; font-weight: bold;">6</span>. Diagrama Pata de gallo
|
||||
|
||||
<span style="color: #ffd400; font-weight: bold;">7</span>. Diagrama de clases
|
||||
Num_Pre_Contrato <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Pre_Contratos (Num_Pre_Contrato),
|
||||
Fecha_Generacion datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Reclamos</span>(
|
||||
Num_reclamo <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
<span style="color: #ff2afc; font-weight: bold;">unique</span> (Num_Usuario,Num_Contrato),
|
||||
Num_Usuario <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Usuarios (Num_Usuario),
|
||||
Num_Contrato <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Contratos (Num_Contrato),
|
||||
Motivo nvarchar (<span style="color: #ffd400; font-weight: bold;">100</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Fecha_Reclamo datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Num_Estado <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Estados (Num_Estado),
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Administrador_Servicio</span>(
|
||||
<span style="color: #ff2afc; font-weight: bold;">Primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span> (Num_Administrador,Num_Servicio),
|
||||
Num_Administrador <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Administradores (Num_Administrador),
|
||||
Num_Servicio <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Servicios_Publicaciones (Num_Servicio)
|
||||
);
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Recordatorios_Usuario</span>(
|
||||
Num_Recordatorio <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Num_Contrato <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Contratos (Num_Contrato),
|
||||
Num_Usuario <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Usuarios (Num_Usuario),
|
||||
Hora <span style="color: #ffd400;">decimal</span> (<span style="color: #ffd400; font-weight: bold;">10</span>,<span style="color: #ffd400; font-weight: bold;">2</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Fecha datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Lugar nvarchar (<span style="color: #ffd400; font-weight: bold;">50</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>
|
||||
);
|
||||
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org91c8dba" class="outline-2">
|
||||
<h2 id="org91c8dba"><span class="section-number-2">5.</span> Diagrama Pata de gallo</h2>
|
||||
<div class="outline-text-2" id="text-5">
|
||||
|
||||
<div id="orgaacf8fb" class="figure">
|
||||
<p><img src="./master - proyecto_analisis3 - dbo.png" alt="master - proyecto_analisis3 - dbo.png" width="900px" />
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org377f853" class="outline-2">
|
||||
<h2 id="org377f853"><span class="section-number-2">6.</span> Marco Teorico Normalizacion</h2>
|
||||
<div class="outline-text-2" id="text-6">
|
||||
<p>
|
||||
La normalización es un proceso fundamental en el diseño de bases de datos que tiene como objetivo reducir la redundancia y mejorar la integridad de los datos. Este proceso implica organizar los datos en tablas y columnas para asegurar que las dependencias entre datos estén correctamente definidas y las anomalías de actualización se minimicen. Las formas normales (NF) son los estándares utilizados para evaluar el nivel de normalización de una base de datos.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
A continuación, desarrollaremos las cinco formas normales (1FN, 2FN, 3FN, 4FN y 5FN) aplicadas a nuestro proyecto para poder tener una visión más práctica de lo que las mismas implican.
|
||||
</p>
|
||||
</div>
|
||||
<div id="outline-container-orgb19d55f" class="outline-3">
|
||||
<h3 id="orgb19d55f"><span class="section-number-3">6.1.</span> Primera Forma Normal (1FN)</h3>
|
||||
<div class="outline-text-3" id="text-6-1">
|
||||
<p>
|
||||
La Primera Forma Normal establece que los datos deben estar organizados en tablas de manera que cada columna contenga valores atómicos, y cada fila sea única.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Por ejemplo, la tabla `Profesionales` tiene columnas con valores indivisibles y cada campo contiene solo un valor y no se permite la repetición de filas.
|
||||
</p>
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-sql"><span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Profesionales</span>(
|
||||
Num_Profesional <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Email nvarchar (<span style="color: #ffd400; font-weight: bold;">30</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Telefono <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Nombre nvarchar (<span style="color: #ffd400; font-weight: bold;">25</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Apellido nvarchar (<span style="color: #ffd400; font-weight: bold;">25</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
DNI <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>
|
||||
);
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org411a8e0" class="outline-3">
|
||||
<h3 id="org411a8e0"><span class="section-number-3">6.2.</span> Segunda Forma Normal (2FN)</h3>
|
||||
<div class="outline-text-3" id="text-6-2">
|
||||
<p>
|
||||
La Segunda Forma Normal requiere que la base de datos cumpla con 1FN y que todos los atributos no clave dependen completamente de la clave primaria. Esto significa que no debe haber dependencias parciales en una tabla. Las tablas como `Credenciales` cumplen con esta forma normal, ya que todos sus atributos dependen completamente de la clave primaria `Num<sub>credencial</sub>`.
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-sql">
|
||||
<span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Credenciales</span>(
|
||||
Num_credencial <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Titulo nvarchar (<span style="color: #ffd400; font-weight: bold;">50</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Imagen_Titulo nvarchar (<span style="color: #ffd400; font-weight: bold;">150</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Especializacion nvarchar (<span style="color: #ffd400; font-weight: bold;">40</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Num_Profesional <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Profesionales (Num_Profesional)
|
||||
);
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgb6f84dd" class="outline-3">
|
||||
<h3 id="orgb6f84dd"><span class="section-number-3">6.3.</span> Tercera Forma Normal (3FN)</h3>
|
||||
<div class="outline-text-3" id="text-6-3">
|
||||
<p>
|
||||
La Tercera Forma Normal requiere que la base de datos cumpla con 2FN y que no haya dependencias transitivas, es decir, los atributos no clave deben depender solo de la clave primaria y no de otros atributos no clave. Las tablas como `Publicaciones` cumplen con esta forma normal, ya que todos sus atributos dependen directamente de la clave primaria `Num<sub>Publicacion</sub>`.
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-sql"><span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Publicaciones</span>(
|
||||
Num_Publicacion <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
<span style="color: #ff2afc; font-weight: bold;">unique</span> (Num_Profesional, Num_Servicio),
|
||||
Num_Profesional <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Profesionales (Num_Profesional),
|
||||
Num_Servicio <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Servicios_Publicaciones (Num_Servicio),
|
||||
Fecha_Publicacion_Inicial datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Tarifa <span style="color: #ffd400;">decimal</span> (<span style="color: #ffd400; font-weight: bold;">5</span>,<span style="color: #ffd400; font-weight: bold;">2</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Horas_De_Trabajo <span style="color: #ffd400;">decimal</span> (<span style="color: #ffd400; font-weight: bold;">2</span>,<span style="color: #ffd400; font-weight: bold;">1</span>) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>
|
||||
);
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgb55c926" class="outline-3">
|
||||
<h3 id="orgb55c926"><span class="section-number-3">6.4.</span> Cuarta Forma Normal (4FN)</h3>
|
||||
<div class="outline-text-3" id="text-6-4">
|
||||
<p>
|
||||
La Cuarta Forma Normal se ocupa de las dependencias multivaluadas. Una tabla está en 4FN si está en 3FN y no tiene dependencias multivaluadas no triviales. En nuestro caso las tablas no presentan dependencias multivaluadas no triviales, lo que significa que cumplen con esta forma normal. Por ejemplo, la tabla `Administradores<sub>Permisos</sub>` maneja correctamente las relaciones muchos a muchos sin introducir redundancias indebidas.
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-sql"><span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Administradores_Permisos</span>(
|
||||
<span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span> (Num_Administrador, Num_Permiso),
|
||||
Num_Administrador <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Administradores (Num_Administrador),
|
||||
Num_Permiso <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Permisos (Num_Permiso)
|
||||
);
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-org2c3b7d8" class="outline-3">
|
||||
<h3 id="org2c3b7d8"><span class="section-number-3">6.5.</span> Quinta Forma Normal (5FN)</h3>
|
||||
<div class="outline-text-3" id="text-6-5">
|
||||
<p>
|
||||
La Quinta Forma Normal requiere que la base de datos esté en 4FN y que cualquier dependencia de unión no trivial esté implícita en las claves candidatas. Esto significa que una tabla no debe poder descomponerse en dos o más tablas más pequeñas que se puedan unir sin pérdida de información.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Por ejemplo, la tabla `Contratos` no puede descomponerse sin pérdida de información:
|
||||
</p>
|
||||
|
||||
<div class="org-src-container">
|
||||
<pre class="src src-sql"><span style="color: #ff2afc; font-weight: bold;">create</span> <span style="color: #ff2afc; font-weight: bold;">table</span> <span style="color: #42c6ff;">Contratos</span>(
|
||||
Num_Contrato <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">primary</span> <span style="color: #ff2afc; font-weight: bold;">key</span>,
|
||||
Fecha_Generacion datetime <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span>,
|
||||
Num_Comprobante <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Comprobantes_Pago (Num_Comprobante) <span style="color: #ff2afc; font-weight: bold;">not</span> <span style="color: #ff2afc; font-weight: bold;">null</span> <span style="color: #ff2afc; font-weight: bold;">unique</span>,
|
||||
Num_Profesional <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Profesionales (Num_Profesional),
|
||||
Num_Usuario <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Usuarios (Num_Usuario),
|
||||
Num_Publicacion <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Publicaciones (Num_Publicacion),
|
||||
Num_Pre_Contrato <span style="color: #ffd400;">int</span> <span style="color: #ff2afc; font-weight: bold;">foreign</span> <span style="color: #ff2afc; font-weight: bold;">key</span> <span style="color: #ff2afc; font-weight: bold;">references</span> Pre_Contratos (Num_Pre_Contrato)
|
||||
);
|
||||
</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgf49dd95" class="outline-2">
|
||||
<h2 id="orgf49dd95"><span class="section-number-2">7.</span> Diagrama de clases</h2>
|
||||
<div class="outline-text-2" id="text-7">
|
||||
|
||||
<div id="orge27a788" class="figure">
|
||||
<p><img src="./DiagramaDeCLases.png" alt="DiagramaDeCLases.png" />
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="outline-container-orgef2db9d" class="outline-2">
|
||||
<h2 id="orgef2db9d"><span class="section-number-2">8.</span> Diagrama Entidad-Relacion</h2>
|
||||
<div class="outline-text-2" id="text-8">
|
||||
|
||||
<div id="org7af878b" class="figure">
|
||||
<p><img src="./D.E.R.jpg" alt="D.E.R.jpg" width="1500px" />
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="postamble" class="status">
|
||||
<p class="author">Author: Grupo 1</p>
|
||||
<p class="date">Created: 2024-07-07 dom 19:42</p>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user