kack kack - 2 years ago 172
MySQL Question

Table column name with regular expression using mysql

Please let me know is that possible i am use regular expression or another idea to set query like,

select name_en,name_ar,desc_en,desc_ar from table_name

in above query i need to write all column name but should be required directly
column name have _en or _ar not want to specify all column name.

Answer Source

Please try with mysql_list_fields() function and get your fields name from the table.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download