Php function within SQL statement syntax

Posted by Vafello on Stack Overflow See other posts from Stack Overflow or by Vafello
Published on 2010-04-19T15:57:14Z Indexed on 2010/04/19 16:03 UTC
Read the original article Hit count: 150

Filed under:
|

I have the following code. I would like username to take the value of the getUserName function however I am fighting with syntax. Can anybody tell me what should be the correct one?

$query = "SELECT user FROM users_entity WHERE username = getUserName()";

© Stack Overflow or respective owner

Related posts about sql

Related posts about php