okay that did not work it just gives me the error "Could not perform query (), MySQL Said: Query was empty"
and yes all the tables are names are right and all but i did find this out
Code:
function get_config($config_name)
{
$configs = $this->query("SELECT name, value FROM config WHERE name=$config_name LIMIT 0,1");
$configrow = $this->fetch($configs,0);
return $configrow['value'];
}
that gives me this error
Could not perform query (SELECT name, value FROM config WHERE name=skey LIMIT 0,1), MySQL Said: Unknown column 'skey' in 'where clause'
okay that did not work it just gives me the error "Could not perform query (), MySQL Said: Query was empty"
and yes all the tables are names are right and all but i did find this out
Code:
function get_config($config_name)
{
$configs = $this->query("SELECT name, value FROM config WHERE name=$config_name LIMIT 0,1");
$configrow = $this->fetch($configs,0);
return $configrow['value'];
}
that gives me this error
Could not perform query (SELECT name, value FROM config WHERE name=skey LIMIT 0,1), MySQL Said: Unknown column 'skey' in 'where clause'
so that mite help you help me fix this.
You havent actually changed the line
look above. its still the same as the one in your first post
okay if you re-read my post it says "okay that did not work it just gives me the error "Could not perform query (), MySQL Said: Query was empty" "
and that other bit of code was anther test i did that gave me a diff error to the one i have been getting of Could not perform query (), MySQL Said: Query was empty.
Thats because you have 0,1 as your limit. anything with 0 returns an empty result
Taken from MYSQL REF:
Quote:
LIMIT 0 quickly returns an empty set. This can be useful for checking the validity of a query. When using one of the MySQL APIs, it can also be employed for obtaining the types of the result columns. (This trick does not work in the MySQL Monitor (the mysql program), which merely displays Empty set in such cases; you should instead use SHOW COLUMNS or DESCRIBE for this purpose.)
f
PHP Code:
unction get_config($config_name) {
$configs = $this->query("SELECT `name`, `value` FROM `config` WHERE `name`= '". $config_name ."' LIMIT 1"); $configrow = $this->fetch($configs,0); return $configrow['value'];
okay this is a very hard one to fix my the look as that did not fix it :'( will it be okay if i PM you my full code and you can make the fix's so you can test it all and see for you self it will make it easier???
You can post the file here unless it has any sensitive data in it
hmm i will not want to show the full code here, so..... but if i upload them as a html so you can read it and i post a link to it can you find whats wrong and help me?