How to create a variable containing two columns?

This is the preview of the data in mysql

I want to make two variables on Grafana: Counter and Random

How can I do that?
What will be the query?

I have tried using
SELECT Counter FROM <table_name>
SELECT * FROM <table_name>

But no success.

I want something like this:

where I would be able to select Counter and Grafana would display Counter values only.
When I select Random, random values should be displayed.
Any help would be appreciated.