academia/docs/architecture/diagrams/05-entity-relationship.svg

1 line
18 KiB
XML

<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" contentStyleType="text/css" data-diagram-type="CLASS" height="651px" preserveAspectRatio="none" style="width:882px;height:651px;background:#FFFFFF;" version="1.1" viewBox="0 0 882 651" width="882px" zoomAndPan="magnify"><title>Sistema de Registro de Estudiantes - Diagrama Entidad-Relaci&#243;n</title><defs/><g><g class="title" data-source-line="6"><text fill="#000000" font-family="Verdana" font-size="22" font-weight="bold" lengthAdjust="spacing" textLength="804.8154" x="34.3288" y="35.4209">Sistema de Registro de Estudiantes - Diagrama Entidad-Relaci&#243;n</text></g><!--class students--><g class="entity" data-entity="students" data-source-line="8" data-uid="ent0002" id="entity_students"><rect fill="#F8F9FA" height="125.4844" rx="2.5" ry="2.5" style="stroke:#495057;stroke-width:1;" width="246.0928" x="12" y="195.1994"/><ellipse cx="100.0938" cy="209.1994" fill="#FFFFFF" rx="9" ry="9" style="stroke:#000000;stroke-width:1;"/><path d="M104.2031,215.1994 L96.4844,215.1994 L96.4844,202.8088 L104.2031,202.8088 L104.2031,204.965 L98.9375,204.965 L98.9375,207.6369 L103.7031,207.6369 L103.7031,209.7931 L98.9375,209.7931 L98.9375,213.0431 L104.2031,213.0431 L104.2031,215.1994 Z " fill="#000000"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="62.4053" x="117.5938" y="214.0461">Students</text><line style="stroke:#495057;stroke-width:1;" x1="13" x2="257.0928" y1="223.1994" y2="223.1994"/><ellipse cx="23" cy="236.8478" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="15.2305" x="30" y="240.1945">Id</text><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="66.623" x="49.6807" y="240.1945">: int &#171;PK&#187;</text><line style="stroke:#495057;stroke-width:1;" x1="13" x2="257.0928" y1="247.4963" y2="247.4963"/><ellipse cx="23" cy="261.1447" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="154.9639" x="30" y="264.4914">Name : nvarchar(100)</text><ellipse cx="23" cy="277.4416" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="222.0928" x="30" y="280.7882">Email : nvarchar(255) &#171;unique&#187;</text><ellipse cx="23" cy="293.7384" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="156.502" x="30" y="297.0851">CreatedAt : datetime2</text><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="160.3779" x="30" y="313.382">UpdatedAt : datetime2</text></g><!--class professors--><g class="entity" data-entity="professors" data-source-line="17" data-uid="ent0003" id="entity_professors"><rect fill="#F8F9FA" height="76.5938" rx="2.5" ry="2.5" style="stroke:#495057;stroke-width:1;" width="178.9639" x="506.56" y="58.6094"/><ellipse cx="556.0375" cy="72.6094" fill="#FFFFFF" rx="9" ry="9" style="stroke:#000000;stroke-width:1;"/><path d="M560.1469,78.6094 L552.4282,78.6094 L552.4282,66.2188 L560.1469,66.2188 L560.1469,68.375 L554.8813,68.375 L554.8813,71.0469 L559.6469,71.0469 L559.6469,73.2031 L554.8813,73.2031 L554.8813,76.4531 L560.1469,76.4531 L560.1469,78.6094 Z " fill="#000000"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="72.5088" x="573.5375" y="77.4561">Professors</text><line style="stroke:#495057;stroke-width:1;" x1="507.56" x2="684.5239" y1="86.6094" y2="86.6094"/><ellipse cx="517.56" cy="100.2578" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="15.2305" x="524.56" y="103.6045">Id</text><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="66.623" x="544.2407" y="103.6045">: int &#171;PK&#187;</text><line style="stroke:#495057;stroke-width:1;" x1="507.56" x2="684.5239" y1="110.9063" y2="110.9063"/><ellipse cx="517.56" cy="124.5547" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="154.9639" x="524.56" y="127.9014">Name : nvarchar(100)</text></g><!--class subjects--><g class="entity" data-entity="subjects" data-source-line="23" data-uid="ent0004" id="entity_subjects"><rect fill="#F8F9FA" height="109.1875" rx="2.5" ry="2.5" style="stroke:#495057;stroke-width:1;" width="185.4717" x="503.31" y="203.3494"/><ellipse cx="562.4809" cy="217.3494" fill="#FFFFFF" rx="9" ry="9" style="stroke:#000000;stroke-width:1;"/><path d="M566.5903,223.3494 L558.8715,223.3494 L558.8715,210.9588 L566.5903,210.9588 L566.5903,213.115 L561.3246,213.115 L561.3246,215.7869 L566.0903,215.7869 L566.0903,217.9431 L561.3246,217.9431 L561.3246,221.1931 L566.5903,221.1931 L566.5903,223.3494 Z " fill="#000000"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="59.6299" x="579.9809" y="222.1961">Subjects</text><line style="stroke:#495057;stroke-width:1;" x1="504.31" x2="687.7817" y1="231.3494" y2="231.3494"/><ellipse cx="514.31" cy="244.9978" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="15.2305" x="521.31" y="248.3445">Id</text><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="66.623" x="540.9907" y="248.3445">: int &#171;PK&#187;</text><line style="stroke:#495057;stroke-width:1;" x1="504.31" x2="687.7817" y1="255.6463" y2="255.6463"/><ellipse cx="514.31" cy="269.2947" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="154.9639" x="521.31" y="272.6414">Name : nvarchar(100)</text><ellipse cx="514.31" cy="285.5916" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="128.9258" x="521.31" y="288.9382">Credits : int {= 3}</text><ellipse cx="514.31" cy="301.8884" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="90.7881" x="521.31" y="305.2351">ProfessorId</text><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="66.2334" x="616.5483" y="305.2351">: int &#171;FK&#187;</text></g><!--class enrollments--><g class="entity" data-entity="enrollments" data-source-line="31" data-uid="ent0005" id="entity_enrollments"><rect fill="#F8F9FA" height="133.4844" rx="2.5" ry="2.5" style="stroke:#495057;stroke-width:1;" width="234.8926" x="247.6" y="380.6794"/><ellipse cx="319.433" cy="394.6794" fill="#FFFFFF" rx="9" ry="9" style="stroke:#000000;stroke-width:1;"/><path d="M323.5424,400.6794 L315.8236,400.6794 L315.8236,388.2888 L323.5424,388.2888 L323.5424,390.445 L318.2768,390.445 L318.2768,393.1169 L323.0424,393.1169 L323.0424,395.2731 L318.2768,395.2731 L318.2768,398.5231 L323.5424,398.5231 L323.5424,400.6794 Z " fill="#000000"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="83.7266" x="336.933" y="399.5261">Enrollments</text><line style="stroke:#495057;stroke-width:1;" x1="248.6" x2="481.4926" y1="408.6794" y2="408.6794"/><ellipse cx="258.6" cy="422.3278" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="15.2305" x="265.6" y="425.6745">Id</text><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="66.623" x="285.2807" y="425.6745">: int &#171;PK&#187;</text><line style="stroke:#495057;stroke-width:1;" x1="248.6" x2="481.4926" y1="432.9763" y2="432.9763"/><ellipse cx="258.6" cy="446.6247" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="78.1484" x="265.6" y="449.9714">StudentId</text><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="66.2334" x="348.1986" y="449.9714">: int &#171;FK&#187;</text><ellipse cx="258.6" cy="462.9216" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" font-weight="bold" lengthAdjust="spacing" textLength="74.5869" x="265.6" y="466.2682">SubjectId</text><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="66.2334" x="344.6371" y="466.2682">: int &#171;FK&#187;</text><ellipse cx="258.6" cy="479.2184" fill="#FFFFFF" rx="3" ry="3" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="158.1084" x="265.6" y="482.5651">EnrolledAt : datetime2</text><line style="stroke:#495057;stroke-width:1;" x1="248.6" x2="481.4926" y1="489.8669" y2="489.8669"/><text fill="#000000" font-family="Verdana" font-size="14" lengthAdjust="spacing" textLength="222.8926" x="253.6" y="506.862">&#171;unique&#187; (StudentId, SubjectId)</text></g><g class="entity" data-entity="GMN9" data-source-line="47" data-uid="ent0010" id="entity_GMN9"><path d="M293.55,230.2394 L293.55,253.6994 L258.41,257.6994 L293.55,261.6994 L293.55,285.6378 A0,0 0 0 0 293.55,285.6378 L468.5441,285.6378 A0,0 0 0 0 468.5441,285.6378 L468.5441,240.2394 L458.5441,230.2394 L293.55,230.2394 A0,0 0 0 0 293.55,230.2394" fill="#FFFFFF" style="stroke:#000000;stroke-width:1;"/><path d="M458.5441,230.2394 L458.5441,240.2394 L468.5441,240.2394 L458.5441,230.2394" fill="#FFFFFF" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="103.4541" x="299.55" y="247.3063">Restricciones:</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="84.2144" x="299.55" y="262.4391">- Email &#250;nico</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="153.9941" x="299.55" y="277.5719">- M&#225;ximo 3 enrollments</text></g><g class="entity" data-entity="GMN12" data-source-line="53" data-uid="ent0013" id="entity_GMN12"><path d="M724.24,230.2394 L724.24,253.6994 L689.23,257.6994 L724.24,261.6994 L724.24,285.6378 A0,0 0 0 0 724.24,285.6378 L873.8626,285.6378 A0,0 0 0 0 873.8626,285.6378 L873.8626,240.2394 L863.8626,230.2394 L724.24,230.2394 A0,0 0 0 0 724.24,230.2394" fill="#FFFFFF" style="stroke:#000000;stroke-width:1;"/><path d="M863.8626,230.2394 L863.8626,240.2394 L873.8626,240.2394 L863.8626,230.2394" fill="#FFFFFF" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="112.2837" x="730.24" y="247.3063">Datos iniciales:</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="78.0952" x="730.24" y="262.4391">10 materias</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="128.6226" x="730.24" y="277.5719">3 cr&#233;ditos cada una</text></g><g class="entity" data-entity="GMN15" data-source-line="59" data-uid="ent0016" id="entity_GMN15"><path d="M720.62,69.1994 L720.62,92.6994 L685.82,96.6994 L720.62,100.6994 L720.62,124.5978 A0,0 0 0 0 720.62,124.5978 L875.473,124.5978 A0,0 0 0 0 875.473,124.5978 L875.473,79.1994 L865.473,69.1994 L720.62,69.1994 A0,0 0 0 0 720.62,69.1994" fill="#FFFFFF" style="stroke:#000000;stroke-width:1;"/><path d="M865.473,69.1994 L865.473,79.1994 L875.473,79.1994 L865.473,69.1994" fill="#FFFFFF" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="112.2837" x="726.62" y="86.2663">Datos iniciales:</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="81.3706" x="726.62" y="101.3991">5 profesores</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="133.853" x="726.62" y="116.5319">2 materias cada uno</text></g><g class="entity" data-entity="GMN18" data-source-line="65" data-uid="ent0019" id="entity_GMN18"><path d="M250.44,574.1694 L250.44,644.7006 A0,0 0 0 0 250.44,644.7006 L479.6495,644.7006 A0,0 0 0 0 479.6495,644.7006 L479.6495,584.1694 L469.6495,574.1694 L369.05,574.1694 L365.05,514.2594 L361.05,574.1694 L250.44,574.1694 A0,0 0 0 0 250.44,574.1694" fill="#FFFFFF" style="stroke:#000000;stroke-width:1;"/><path d="M469.6495,574.1694 L469.6495,584.1694 L479.6495,584.1694 L469.6495,574.1694" fill="#FFFFFF" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="13" font-weight="bold" lengthAdjust="spacing" textLength="138.874" x="256.44" y="591.2363">Reglas de negocio:</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="190.4995" x="256.44" y="606.3691">- (StudentId, SubjectId) &#250;nico</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="182.3174" x="256.44" y="621.5019">- Estudiante no puede tener</text><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="199.9448" x="264.7046" y="636.6347">2 materias del mismo profesor</text></g><!--link students to enrollments--><g class="link" data-entity-1="students" data-entity-2="enrollments" data-source-line="42" data-uid="lnk6" id="link_students_enrollments"><path codeLine="42" d="M252.85,329.0394 C252.85,348.0894 252.85,343.0794 252.85,362.3794" fill="none" id="students-enrollments" style="stroke:#000000;stroke-width:1;"/><line style="stroke:#000000;stroke-width:1;" x1="248.85" x2="256.85" y1="325.0394" y2="325.0394"/><line style="stroke:#000000;stroke-width:1;" x1="248.85" x2="256.85" y1="328.0394" y2="328.0394"/><line style="stroke:#000000;stroke-width:1;" x1="252.85" x2="252.85" y1="329.0394" y2="321.0394"/><line style="stroke:#000000;stroke-width:1;" x1="252.85" x2="258.85" y1="372.3794" y2="380.3794"/><line style="stroke:#000000;stroke-width:1;" x1="252.85" x2="246.85" y1="372.3794" y2="380.3794"/><line style="stroke:#000000;stroke-width:1;" x1="252.85" x2="252.85" y1="372.3794" y2="380.3794"/><ellipse cx="252.85" cy="366.3794" fill="none" rx="4" ry="4" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="32.9443" x="219.85" y="346.7763">tiene</text></g><!--link subjects to enrollments--><g class="link" data-entity-1="subjects" data-entity-2="enrollments" data-source-line="43" data-uid="lnk7" id="link_subjects_enrollments"><path codeLine="43" d="M494.87,298.6994 C479,298.6994 475.52,298.6994 475.52,298.6994 C475.52,298.6994 475.52,322.9794 475.52,362.4594" fill="none" id="subjects-enrollments" style="stroke:#000000;stroke-width:1;"/><line style="stroke:#000000;stroke-width:1;" x1="498.87" x2="498.87" y1="294.6994" y2="302.6994"/><line style="stroke:#000000;stroke-width:1;" x1="495.87" x2="495.87" y1="294.6994" y2="302.6994"/><line style="stroke:#000000;stroke-width:1;" x1="494.87" x2="502.87" y1="298.6994" y2="298.6994"/><line style="stroke:#000000;stroke-width:1;" x1="475.52" x2="481.52" y1="372.4594" y2="380.4594"/><line style="stroke:#000000;stroke-width:1;" x1="475.52" x2="469.52" y1="372.4594" y2="380.4594"/><line style="stroke:#000000;stroke-width:1;" x1="475.52" x2="475.52" y1="372.4594" y2="380.4594"/><ellipse cx="475.52" cy="366.4594" fill="none" rx="4" ry="4" style="stroke:#000000;stroke-width:1;"/><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="84.7031" x="390.52" y="321.9663">inscripciones</text></g><!--link professors to subjects--><g class="link" data-entity-1="professors" data-entity-2="subjects" data-source-line="44" data-uid="lnk8" id="link_professors_subjects"><path codeLine="44" d="M596.05,143.4794 C596.05,163.6694 596.05,172.7394 596.05,194.9294" fill="none" id="professors-subjects" style="stroke:#000000;stroke-width:1;"/><line style="stroke:#000000;stroke-width:1;" x1="592.05" x2="600.05" y1="139.4794" y2="139.4794"/><line style="stroke:#000000;stroke-width:1;" x1="592.05" x2="600.05" y1="142.4794" y2="142.4794"/><line style="stroke:#000000;stroke-width:1;" x1="596.05" x2="596.05" y1="143.4794" y2="135.4794"/><line style="stroke:#000000;stroke-width:1;" x1="600.05" x2="592.05" y1="198.9294" y2="198.9294"/><line style="stroke:#000000;stroke-width:1;" x1="600.05" x2="592.05" y1="195.9294" y2="195.9294"/><line style="stroke:#000000;stroke-width:1;" x1="596.05" x2="596.05" y1="194.9294" y2="202.9294"/><text fill="#000000" font-family="Verdana" font-size="13" lengthAdjust="spacing" textLength="63.3369" x="532.05" y="165.2763">imparte 2</text></g><!--SRC=[hLJ1RjD04BtxAmPpeBMmI1CYQ1GgbJQHAWIg4l416-_K6MhlcjqreahwCHmvS-EQ7sCSRsoNf0W9VDhTUNvlvitiFd5Bp16AJ90Ax2sfGXYHGqOAtLs1e8rRwauWoOIrRqLocnfTAdcXCstWwVJrz7HwlWVJHgBna9UdmzxmLH0uSXd2dAp3N814c67A6wEhzSIwKf9G3Yt4S4aYPJ814-L82XdFC1C9RNwe840-SdSGpla7NjiGX0NhDx0AWBy8ekXAHX6CW9I3yVZwtTdPDXB77l11SF4ZK5-4IPR279tqUiS-DCa5PTrOVpWyPf9IqUSIFL445mQ5Gtdk62fvvIZ7_ZO6yB6G1sBtRVRNHj-WjThK-HVDzXyhw4ZCoyKdJ7O6-Sr_COWhbyHSzS-hDp2uRrYRmXxGJolwJcuJPNIMvKt_iDt_VOPHv6TWNwe1r6K_1gZJEDX3hz9s7OuQjUVGy6uTVmRrV6g5DcX6SRsEOxrwKDe8GaUeC0oQVXn6aRA9eQAc38FEU5JuzRhjPmNE-UevX7uO14hpmb2wTA1lccl1fOmNPpFasqP9JJeQlrXKDiH-t3S_5ILwU_1-y-qhvHe6tQouTH8gzZqDdqcjSIcSjcmq9IIoLkMa1pdRQqXKk04aPlETHuYXYP02IYKUvMzh_wF2q0ErmGhOR_Hs2lftXOLsJkULHBTCxrJAprZrBYbCDHlMkdLu2hhsjKyPgq5H8jCuRhhP3bGdCOaPv6JPwLtgROg_0000]--></g></svg>