\begin{frame}[fragile]
\frametitle{Integrity Constraints}
\begin{exampleblock}{Example schema with key constraints}
\begin{itemize}
\item Customers(\ul{id}, name, street, city) \\
\hint{\emph{Primary key constraint} on \ul{id}}
\item Accounts(depositor $\to$ Customers(id), \ul{accountnr})\\
\hint{\emph{Foreign key constraint} on depositor}
\end{itemize}
\end{exampleblock}
\bigskip
Various types of constraints:
\begin{itemize}
\item \emph{data types}, constrained data types (domains)\\
(e.g. \verb|numeric(2,0)|, \verb|varchar(40)|, \ldots)
\item \emph{columns constraints}\\
(e.g. unique, nullability, counter, \ldots)
\item \emph{check constraints}: logical expression for domain integrity\\
(e.g. \verb|age >= 18 and age <= 150|)
\end{itemize}
\end{frame}