Corrupt CDR Search Results and csv export

When I do a 30-day search in the CDR, the search results and corresponding exported file are corrupt and show the wrong caller information ANONYMOUS. However, when I filter the search by caller ID, the CDR result is correct for the same record. The SQL record is also correct so the issue is ONLY in ASTPP. Look at the 3 examples of the same CDR record.

  1. CDR search export for 02/01/2024 - 03/24/2024. The caller info says ANONYMOUS
    “2024-03-23 19:23:33”,“15141234567 <15141234567>”,011551234567890,55,“Brazil Fixed”,1:02,0.016,0.0039,“NORMAL_CLEARING [16]”,Anonymous,“TATA Prime”,1-Silver,CALLINGCARD,outbound,

  2. CDR search for the same call by caller ID 15141234567. The caller info is John Smith (123456789123)
    “2024-03-23 19:23:33”,“15141234567 <15141234567>”,011551234567890,55,“Brazil Fixed”,1:02,0.016,0.0039,“NORMAL_CLEARING [16]”,“John Smith (123456789123)”,“TATA Prime”,1-Silver,CALLINGCARD,outbound,

  3. CDR search for the same call in the SQL table is also correct and point to the right user ID.
    “3f586399-b328-435b-ae28-b89444e0060e”,“6197”,“0”,“”,“15141234567 <15141234567>”,“011551234567890”,“”,“0”,“62”,“6”,“”,“1.1.1.1”,“NORMAL_CLEARING [16]”,“2024-03-23 23:23:33”,“0.016000”,“0.003900”,“51”,“4”,“0”,“^55.“,“Brazil Fixed”,“0”,“0.016000”,“0”,“0”,”“,“0.000000”,”^5514.”,“Brazil State of Sao Paulo”,“0.003500”,“0.003900”,“outbound”,“CALLINGCARD”,“0”,“0”,“0”,“0”,“0”,“1”,“0”,“0”,“2024-03-23 23:24:35”

This CDR is of course sanitized but it should be obvious that the CDR filter gives corrupted results which is a disaster as the CDR is used to bill our customers.

I would compare those results to what is exactly in the database itself.

I did. #3 is the SQL table record which is correct. ID 6197 links to John Smith (123456789123) in the accounts table which is correct. That’s the part that gets corrupted in the astpp CDR search.

It could be doing relational DB lookups You would have to check the code.