Welcome to OCS Inventory NG community support, where you can ask questions and receive answers from other members of the community.

Please ask questions only in English or French.

Release 2.11.1 available

The official documentation can be found on http://wiki.ocsinventory-ng.org. Read it before asking your question.

Problem with multi-criteria search


We have a problem with the multi-criteria search, in particular with the "Machines not seen in more than 5 day(s)" information displayed at the top of the Welcome page.

Using the DEBUG mode, we can see the SQL syntax used for this request (as of today January 23rd ) is the following:

SELECT SQL_CALC_FOUND_ROWS hardware.ID AS hardwareID , hardware.DEVICEID AS hardwareDEVICEID , hardware.NAME AS hardwareNAME , hardware.WORKGROUP AS hardwareWORKGROUP , hardware.USERDOMAIN AS hardwareUSERDOMAIN , hardware.OSNAME AS hardwareOSNAME , hardware.OSVERSION AS hardwareOSVERSION , hardware.OSCOMMENTS AS hardwareOSCOMMENTS , hardware.PROCESSORT AS hardwarePROCESSORT , hardware.PROCESSORS AS hardwarePROCESSORS , hardware.PROCESSORN AS hardwarePROCESSORN , hardware.MEMORY AS hardwareMEMORY , hardware.SWAP AS hardwareSWAP , hardware.IPADDR AS hardwareIPADDR , hardware.DNS AS hardwareDNS , hardware.DEFAULTGATEWAY AS hardwareDEFAULTGATEWAY , hardware.ETIME AS hardwareETIME , hardware.LASTDATE AS hardwareLASTDATE , hardware.LASTCOME AS hardwareLASTCOME , hardware.QUALITY AS hardwareQUALITY , hardware.FIDELITY AS hardwareFIDELITY , hardware.USERID AS hardwareUSERID , hardware.TYPE AS hardwareTYPE , hardware.DESCRIPTION AS hardwareDESCRIPTION , hardware.WINCOMPANY AS hardwareWINCOMPANY , hardware.WINOWNER AS hardwareWINOWNER , hardware.WINPRODID AS hardwareWINPRODID , hardware.WINPRODKEY AS hardwareWINPRODKEY , hardware.USERAGENT AS hardwareUSERAGENT , hardware.CHECKSUM AS hardwareCHECKSUM , hardware.SSTATE AS hardwareSSTATE , hardware.IPSRC AS hardwareIPSRC , hardware.UUID AS hardwareUUID , hardware.ARCH AS hardwareARCH , hardware.CATEGORY_ID AS hardwareCATEGORY_ID FROM hardware WHERE hardware.LASTCOME < 'str_to_date(01/18/2019 12:00, \'%m/%d/%Y %H:%i\')' GROUP BY hardware.id order by hardwareDEVICEID asc limit 0 , 10

The error returned for this request is :

You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ')' at line 3

Our setup is the following:


  • PHP Version :
  • Web Server :
  • Database Server :
  • Version OCSReports:
  • 7.2.14
  • Apache/2.4.6 (CentOS) PHP/7.2.14 mod_perl/2.0.10 Perl/v5.16.3
  • MariaDB Server version 5.5.60-MariaDB
  • 2.5


Could you please help us in troubleshooting this issue ?

Thanks in advance !

Best regards,


in OCS Inventory NG server for Unix by (120 points)

2 Answers

0 votes
please report this on github


I think you can't get any help here
by (23.1k points)
0 votes


I have exactly the same problem

my post

by (710 points)
Powered by Question2Answer