# Table number in ref inconsistent with actual table caption [duplicate]

Possible Duplicate:
Why does an environment’s label have to appear after the caption?

For convenience of readers, Table~\ref{table_abbreviation} lists the abbreviations and their full meaning, as used in this report.

\begin{table}[ht]
\label{table_abbreviation}
\caption{Abbreviations used in this paper}
\centering
\begin{tabular}{l l}
\hline
Abbreviations & Full definition \\
\hline
P2P & Peer-to-peer  \\
DDM & Distributed Data Mining  \\
[1ex]
\hline
\end{tabular}
\end{table}


The above is a latex code portion from a document I am writing. I am expecting ~\ref{table_abbreviation} to give the same number as shown next to the caption of table. However, while the caption says "Table 1", in the content it is referred as 1.3. Perhaps, the numbering would be clear if I give the whole code, but I was under the impression, the numbering will be consistent no matter where they are used.

-

## marked as duplicate by egreg, lockstep, Kurt, Stefan Kottwitz♦Nov 2 '12 at 13:17

@ShamimHafiz -- your question about the ordering of the \label and \caption is answered in this question: Why does an environment's label have to appear after the caption?. –  barbara beeton Nov 2 '12 at 12:24