> most reliable method of testing if a table exists?
> ... I am using SQL Server compact edition.
I've only ever seen the kind of technique you've shown. You might get slightly quicker/simpler code by using ExecuteScalar and testing for DBNull.Value.
I know this doesn't help, but in SQL 2000+ I usually use this:
if object_id( 'RiaOrder', 'U' ) is not null
begin
....
end
Change the second parameter to 'P' for procedures.. see Books Online for more.