changed mysql query
Merge branch 'dev2'