So I write a paper with the following:

  \begin{table}\label{table:foo}
   \caption{Foo data}
    ...
  \end{table}

and a little later...

  \begin{table}\label{table:bar}
   \caption{Bar data}
    ...
  \end{table}

  We examined foo (see Table \ref{table:foo}),
  then we examined bar (see Table \ref{table:bar})...

but what does the generated text say?

  We examined foo (see Table 1),
  then we examined bar (see Table 1)...

What?!?

It turns out that in LaTeX, the table counter is incremented by the caption
command, not the start of a table environment!  I had to change it to

  \begin{table}
   \caption{Bar data}\label{table:bar}

so that the text would reference the correct table!


Reply via email to