Trying to establish connection to External Database

My issue was resolved, not sure if the connection to the database will work, but the error with wpdb connection was fixed. It was quite easy fix once I found out what the file dependence was. This is what you need to do:

In the file you are trying to use wpdb you need to add code before you can use the class:

<?php require_once('../../../wp-load.php'); ?>

Note* You may need to change how far back in the directory you go depending on your install or depending on the location of your php template/file.

It should run wpdb without any errors.