Possible Duplicate:
Keeping tables/figures close to where they are mentioned

I have a doc that has several tables in it. Each section of my end document is in a separate .tex file. In some of my files I have tables in them. Say, for example, section 4 has two tables. Currently the first table for section four does not begin on any of the pages that section 4 is on. Section 5 starts at the end of the last page, but the first section 4 table appears on the next page, which does not have any of the section 4 text in it. How do I ensure these tables appear on pages that have section 4 text on them?


For general advice look at How to influence the position of float environments like figure and table in LaTeX?. For your specific problem you might try to use the \FloatBarrier command (from the package placeins) which will output all floats that are not yet typeset when encountered. E.g.,


\section{New section}

The package offers some fine-tuning possibilities, see its documentation.

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