Fixed incorrect datatype conversion on multi-indexes
When creating a new table from a `pandas` dataframe with a multi-index, the code would iterate over the index columns backwards but use their types as if counting forwards.  This meant that the created table had incorrect indexes for multi-indexes.

This code factors out a function to pull column names and column types for both SQLAlchemy and legacy table objects.  This code now iterates over the indices properly.

And additional test has been written.  All test pass on my local machine.

Closes https://github.com/pydata/pandas/issues/8021 .

@artemyk Looks good, thanks a lot! Only some comments on the test.
 You are totally right --- I didn't realize that while the write/read test would fail currently, I thought it would return both columns as having `float` dtype both pre- and post-patch.  But in fact, post-patch the dtypes are correct, while pre-patch they are both `float`.  So the test is simpler and now applies both to SQLAlchemy and legacy APIs (it is under `_TestSQLApi`).  Let me know if there is anything else to fix.
 I think this may be ready to go.
 @artemyk needs:
-  rebase on master (so you will pick up the changed test functions)
- a release note in v0.15.0 (bug fix?)
- a squash
 @jreback Sorry, this is actually my first pull request ever so I'm not exactly sure what I need to do now.
I inserted a line in release notes.  Regarding rebasing on master, I actually cherry-picked the commit with the changed test functions, so that change is included.  Do I still need to rebase & squash?
 The change in the test function is already merged in master, so if you fetch pandas master (`git fetch upstream`) it will already be included, and you certainly don't need to cherry-pick it. So try:

```
git fetch upstream
git rebase upstream/master
```

And then, with squashing we mean to combine the different update commits all into one for this PR, you can do this with `git rebase -i HEAD~6`, and then squash the necessary commits.

Just ask if something is not clear!
 see here: https://github.com/pydata/pandas/wiki/Using-Git

@jorisvandenbossche instructions are good
 @jreback Thanks greatly for the instructions.  I followed them however, when I did `git push` I got a "Updates were rejected because the tip of your current branch is behind its remote counterpart" error.  So I did a `git push -f`.  Does this commit look correct?
I notice that the changes include those I made to `assert_frame_equal` -- that probably doesn't belong, right?
 yes, you need to use `-f`.

pls squash as well

so

```
git rebase -i origin/master
```

then 's' all of the commits (ecept the first)

then repush with the '-f'
 @jreback Thanks for the help.  
This should be squashed now.
 looks good to me, @jorisvandenbossche ball in your court
 Tests passed, so merging. 
Thanks a lot @artemyk, excellent first (or second now) PR! 
(and more is always welcome if you want :-))
