user messages query added, minor updates