I have a separate file called sql_access.js that is supposed to make accessing my SQL database easy from every other location that would access the SQL. You can see
sql_access.js