RE: Are NetSuite record ids guaranteed to be positive integers?
Answered
Hi,
I wonder if I can assume throughout my code that NetSuite record ids are numerical, or specifically positive integers (either in string or number form). Can I?
I’m passing the record id via a URL param to my Suitelet and would like to validate it before using, as an input that a (potentially malicious) user has control over.
Thanks!
Best answer
Hi,
Generally speaking, yes. You may find some negatives for standard records, e.g. the user who creates the account has an ID of -5, the administrator role has an ID of -3, etc.
If you’re talking transactions then they will always be positive.
Thanks,
Chris
Thanks!