Giter VIP home page Giter VIP logo

Comments (5)

m-lopez-f avatar m-lopez-f commented on May 23, 2024

Good morning, Pandora 5.1 SP4 in pandoradb_migrate_5.0.x_to_5.1.mysql.sql have table tmodule_relationship and in this table column id_rt. Please check if you have this table and column in DB.

from pandorafms.

m-lopez-f avatar m-lopez-f commented on May 23, 2024

Good morning, in my test of this problem, I executed in next sequence:
Create database, insert data, execute pandoradb_migrate_5.0.x_to_5.1.mysql.sql and execute pandoradb_migrate_5.1_to_6.0.mysql.sql. What is your sequence used in first moment?.

from pandorafms.

MartinURU avatar MartinURU commented on May 23, 2024

Hello! Thanks for your help.

Our sequence is the same. But now also we tried this:

I checked out what u said, and i realise that when i run pandoradb_migrate_5.0.x_to_5.1.mysql.sql, i have the table tmodule_relationship but i havent the column.

We tried to create the column by ourselves and after we runned again the alter 5.1 to 6.0 and we received the folowing error mesage:

ERROR 1005 (HY000) at line 163: Can't create table 'pandora.#sql-87d_129' (errno: 150)

Our table is now like this:

mysql> desc tmodule_relationship;
+----------------+---------------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+----------------+---------------------+------+-----+---------+----------------+
| id | int(10) unsigned | NO | PRI | NULL | auto_increment |
| module_a | int(10) unsigned | NO | MUL | NULL | |
| module_b | int(10) unsigned | NO | MUL | NULL | |
| disable_update | tinyint(1) unsigned | NO | | 0 | |
+----------------+---------------------+------+-----+---------+----------------+
4 rows in set (0.00 sec)

Also we see this on the script:

ALTER TABLE tmodule_relationship ADD FOREIGN KEY (id_rt) REFERENCES trecon_task(id_rt) ON DELETE CASCADE;
ALTER TABLE tmodule_relationship MODIFY id_rt int(10) unsigned NULL default NULL;

Why the relationship its created before modify the column? This is normal? may be we have an old version of the script?

from pandorafms.

m-lopez-f avatar m-lopez-f commented on May 23, 2024

What is your version of PandoraFMS?, because in 43b3ef2 was added this column, if your version is before of this date, can you execute this line: "ALTER TABLE tmodule_relationship ADD COLUMN id_rt int(10) unsigned NOT NULL DEFAULT 0; " and the problem is fixed.

from pandorafms.

MartinURU avatar MartinURU commented on May 23, 2024

Thanks a lot!!! Now its working! We add that line in our script 5.0 to 5.1 and now is fixed. Pandora's sql 5.1 to 6.0 also runs ok. Excelente amigo! Abrazo desde Uruguay! :P

from pandorafms.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.