This is a discussion on dropping segments within the Sybase forums, part of the Database Server Software category; --> I have created a segment and exclusively allocated for a database 'test' . After that i created few objects ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| I have created a segment and exclusively allocated for a database 'test' . After that i created few objects on the segment. Now if iam trying to drop the segment ,it's saying segment is in use. I extended 'default' segment to that device so that all the objects will come on default once i will drop the segment. How to move all objects from a segment and drop the segment. (Creating clustered index is one way iam aware of) is there any other way of moving an objects from segments. 1. sp_addsegment test_seg,test,dev2 go Now the dev2 is exclusively used for the 'test' database. 2. sp_extendsegment "default",test,dev2 go 3. sp_dropsegment seg1,test go Msg 17522, Level 16, State 1: Server 'FOREXDB125', Procedure 'sp_dropsegment', Line 200: The segment 'seg1' is being used. what are the ways of moving objects from segments.A Regards |
| ||||
| "Lalit" <issues_sybase@hotmail.com> wrote in message news:7bcd3933.0312200134.4398cfae@posting.google.c om... : I have created a segment and exclusively allocated for a database : 'test' . After that i created few objects on the segment. : Now if iam trying to drop the segment ,it's saying segment is in use. : I extended 'default' segment to that device so that all the objects : will come on default once i will drop the segment. : : How to move all objects from a segment and drop the segment. : (Creating clustered index is one way iam aware of) : is there any other way of moving an objects from segments. : : 1. sp_addsegment test_seg,test,dev2 : go : Now the dev2 is exclusively used for the 'test' database. : : 2. sp_extendsegment "default",test,dev2 : go : : 3. sp_dropsegment seg1,test : go : Msg 17522, Level 16, State 1: : Server 'FOREXDB125', Procedure 'sp_dropsegment', Line 200: : The segment 'seg1' is being used. : : what are the ways of moving objects from segments.A : : Regards See http://sybooks.sybase.com/onlinebook...125;pt=65125#X and http://sybooks.sybase.com/onlinebook...506;pt=65125#X Hint: sp_placeobject '<name>', 'default' doesn't physically move the object, but assures that future allocations are made on specified segment. HTH, /Stefan |