Quick Find occasionally causes SQL Error

Hello CRM community,

we're struggling with fixing Quick Find component on a system. 

Using Quick Find shows all the right results but occassionally when clicking a result CRM shows ERROR

"Unexpected Event: SQL Code 4145 EAccessViolation: Access violation at address 1A005320 in module 'eware.dll'. Read of address 00000000"

When reloading the error page, my search result I clicked on loads fine. 

I have received information that the Database Server seems to have crashed quite some time ago. Maybe this is in correlation to the problem. Not sure. 

What I have tried so far:

- Reinstall QuickFind

- Update Tomcat to latest version

- Metadata refresh

- Run the SQL request in Mgmt Studio = same result

Here is what SQL Log says:

I can see that the requests are not correct. Running them like this in Mgmt. Studio results in the same error message

Mrz 20 2026 14:20:03.936	9160	6288	1	fselectsql,time,sql,errormsg	16	select * from Person  WITH (NOLOCK)  where pers_companyid= AND pers_Deleted is null	Falsche Syntax in der Nähe des AND-Schlüsselworts
Mrz 20 2026 14:20:05.592	9160	6288	1	fselectsql,time,sql,errormsg	0	select * from Person  WITH (NOLOCK)  where pers_companyid= AND pers_Deleted is null	Falsche Syntax in der Nähe des AND-Schlüsselworts
Mrz 20 2026 14:20:20.790	9160	6288	1	fselectsql,time,sql,errormsg	16	select * from vcompany  WITH (NOLOCK)  where (comp_companyid=26235) AND (    SELECT *)	In der Nähe von ")" wurde ein nicht boolescher Ausdruck in einem Kontext angegeben, in dem eine Bedingung erwartet wird
Mrz 20 2026 14:20:23.088	9160	1816	1	fselectsql,time,sql,errormsg	16	select * from vcompany  WITH (NOLOCK)  where (comp_companyid=26235) AND (    SELECT *)	In der Nähe von ")" wurde ein nicht boolescher Ausdruck in einem Kontext angegeben, in dem eine Bedingung erwartet wird
Mrz 20 2026 14:20:23.096	9160	1816	1	fselectsql,time,sql,errormsg	0	select * from vcompany  where (comp_companyid=26235) AND (    FROM Custom_SysParams)	Falsche Syntax in der Nähe des FROM-Schlüsselworts

They are using Sage CRM 2025 R1

Anyone that has more ideas on how to troubleshoot this further? 

I'm glad for any ideas / input on this

Thanks

Simon

Parents
  • 0

    The 

    select * from Person  WITH (NOLOCK)  where pers_companyid= AND pers_Deleted is null

    is interesting. Can you please

    Check for Persons without a Company: SELECT pers_personid, pers_companyid FROM Person WHERE pers_companyid IS NULL
    Check for Company records with invalid parents or bad territory data.
  • 0 in reply to Sage CRM

    I have now checked the SQL request, which by SQL Log can't be run.
    select * from vcompany  WITH (NOLOCK)  where (comp_companyid=7908) AND (    SELECT *) shows the same error in SQL studio

    But when removing "AND ( SELECT *) 
    select * from vcompany  WITH (NOLOCK)  where (comp_companyid=7908)
    The request can be executed fine

Reply
  • 0 in reply to Sage CRM

    I have now checked the SQL request, which by SQL Log can't be run.
    select * from vcompany  WITH (NOLOCK)  where (comp_companyid=7908) AND (    SELECT *) shows the same error in SQL studio

    But when removing "AND ( SELECT *) 
    select * from vcompany  WITH (NOLOCK)  where (comp_companyid=7908)
    The request can be executed fine

Children
No Data