Getting current user data with MySQL statement
There are many widgets in Elementor which allow using MySQL statements to populate some data field. What I am trying to do is populate a field with a specific user's order data. The problem I am running into is because these Elementor MySQL editors do not allow php I have to get the current user ID, etc... with only valid MySQL syntax.
I am very new to developing in WordPress. Should I just grow a pair, move out of my plugins' basement, get a real job, and ditch Elementor or is there an easier way to configure/write these MySQL statements with php inside of them (instead of vice versa which I know is possible but these fields only allow MySQL statements)?
This is what I have tried:
SELECT * FROM table WHERE ID = wp_get_current_user()-ID
Yes, I realize I just exposed how little I know with that statement above and how potentially dumb that was... Just let me down slowly if I am on to something, if not don't hesitate to put me in my place.