BEGIN
 IF NOT EXISTS (SELECT * FROM SYSCAT.TABLESPACES WHERE TBSPACE = 'S1')
  THEN EXECUTE IMMEDIATE 'CREATE TABLESPACE  S1';
 END IF;
END|
BEGIN
 IF NOT EXISTS (SELECT * FROM SYSCAT.TABLESPACES WHERE TBSPACE = 'S2')
  THEN EXECUTE IMMEDIATE 'CREATE TABLESPACE  S2';
 END IF;
END|
BEGIN
 IF NOT EXISTS (SELECT * FROM SYSCAT.TABLESPACES WHERE TBSPACE = 'S3')
  THEN EXECUTE IMMEDIATE 'CREATE TABLESPACE  S3';
 END IF;
END|
