This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

grp.exists()
#1
What is the simplest and minimum CPU power consuming way to check if there is a ga or alias with such name or address? I know about find but it has too much unnecessary data so maybe there is other way or maybe it would be nice to add other method which only returns true/false or add some additional parameter to find method to search if exists?
Done is better than perfect
Reply
#2
I don't think that you can gain much by replacing grp.find with something simpler. If you need to do grp.find very often then you should cache the data somehow, maybe do a db query to get all objects at once.
Reply
#3
(14.09.2018, 12:57)admin Wrote: I don't think that you can gain much by replacing grp.find with something simpler. If you need to do grp.find very often then you should cache the data somehow, maybe do a db query to get all objects at once.

I have a project with hotel and I am creating and updating ga's based on json so I am searching the most efficient way for checking such thing. Thanks for replyWink
Done is better than perfect
Reply


Forum Jump: