Title: Query Syntax help
Last modified: August 30, 2016

---

# Query Syntax help

 *  [gps961](https://wordpress.org/support/users/gps961/)
 * (@gps961)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/query-syntax-help/)
 * I’m trying to modify a query so that the WHERE condition tests that a field equals
   the login of the user. I know the first part is correct but I cannot work out
   how I describe the login. It currently goes;
 * WHERE ‘Org’ = user_login
 * but user_login doesn’t work.
 * Does anyone know how I should correct this.
 * Thanks

Viewing 1 replies (of 1 total)

 *  [Matt Knowles](https://wordpress.org/support/users/aestheticdesign/)
 * (@aestheticdesign)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/query-syntax-help/#post-6289881)
 * What is your entire query string?

Viewing 1 replies (of 1 total)

The topic ‘Query Syntax help’ is closed to new replies.

## Tags

 * [MySQL Query](https://wordpress.org/support/topic-tag/mysql-query/)

 * In: [Hacks](https://wordpress.org/support/forum/plugins-and-hacks/hacks/)
 * 1 reply
 * 2 participants
 * Last reply from: [Matt Knowles](https://wordpress.org/support/users/aestheticdesign/)
 * Last activity: [10 years, 11 months ago](https://wordpress.org/support/topic/query-syntax-help/#post-6289881)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
