Closed (duplicate)
Project:
RESTful Web Services
Version:
7.x-2.0-alpha2
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
7 May 2012 at 19:27 UTC
Updated:
6 Sep 2012 at 07:38 UTC
I just did a pretty basic fresh install and I'm getting this error on nodes and profile2s. Comments work fine.
PDOException: SQLSTATE[22P02]: Invalid text representation: 7 ERROR: invalid input syntax for integer: "1.json" LINE 5: WHERE (base.nid IN ('1.json')) ^: SELECT revision.vid AS vid, base.uid AS uid, revision.title AS title, revision.log AS log, revision.status AS status, revision.comment AS comment, revision.promote AS promote, revision.sticky AS sticky, base.nid AS nid, base.type AS type, base.language AS language, base.created AS created, base.changed AS changed, base.tnid AS tnid, base.translate AS translate, revision.timestamp AS revision_timestamp, revision.uid AS revision_uid FROM {node} base INNER JOIN {node_revision} revision ON revision.vid = base.vid WHERE (base.nid IN (:db_condition_placeholder_0)) ; Array ( [:db_condition_placeholder_0] => 1.json ) in DrupalDefaultEntityController->load() (line 196 of /drupal/includes/entity.inc).
Installed contrib modules with default settings:
Database is PostgreSQL 9.1
I've set the correct user access permissions.
Comments
Comment #1
hernangomez commentedI have the same problem with my PostgreSQL installation.
May i'm wrong, but i think there's an error on the SQL query because in the WHERE parameter instead of take the nid (1) it use the url parameter (1.son).
This
[:db_condition_placeholder_0] => 1.jsonshould be[:db_condition_placeholder_0] => 1Comment #2
hernangomez commentedComment #3
klausiI think this is a duplicate of #1003788: PostgreSQL: PDOException:Invalid text representation when attempting to load an entity with a string or non-scalar ID.
Using the format extension like ".json" or ".xml" is not recommended anyway - use the accept headers when possible.
Comment #3.0
klausiRemove unused contrib modules from list.