Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merger equivalence with fusion <-> glpiinventory sql #359

Closed
falco2001 opened this issue May 16, 2023 · 3 comments
Closed

Merger equivalence with fusion <-> glpiinventory sql #359

falco2001 opened this issue May 16, 2023 · 3 comments
Labels

Comments

@falco2001
Copy link

falco2001 commented May 16, 2023

Describe the bug

Good morning,
is there an equivalance with this in glpiinventoty? Thank you
SELECT DISTINCT UPPER (B.name),A.remote_addr,D.name FROM glpi_plugin_fusioninventory_inventorycomputercomputers as A LEFT JOIN glpi_computers as B ON A.computers_id = B.id LEFT JOIN glpi_items_operatingsystems as C ON C.items_id = B.id LEFT JOIN glpi_operatingsystems as D on D.id = C.operatingsystems_id LEFT JOIN glpi_plugin_fusioninventory_agents as E on E.computers_id = A.computers_id WHERE TIME_TO_SEC(TIMEDIFF(NOW(),E.last_contact)) < 1200 AND (remote_addr LIKE ...

To reproduce

SQL error

Expected behavior

No wrong answer

Operating system

Linux

GLPI Agent version

1.4

GLPI version

10.0.7

GLPIInventory plugin

1.2.1

Additional context

No response

@falco2001 falco2001 added the bug Something isn't working label May 16, 2023
@stonebuzz
Copy link
Contributor

Hi @falco2001

remote_addr is now a column from glpi_agents table.

Link with asset is done with

itemtype = 'Computer' and items_id = ID

image

Best regards

@trasher trasher added support and removed bug Something isn't working labels May 16, 2023
@trasher trasher closed this as completed May 16, 2023
@falco2001
Copy link
Author

Thank you
Do you have any idea where I can find ?

  • last_contact in glpi_computers ? before it was in glpi_plugin_fusioninventory_agents
  • name LIKE 'Microsoft Windows 11% before it was in glpi_operatingsystems ?

@cedric-anne
Copy link
Member

@falco2001

Please use GLPI forums to get support. There are more people there, and you'll probably get answers faster than here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants