There's most probably a CSS style somewhere in your HTML code which sets the margin before or after the tables.
Check the following code:
<!DOCTYPE html>
<head>
<title>Testing tables</title>
<style>
#t1, #t2 {
margin: 10px;
border-collapse: collapse;
border: 1px solid black;
}
</style>
</head>
<body>
<table id="t1">
<thead>
<tr><th>One</th><th>Two</th></tr>
</thead>
<tbody>
<tr><td>Data 1</td><td>Data 2</td></tr>
</tbody>
</table>
<table id="t2">
<thead>
<tr><th>Three</th><th>Four</th></tr>
</thead>
<tbody>
<tr><td>Data 3</td><td>Data 4</td></tr>
</tbody>
</table>
</body>
After you view this code in your browser, try to replace the line margin: 10px; with margin: 0 and see what's changed on the webpage.
You can use the right tools (Firefox / Chrome / Opera) to inspect which part of your code is playing tricks with you.