Dear webgeer

I have a strange issue: when installing Gmap I needed to maually create the table "location".
Eventually the update.php script was not able to create the table.
So I manually executed the query:

CREATE TABLE location (
        eid int unsigned NOT NULL default '0',
        type varchar(6) NOT NULL default '',
        name varchar(255) default NULL,
        street varchar(255) default NULL,
        additional varchar(255) default NULL,
        city varchar(255) default NULL,
        province varchar(16) default NULL,
        postal_code varchar(16) default NULL,
        country char(2) default NULL,
        latitude decimal(10,6) default NULL,
        longitude decimal(10,6) default NULL,
        source tinyint default '0',
        PRIMARY KEY  (type,eid)
      ) /*!40100 DEFAULT CHARACTER SET utf8 */;

Having done this Gmap does not work, and if I try to save a node with location information I am prompted with this error:
UNKNOWN COLUMN 'lid' in 'field list' query: INSERT INTO location (eid, lid, type, latitude, longitude, source) VALUES (8, 8, 'node', '45.88', '11.22', '1') in c:\programs\easyphp1-8\www\drupal_476\includes\database.mysql.inc in line 121.

As far as I know there shouldn't be any LID field in table LOCATION...
if I manually create the LID field as INTEGER everything seems to work... but I am afraid of breaking the Gmap schema...

I had the same error also with version 4.7.x-1.x, so I upgraded to 4.7.x-2.x
but with the same result.

It looks like I am the only one with this problem... can you please help?
Thank you

Comments

big67’s picture

Priority: Critical » Normal

Dear webgeer
after some searching I finally realised that the location module you refer to in the Gmap module page is not the "Gmap location" module that comes together with Gmap, but a different one.
Can you or somebody else please confirm that Gmap module needs a previous installation of the "location" module?
Best regards and thank you in advance
Big

big67’s picture

Category: bug » support

Changed to support request.

big67’s picture

Some update:
I realised that, as far as Drupal 4.7.x, the field 'lid' is not installed by Gmap module in the location table and this causes an error.
You need to install and enable the location module before installling Gmap: enabling the location module will set up correctly the location table in the database.
The location module can then be safely disabled.

bdragon’s picture

Status: Active » Closed (fixed)

I hope that nobody is still deploying new 4.7 sites.

Thanks for the debugging.