Re: Newbie help with determining whether a type exists and if so
Posted in 2000
Mark Rowell <markr@mutant-tech.com> wrote: >Hi > >I know how to create and drop types/procs/tables and I know how to determine >whether they exist or not but I try something like: > >IF select count(*) from sysxtdtypes where name='name_t' > 0 THEN > DROP TYPE name_t RESTRICT >ENDIF Select your count into a variable and then do your evaluation against the variable. > >But of course I get a syntax error. > >Is there something similar to the EXISTS keyword in Sybase/SQLServer e.g. > >IF EXISTS select * from sysxtdtypes where name='name_t' THEN > DROP TYPE name_t RESTRICT >ENDIF > >Thanks > >Mark Rowell > > carlos Currently on hiatus from unemployment. ---------------------- Do you do Linux? :) Get your FREE @linuxstart.com email address at: http://www.linuxstart.com