Q:

How do I see a MariaDB Virtual Formula once the Table is Created?

I Created a table below. 
CREATE TABLE product ( 
productname VARCHAR(25),  
price_eur DOUBLE, 
xrate DOUBLE, 
price_usd DOUBLE AS (price_eur*xrate) VIRTUAL);
Query OK, 0 rows affected (0.28 sec)

How Can I View the price_usd Formula after I Created the Table? I use phpMyAdmin and all it shows that it's a VIRTUAL and a DOUBLE.
Thank You for Your Help! 

A:

You can find which columns are virtual with this query
select table_schema, table_name, column_name 
  from information_schema.columns 
 where extra='virtual'

In order to see the formula you need to issue the SHOW CREATE TABLE tablename command; it doesn't seem like the MariaDB team has put virtual-column formulae into the information_schema yet, sigh.

