Started using database - still buggy. Started with recognition and autocompletion of variables in query - also buggy.