Fatal Error Accessing Dashboard

6 replies [Last post]
padmarketing
Offline
Joined: 10/12/2011
Status: 
Answered

I am getting this error when trying to access the dashboard and the page does not display:

Recoverable fatal error: Argument 2 passed to db_query() must be an array, integer given, called in /home/padbusin/public_html/draws/sites/all/modules/ms_affiliates/ms_affiliates.module on line 470 and defined in db_query() (line 2282 of /home/padbusin/public_html/draws/includes/database/database.inc).

 

When I disable the MS Core module, I am able to access the dashboard.

 

padmarketing
Offline
Joined: 10/12/2011
I have the affiliate and Pay

I have the affiliate and Pay to publish modules.

 

I can have ms core, ms pay to publish turned on and I can access the dashboard.

But if I turn on ms affiliate or ms credit I get errors:

 

ms affiliate error:

Recoverable fatal error: Argument 2 passed to db_query() must be an array, integer given, called in /home/padbusin/public_html/draws/sites/all/modules/ms_affiliates/ms_affiliates.module on line 470 and defined in db_query()

 

ms credit error:

PDOException: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'expiration' in 'where clause': SELECT uid, SUM(credits) AS total_credits FROM {ms_credit_transactions} WHERE uid = :uid AND (expiration = :zero OR expiration > :now) GROUP BY uid; Array ( [:uid] => 3 [:zero] => 0 [:now] => 1320521558 ) in ms_credits_get_user_balance() (line 264 of /home/padbusin/public_html/draws/sites/all/modules/ms_core/ms_credits/ms_credits.module)

Leighton Whiting
Offline
Joined: 06/02/2009
Thanks for reporting these.

Thanks for reporting these. The Affiliates Suite bug has just been fixed, and will be in the next release tonight.

The MS Credits module snuck in to the last release accidentally before it was completely done. The next release of MS Core will have a working version, however you will need to uninstall the old (broken) MS Credits before it will work.

-Leighton

padmarketing
Offline
Joined: 10/12/2011
I have downloaded the Latest

I have downloaded the Latest of both core and affiliates module and I am now getting this error:

PDOException: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''10'' at line 1: SELECT COUNT(aid) AS aidnum, aid FROM {ms_affiliates_genealogy} GROUP BY aid ORDER BY aidnum DESC LIMIT :limit; Array ( [:limit] => 10 ) in ms_affiliates_top_affiliates_html() (line 471 of /home/padbusin/public_html/draws/sites/all/modules/ms_affiliates/ms_affiliates.module).

padmarketing
Offline
Joined: 10/12/2011
Issue remains

Recoverable fatal error: Argument 2 passed to db_query() must be an array, string given, called in /home/padbusin/public_html/draws/sites/all/modules/ms_affiliates/ms_affiliates.module on line 470 and defined in db_query() (line 2309 of /home/padbusin/public_html/draws/includes/database/database.inc).

 

This is happening when adding the top affiliates block to the dashboard.

padmarketing
Offline
Joined: 10/12/2011
Top Affiliates

Actually anywhere i use the top affiliates block gives me the fatal error.

Leighton Whiting
Offline
Joined: 06/02/2009
Strange, I'm not able to

Strange, I'm not able to duplicate this, and the code looks right in the latest release. Can you try the latest release from November 17th, and see if that fixes it? If you are already using that one, then can you try the dev  version? If that still doesn't work, can you open a support ticket and let me take a look at the site?

Sincerely,

Leighton Whiting

Twitter Feed