Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

My long table extends one more column after the last row and is not smooth. What am I missing?

\usepackage{longtable}

\begin{longtable}{|l|l|}
\caption{sample table with extra lines} \\
\hline
\textbf{ID} & \textbf{symbol} \\ \hline
100505607 & LOC100505607\\ \hline
100506282 & unknown \\ \hline
100506342 & unknown \\ \hline
\label{tab:exclusivelyByAbid}
\end{longtable}
share|improve this question
add comment

migrated from stackoverflow.com May 1 '12 at 10:36

This question came from our site for professional and enthusiast programmers.

1 Answer

up vote 5 down vote accepted

\label needs to be inside the \caption argument (or in a later table cell), but not, as in the posted code, in a cell on its own on the last row, otherwise longtable will generate a spurious last row to hold the write node.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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