\begin{frame} \frametitle{Multi-Valued Attributes} \begin{goal}{} \emph{Multi-valued attribute} $A$ of an entity set $E$ is represented by \mpause[1]{a \emph{separate table} with: \begin{itemize} \item columns for the primary key of $E$, and \item a column for the attribute value \end{itemize} Each single value of the multi-valued attributes gets its own row.% } \end{goal} \begin{center} \scalebox{.92}{ \begin{tikzpicture}[every edge/.style={link}] \node[entity] (customer) {customer}; \node[attribute] (id) [at=(customer),shift={(-1cm,1cm)}] {\key{id}} edge (customer); \node[attribute] (name) [at=(customer),shift={(1cm,1cm)}] {name} edge (customer); \node[multi attribute] (phone) [at=(customer),shift={(3.5cm,0cm)}] {phone-number} edge (customer); \end{tikzpicture}} \end{center} \mpause{ \begin{center} {\small\ttfamily \colorbox{rellight}{% \begin{tabular}[t]{|r|r|} \multicolumn{2}{c}{Customer} \\ \hline \hd{\key{id}} & \hd{name} \\ \hline 1 & Smith \\ 2 & Jones \\ 3 & Brown \\ 4 & Ford \\ \hline \end{tabular}% }~\quad~% \colorbox{rellight}{% \begin{tabular}[t]{|r|r|} \multicolumn{2}{c}{Phone-number} \\ \hline \hd{\key{id}$\;\to\;$Customer} & \hd{\key{number}} \\ \hline 1 & 06-19348472 \\ 1 & 0346-928475 \\ 3 & 06-13783933 \\ 3 & 0238-187333 \\ 3 & 0192-937189 \\ \hline \end{tabular}% } } \end{center} } \end{frame}