Query from WordPress

I need to get data from a WordPress database and to get the name of the image I have to cross two tables. The query should be like this

11

but does not accept a text and therefore interprets it is undefined

It’s possible to solve this?

Thank you

Community Page
Last updated: