Why doesn't sc_lookup work in menu events?

The “Help” file says sc_lookup should work in menus. Specifically in onApplicationInit, onExecute, and onLoad

Assuming valid parameters and an established data connection why does

$check_sql = “SELECT Company Name FROM tbl_companies LIMIT 1” ;
sc_lookup(rs, $check_sql);

fail code generation with the meaningless logged error message () :

Thanks

Using sc9 the sc_lookup generates and works OK in every other application except menus (??!!) I’ll raise it as a bug.