![]() |
Help with SQL
Can anyone help me with what is wrong with this query?
$db->query_first('SELECT userid, usergroupid, membergroupids, username, password, salt FROM user WHERE (username = "$username")') I'm getting the following error from my script - Invalid SQL: SELECT userid, usergroupid, membergroupids, username, password, salt FROM user WHERE username = interpolated_username; MySQL Error : Unknown column 'interpolated_username' in 'where clause' Thanks guys, Max |
Try changing it to:
PHP Code:
Alan. |
Quote:
PHP Code:
|
Here's my script guys, it's what I would consider pretty basic, but...for whatever reason I just can not get this to work. Im sure I am just overlooking something as I am pretty glazed from working on this. Maybe some fresh eyes can help me...
Here's the script: PHP Code:
Seems simple enough, eh? Thanks! Max Thanks for the help, guys! I've figured out the problem however. The problem was not with the query that you guys helped with, it was due to the fact that I had not set the query to an array. Learned a lot from this little excercise, thanks again! |
$bbuserinfo is only available in templates.
PHP Code:
|
All times are GMT. The time now is 10:45 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|