2

I have a long table that I would like to span as many pages as necessary. I used longtable within landscape but it gives me an error. This is my code:

\begin{document}


\begin{landscape}

\begin{longtable}[H]

\begin{tabular}{l*{6}{c}r}
    \hline 
    Description   & T & Source & Geography & Start & End & F \\ 
    \hline 

     \multicolumn{1}{l}{\textbf{Real Activity}} \\ 

    Retail sales volume index & 6 & 4 & 0 & 2 & 10 &  Y \\
    Manufacturing turnover index  & 6 & 3 & 0 & 3 &  8 &  Y \\
    Construction production index       & 6 & 2 & 1 & 3 &  7 & Y  \\
    Retail sales of non-food production (excl. fuel)  & 6 & 2 & 1 & 3 &  5 & Y  \\
    Industrial Production (excluding construction)  & 6 & 2 & 1 & 3 &  5 &  Y \\
    Industrial Production: manufacturing  & 6 & 2 & 1 & 3 &  5 & Y  \\
     Industrial Production: energy  & 6 & 2 & 1 & 3 &  5 &   \\
     Industrial Production: consumer goods & 6 & 2 & 1 & 3 &  5 &  Y \\
     Industrial Production: consumer durables & 6 & 2 & 1 & 3 &  5 &  Y \\
     Industrial Production: capital goods & 6 & 2 & 1 & 3 &  5 &  Y \\
     Industrial Production: consumer non-durables & 6 & 2 & 1 & 3 &  5 & Y  \\
     Industrial Production: intermediate goods & 6 & 2 & 1 & 3 &  5 &  Y \\
     New orders: manufacturing & 6 & 2 & 1 & 3 &  5 &  Y \\
     New orders: capital goods & 6 & 2 & 1 & 3 &  5 &  Y \\
     New orders: consumer durables & 6 & 2 & 1 & 3 &  5 & Y  \\
     New orders: consumer non-durables  & 6 & 2 & 1 & 3 &  5 &  Y \\
     New orders: intermediate goods  & 6 & 2 & 1 & 3 &  5 & Y  \\

    \multicolumn{1}{l}{\textbf{Prices}} \\ 

    Harmonised Index of COnsumer Prices (HICP) & 6 & 4 & 0 & 2 & 10 &  Y \\
    HICP: energy    & 6 & 3 & 0 & 3 &  8 &  Y \\
    HICP: food    & 6 & 2 & 1 & 3 &  7 &  Y \\
    HICP: goods    & 6 & 2 & 1 & 3 &  5 &  Y \\
    HICP: excl. energy    & 6 & 2 & 1 & 3 &  5 &  Y \\
    Producer Price Index (PPI)    & 6 & 2 & 1 & 3 &  5 &  Y \\
    Oil Prices (Brent)    & 6 & 2 & 1 & 3 &  5 &  Y \\

    \multicolumn{1}{l}{\textbf{Surveys}} \\ 

    Economic Sentiment Indicator (ESI): industrial confidence & 6 & 4 & 0 & 2 & 10 &  Y \\
    ESI: consumer confidence  & 6 & 3 & 0 & 3 &  8 &  Y \\
    ESI: economic sentiment & 6 & 2 & 1 & 3 &  7 &  Y \\
    ESI: business climate & 6 & 2 & 1 & 3 &  5 &  Y \\


\end{tabular}

\end{longtable}


\end{landscape}

\end{document}

Can anyone help me ?

Thanks a lot!

2
  • 2
    the syntax you show is unlike any example in the longtable manual. longtable does not have an H argument and you are missing the {cccc} column specification argument, and your longtable is just a single row single column with a tabular in the cell so no page breaking is possible. Jun 8, 2020 at 10:50
  • @DavidCarlisle How can I fix it to make it work on for page breaking?
    – Rollo99
    Jun 8, 2020 at 10:53

1 Answer 1

6

Please see the longtable documentation, you want something like

\documentclass{article}

\usepackage{longtable,pdflscape}

\begin{document}



\begin{landscape}

\begin{longtable}{l*{6}{c}r}
    \hline 
    Description   & T & Source & Geography & Start & End & F \\ 
    \hline 
\endhead
     \multicolumn{1}{l}{\textbf{Real Activity}} \\ 

    Retail sales volume index & 6 & 4 & 0 & 2 & 10 &  Y \\
    Manufacturing turnover index  & 6 & 3 & 0 & 3 &  8 &  Y \\
    Construction production index       & 6 & 2 & 1 & 3 &  7 & Y  \\
    Retail sales of non-food production (excl. fuel)  & 6 & 2 & 1 & 3 &  5 & Y  \\
    Industrial Production (excluding construction)  & 6 & 2 & 1 & 3 &  5 &  Y \\
    Industrial Production: manufacturing  & 6 & 2 & 1 & 3 &  5 & Y  \\
     Industrial Production: energy  & 6 & 2 & 1 & 3 &  5 &   \\
     Industrial Production: consumer goods & 6 & 2 & 1 & 3 &  5 &  Y \\
     Industrial Production: consumer durables & 6 & 2 & 1 & 3 &  5 &  Y \\
     Industrial Production: capital goods & 6 & 2 & 1 & 3 &  5 &  Y \\
     Industrial Production: consumer non-durables & 6 & 2 & 1 & 3 &  5 & Y  \\
     Industrial Production: intermediate goods & 6 & 2 & 1 & 3 &  5 &  Y \\
     New orders: manufacturing & 6 & 2 & 1 & 3 &  5 &  Y \\
     New orders: capital goods & 6 & 2 & 1 & 3 &  5 &  Y \\
     New orders: consumer durables & 6 & 2 & 1 & 3 &  5 & Y  \\
     New orders: consumer non-durables  & 6 & 2 & 1 & 3 &  5 &  Y \\
     New orders: intermediate goods  & 6 & 2 & 1 & 3 &  5 & Y  \\

    \multicolumn{1}{l}{\textbf{Prices}} \\ 

    Harmonised Index of COnsumer Prices (HICP) & 6 & 4 & 0 & 2 & 10 &  Y \\
    HICP: energy    & 6 & 3 & 0 & 3 &  8 &  Y \\
    HICP: food    & 6 & 2 & 1 & 3 &  7 &  Y \\
    HICP: goods    & 6 & 2 & 1 & 3 &  5 &  Y \\
    HICP: excl. energy    & 6 & 2 & 1 & 3 &  5 &  Y \\
    Producer Price Index (PPI)    & 6 & 2 & 1 & 3 &  5 &  Y \\
    Oil Prices (Brent)    & 6 & 2 & 1 & 3 &  5 &  Y \\

    \multicolumn{1}{l}{\textbf{Surveys}} \\ 

    Economic Sentiment Indicator (ESI): industrial confidence & 6 & 4 & 0 & 2 & 10 &  Y \\
    ESI: consumer confidence  & 6 & 3 & 0 & 3 &  8 &  Y \\
    ESI: economic sentiment & 6 & 2 & 1 & 3 &  7 &  Y \\
    ESI: business climate & 6 & 2 & 1 & 3 &  5 &  Y \\



\end{longtable}


\end{landscape}


\end{document}
1
  • Very helpful, thanks so much!
    – Rollo99
    Jun 8, 2020 at 11:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.