The Zurich release has arrived! Interested in new features and functionalities? Click here for more

Difference between gs.nil(current.number) and current.number.nil()

Abhinab Achary1
Tera Guru

Hi All,

I just want to know the difference between using

gs.nil(current.number) and current.number.nil()

i am able to see the current.number.nil() in wiki but do there any user of ussing gs.nil(current.number) and if there is any can anyone help me understand how they are different. is the 1st one even valid?

Thanks,

Abhinab

9 REPLIES 9

snehabinani26
Tera Guru

I haven't came across using 1st now for any of my requirement. We always go ahead and use current.number.nil() option. I think 1st one is not valide.



Hope this helps you.


Abhinab Achary1
Tera Guru

I am waiting if some more people can validate as I came across this strange function in some of our implementation


vinitha3
Tera Guru

Hi,



current.fieldname.nil() or previuos.fieldname.nil() is used more than gs.nil()



gs.nil()


This should be Queries an object and returns true if the object is null or contains an empty string. Otherwise, it returns false.



I have also used !current.field.isNil() before, as well as the always trusty current.field != '' to indicate emptiness.



Thanks,


Vinitha.K


Is there really anything that calls gs.nil(object) at all


Thats what i want to knwo