Fatal error: Call to undefined function db_fetch_object() in /sites/all/modules/graphmind/plugins/graphmind_futures_wheel/graphmind_futures_wheel.module on line 84

Comments

voughndutch’s picture

I Am having this same issue what I doing wrong?

hgneng’s picture

me too.

db_fetch_object is D6 function.
But even I change it into D7 function, it still can't run. The $nid parameter passing into the function is not nid but an array of [map, plugins, features, setting.

hgneng’s picture

Status: Active » Needs review

I have solved the issue with following code although I have other issues to run Graphmind...

function graphmind_futures_wheel_is_node_futures_wheel($nid) {
  if (!is_numeric($nid))
    return FALSE;

  $res = db_query('SELECT COUNT(nid) AS count
    FROM {graphmind_futures_wheel}
    WHERE nid = :nid',
    array(':nid' => $nid));
  
  if ($res->rowCount() > 0)
    return ($res->fetch()->count >= 1);
  else
    return FALSE;
}
voughndutch’s picture

This fixes the error on my side thank you . Next issue Network request error