--------------------------------------------------------------------------
--
-- IDS 9.30 to IDS 9.2x reversion script for the Spatial DataBlade
--
-- You must execute this script (using DB-Access or SQL Editor)
-- before you can revert your server from 9.3 to 9.2x if the
-- following sequence of events describes your reversion scenario:
--   1. Bring up (or convert to) 9.3x server.
--   2. Register the Spatial DataBlade.
--   3. Revert to 9.2x server.
--
-- You do NOT have to run this script if the following sequence
-- of events describes your reversion scenario:
--   1. Bring up 9.2x server.
--   2. Register the Spatial DataBlade.
--   3. Convert to 9.3x server.
--   4. Revert to 9.2x server.
--------------------------------------------------------------------------

begin work;

drop function streamwrite(stream,ST_Point);
drop function streamread(stream,ST_Point);
drop function streamwrite(stream,ST_MultiPoint);
drop function streamread(stream,ST_MultiPoint);
drop function streamwrite(stream,ST_LineString);
drop function streamread(stream,ST_LineString);
drop function streamwrite(stream,ST_MultiLineString);
drop function streamread(stream,ST_MultiLineString);
drop function streamwrite(stream,ST_Polygon);
drop function streamread(stream,ST_Polygon);
drop function streamwrite(stream,ST_MultiPolygon);
drop function streamread(stream,ST_MultiPolygon);
drop function streamwrite(stream,ST_Curve);
drop function streamread(stream,ST_Curve);
drop function streamwrite(stream,ST_MultiCurve);
drop function streamread(stream,ST_MultiCurve);
drop function streamwrite(stream,ST_Surface);
drop function streamread(stream,ST_Surface);
drop function streamwrite(stream,ST_MultiSurface);
drop function streamread(stream,ST_MultiSurface);
drop function streamwrite(stream,ST_Geometry);
drop function streamread(stream,ST_Geometry);
drop function streamwrite(stream,ST_GeomCollection);
drop function streamread(stream,ST_GeomCollection);

drop function SE_SuppRelease();

delete from sysbldobjects where 
   bld_id like 'spatial.%' and obj_signature = 'stream.sql';
delete from sysbldobjects where 
   bld_id like 'spatial.%' and obj_signature = 'SE_SuppRelease ()';

commit work;
