I wrote a SQL query to evenly distribute leads to the user. The query runs perfectly on SQL Server, but not Sage CRM 7.1SP2. Any feedback is welcome! Thanks!
The query is below. Here is what I did ,and got the SQL errors. The expected result is when…