0

I'm trying to replicate the table from Annex A of the ISO/IEC 27001 standard:

enter image description here

Here is my MWE:

\usepackage{array,longtable}
\begin{longtable}{| l | >{\raggedright}p{0.2\textwidth} | >{\raggedright}p{0.7\textwidth} |}
    \hline
    \multicolumn{3}{|>{\raggedright}p{\textwidth}|}{\textbf{Text text text}} \\           
    \hline
    Lorem & ipsum & text \\
\end{longtable}

However, adding almost anything between the 'Lorem ipsum' row and the \end{longtable} causes compilation to fail, but in different ways.

Adding another row of cells containing text causes the following:

! Extra alignment tab has been changed to \cr.
<recently read> \endtemplate 

l.195                       Lorem2 &
                        ipsum2 & text2 \\

Adding \hline causes the following:

! Misplaced \noalign.
\hline ->\noalign 
                  {\ifnum 0=`}\fi \hrule \@height \arrayrulewidth \futurelet...
l.195                       \hline

And adding \cline{1-3} causes the following:

! Misplaced \omit.
\@cline #1-#2\@nil ->\omit 
                           \@multicnt #1\advance \@multispan \m@ne \ifnum \@...
l.195                       \cline{1-3}

This happens whether I use the longtable or tabular environment.

The only thing that I can add that won't break it is a single text cell, e.g.:

    Lorem & ipsum & text \\
    adsfdsfdsf
\end{longtable}

I am at a complete loss as to what is wrong here. Every other question I can find with the same error is using different packages or nesting things in a way I am not.

The fact that compilation fails no matter what I add makes me think the actual error messages are red herrings, but I have no idea how to debug whatever the underlying issue may be without that information.

0 Answers0