fixed basket select query