Discussion (2)0
Log in or sign up to continue

return $s(type["uc":"Unable to correct-"_$case($p(type,"uc",2),4:"Patient Collapse In",5:"Patient Collapse Out",8:"Collapse Reversal",:""),1:"")
The above example is that uses both $case and $select.

$ select doesn't do the same in the $case. $ select only proceeds if the first condition is true. If it is false it will not proceed.

$case is that it checks the first condition is true if not it will see what the default condition and executes it. If you given anything in the default.

Hope this helps if i am wrong please correct me.