I am getting the following error message in a OG group-node-panel-page with a 'content pane' view of group members.
"Notice: Array to string conversion in DatabaseStatementBase->execute() (line 2095 of /home/xxxx/public_html/xxx/includes/data"
Getting one message per row of the views output.
Error disappears when I revert views to earlier dev version(2011-06-06) ( not solved by the latest dev)

Drupal 7.2
Views 7.x-3.0-rc1
CTools 7.x-1.x-dev (2011-Jun-09)
Entity API 7.x-1.0-beta9
Organic groups 7.x-1.x-dev (2011-Jun-15)
Organic groups views 7.x-1.0
Panels 7.x-3.0-alpha3
References 7.x-2.0-beta3

Have done the usual rituals like clearing cache twice etc.. The exported view is in the attachment.

Comments

Vasu’s picture

Sorry about the incomplete error message in the above post. It is like this
"Notice: Array to string conversion in DatabaseStatementBase->execute() (line 2095 of /home/xxxx/public_html/xxx/includes/database/database.inc)"

bojanz’s picture

I get it on a VBO default view as well. I poked arond database.inc but got no enlightenment.

Andrew Schulman’s picture

Subscribing.

dawehner’s picture

@bojanz
Which vbo default view is this? This would be actually cool to have a easy to use views to reproduce the problem.

bojanz’s picture

admin_people (at admin/people2). Message shows once per row.

dawehner’s picture

Status: Active » Needs review
StatusFileSize
new1.37 KB

Thanks.

Okay the problem is get_value uses get_items at the moment.
But get_items assumes $this->items is set, but that's not the case here, because field_user_roles::pre_render set's the value.

So add a new 'raw' parameter for get_value

bojanz’s picture

Status: Needs review » Reviewed & tested by the community

Sounds good, and fixes the problem on my install.

amateescu’s picture

The patch from #6 worked for me too.

anon’s picture

patch in #6 works for me!

dawehner’s picture

Version: 7.x-3.0-rc1 » 6.x-3.x-dev
Status: Reviewed & tested by the community » Patch (to be ported)

Commited to 7.x-3.x.

This might need a backport.

manu.joseph’s picture

Thankz dereine... I made the following changes mentioned in the patch for the two files. Now the notice error disappears. Thank God..

geerlingguy’s picture

Patch fixes the issue in 7.x-3.x for me as well; hopefully next rc comes soon :)

jelle_s’s picture

patch in #6 works
+1 on #12!

k.halterman’s picture

Version: 6.x-3.x-dev » 7.x-3.0-rc1

I am a complete noob with php and Drupal. Exactly how do I apply a patch to an existing install of Drupal on my site? I have this same error:

Notice: Array to string conversion in DatabaseStatementBase->execute() (line 2137 of /home/content/49/8485049/html/aftermath/includes/database/database.inc).

I can reproduce it by adding and removing the user:roles field when following the views tutorial for creating a user list, trying to create a sort group for the roles users belong to. Thanks.

dawehner’s picture

Version: 7.x-3.0-rc1 » 6.x-3.x-dev

@k.halterman
Please test the dev version, as the patch is only there as far as i remember.
If there is still an issue better create a new issue, but write a report which shows what you did etc. so it's possible to reproduce the problem.

zeta1600’s picture

worked.

dawehner’s picture

hazit’s picture

Version: 6.x-3.x-dev » 7.x-3.7
Status: Patch (to be ported) » Active

Here's another noob with another string of errors:

Notice: Array to string conversion in DatabaseStatementBase->execute() (line 2168 of \includes\database\database.inc).
Recoverable fatal error: Object of class stdClass could not be converted to string in DatabaseStatementBase->execute() (line 2168 of includes\database\database.inc).

I just updated to Views 7.x-3.7 before this started happening. I am assuming the patch referred to above is in effect incorporated in this release (I may be wrong).

Do you think this is this still a problem with Views or something else?