Thanks Jamie,
I tried that. My webhost does not allow that.
Moving to a vps is not feasible at the moment.
Are there drupal alternatives to achieving what I want. I want to have multiple subdomains using the same codebase/database. I tried multisites, but I had the same issues.
Thanks