function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
TaoTao 

Strange things of sosl ??

It seems like some problems happend in sosl...

A few days ago, a salesforce internal error occured when searching account with Name and Phone field by sosl. And It disappeared after 10 minutes.

And Now, I search account like this:

            tempTelNo2 = '03*';
            tempTelNo3 = '03%';
                FIND
                    :tempTelNo2
                IN
                    Phone FIELDS
                RETURNING
                    Account(Id
                        WHERE
                            TELNO1__c LIKE :tempTelNo3
                            OR TELNO2__c LIKE :tempTelNo3
                            OR ContactorTel__c LIKE :tempTelNo3
                            OR MobileTEL__c LIKE :tempTelNo3
                            OR OtherTelNo__c LIKE :tempTelNo3
                    ),
                    Contact(AccountId
                        WHERE
                            Phone LIKE :tempTelNo3
                            OR MobilePhone LIKE :tempTelNo3
                            OR Phone2__c LIKE :tempTelNo3
                    )
                LIMIT :limitTemp

There should be more 100000 records.
But I got only 4 records.
This just happened in AP.
It does not happen in Sendbox(CS06).
Any one knows why?...

bvramkumarbvramkumar
Few thoughts:

If you are trying to fine '03*' in Phone fields why is there a need to filter using '03%' on Account and contact. You want to re-filter accounts,contacts only on those specific phone fields?

The 4 records that were returned... are they expected records?

Can you find at least one difference between the row that is returned and the row that is not returned?

Is your "User" the owner of those 4 records. May be there is a OWD private sharing rule applied on accounts and contacts?
TaoTao

>If you are trying to fine '03*' in Phone fields why is there a need to filter using '03%' on Account and contact.

>You want to re-filter accounts,contacts only on those specific phone fields?

Yes, I want to re-filter accounts,contacts only on those specific phone fields.

 

>The 4 records that were returned... are they expected records?

I checked them, they are expected records.

 

>Can you find at least one difference between the row that is returned and the row that is not returned?

I checked that 4 records and a few of other records, their phone all starts with 03, no parent (Account). 

No difference I think.

(The data in text fields are different, like Name etc. I think it doesn't matter...)

 

>Is your "User" the owner of those 4 records. May be there is a OWD private sharing rule applied on

>accounts and contacts?

Actually, the owner is not my User.

But all of the records have the same owner. (Imported by another user.) 

 

By the way, When I change '03' to '0333', I got my desired result.