add sql code

File for mysql db