You need to sign in to do that
Don't have an account?
dgindy
Checking for Null returns
Ok. This would seem like a simple answer to find. I could be asking the wrong question.
I get an out of index error. nullvalue()? What should I be using to check if I have a data set being returned.
Code:
Overnight__c[] Overnight = [select Doctor__c,Oximetry__c,Patient__c,Task__c,Scheduled_Date__c,PCCName__c,id from Overnight__c where Oximetry__c=:OxTest[0].Id]; if(Overnight[0].Id != null)
I get an out of index error. nullvalue()? What should I be using to check if I have a data set being returned.
Thanks
then you can check the first entry of the array
so, something like this
if ( overnight.size() > 0 )
if ( overnight[0].id !=null )