https://www.icyphoenix.com/viewtopic.php?f=35&t=6267&p=42634#p42634 ----------------------------------- spydie Mon 10 Aug, 2009 21:34 Problem With Sql " Trying To Port A Mod" ----------------------------------- hi i got a small problem I´m trying to port F-1 Webtip Mod from .27 to 1.3 At the moment everything is fine but i have a problem with the table prefixes i got for example this code : [code linenumbers=false]// Pull all config data // $sql = "SELECT * FROM " . 'FORMEL_CONFIG_TABLE'; if(!$result = $db->sql_query($sql)) { message_die(GENERAL_ERROR, "Could not query config information in formel configuration", "", __LINE__, __FILE__, $sql); } else { while( $row = $db->sql_fetchrow($result) ) { $config_name = $row['config_name']; $config_value = $row['config_value']; $default_config[$config_name] = isset($HTTP_POST_VARS['submit']) ? str_replace("'", "\'", $config_value) : $config_value; $new[$config_name] = ( isset($HTTP_POST_VARS[$config_name]) ) ? $HTTP_POST_VARS[$config_name] : $default_config[$config_name]; if( isset($HTTP_POST_VARS['submit']) ) { $sql = "UPDATE " . 'FORMEL_CONFIG_TABLE'. " SET config_value = '" . str_replace("\'", "''", $new[$config_name]) . "' WHERE config_name = $config_name"; if( !$db->sql_query($sql) ) { message_die(GENERAL_ERROR, "Failed to update configuration for $config_name", "", __LINE__, __FILE__, $sql); } } } if( isset($HTTP_POST_VARS['submit']) ) { $message = $lang['formel_acp_config_updated'] . "

" . sprintf($lang['Click_return_config'], "", "") . "

" . sprintf($lang['Click_return_admin_index'], "", ""); message_die(GENERAL_MESSAGE, $message); } } [/code] and i get this error message : [quote]Could not query config information in formel configuration DEBUG MODE SQL Error : 1146 Table 'ip.ip_formel_config' doesn't exist SELECT * FROM ip_formel_config Line : 82 File : admin_formel_config.php[/quote] As you see The mod is calling Db by name and then the table prefix.