You need to sign in to do that
Don't have an account?
Is there a delay in new records being available to visualforce/apex soql searches?
My first post to this group I'm stumped, thank you for any help
I've created a simple visualforce page to search fields on a cusotm object.
I originally imported around 38,000 records with data loader BEFORE I build the page... these records are found by my search page just fine.
Just when I have my page the way I want it will not find any NEW records I create, either by doing them one at a time through the regular UI, or by importing them.
I'm searching on the "Name field" so nothing fancy, and System Admin is the only user as this is a new production system so I don't think permissions are the problem...
Any help?
SOSL is subject to the limitations of the Search Index Engine (or whatever it's technical term is called). The SIE (as I'll call it) farms records for indexing as they're created; bulk inserts usually take a while to catch up (a few seconds to a few minutes at most, unless the system specifically tells you that the SIE is behind). SOSL is therefore considered to be an index-only query. SOQL does not suffer from this limitation, as it uses an indexed table scan. The results are slower, but are always accurate to precisely what is in the database when you perform the query. If you are experiencing problems, I would suggest you look at your filters. Also note that you might be running into some Visualforce limitation on number of rows, heap space, or some other condition. If all else fails, try submitting a case to the Developer Support Team. You can also post your code (if you're allowed), and we'll see if we can help you out with the problem. I suspect that it might be difficult to reproduce, but if you have an obvious error, we should be able to spot it.
Thank you for the reply, I've posted by code below as I don't really think I know the difference between SOSL, and SOQL, (I'm coming from PHP here you'll be able to tell!)
This is just a custom object called "companies" and once all of our data is imported it will not change too much so which ever way our users can search faster is better for us.
Again no problem returning any OLD records... just not NEW records....
However the built in search function in salesfoce finds my NEW records just fine...