Creating onlyintestbranch SQLQuery