Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » DBISAM Technical Support » Support Forums » DBISAM SQL » View Thread |
Messages 1 to 3 of 3 total |
Dropping an Index |
Mon, Sep 24 2007 6:50 PM | Permanent Link |
Allan Brocklehurst | hello;
Stats D4.25B2 I am in the middle of writing s Script that will create and alter a ton of tables this part is giving me allot of grief. I would like to have the "if Exists" Clause. This will be run remotely. DROPPING AN INDEX !!!! i tried DROP INDEX IF EXISTS "MTCode" ON "Facilities" ("MTCode"); and DROP INDEX "ELRLogTable"."User" and DROP INDEX "ELRLogTable.dat"."User" either way I'm not getting this at all any suggestions tia Allan B Attachments: brock.vcf |
Mon, Sep 24 2007 11:11 PM | Permanent Link |
"Donat Hebert \(Worldsoft\)" | Allan, you're close but here's the reference:
DROP INDEX [IF EXISTS] table_reference.index_name | PRIMARY You can also consider alter table with a redefine is you're changing the primary ... ie ALTER table table_reference Redefine Primary Key(IndexFieldnames) Compress FULL NOBACKUP; hth. Donat. "Allan Brocklehurst" <brock@ns.sympatico.ca> wrote in message news:22FDE073-C9AF-455B-A229-91DCD1841821@news.elevatesoft.com... > hello; > > Stats D4.25B2 > > I am in the middle of writing s Script that will create and alter a > ton of tables > this part is giving me allot of grief. > I would like to have the "if Exists" Clause. This will be run remotely. > > DROPPING AN INDEX !!!! > i tried > > DROP INDEX IF EXISTS "MTCode" ON "Facilities" ("MTCode"); > > and > > DROP INDEX "ELRLogTable"."User" > > and > > DROP INDEX "ELRLogTable.dat"."User" > > > either way I'm not getting this at all > > any suggestions > > tia > > Allan B > |
Tue, Sep 25 2007 8:26 AM | Permanent Link |
Allan Brocklehurst | Donat;
that's the ticket thanks. I also dropped the quotes Allan "Donat Hebert \(Worldsoft\)" <donat.hebert@worldsoft.ca> wrote: Allan, you're close but here's the reference: DROP INDEX [IF EXISTS] table_reference.index_name | PRIMARY You can also consider alter table with a redefine is you're changing the primary ... ie ALTER table table_reference Redefine Primary Key(IndexFieldnames) Compress FULL NOBACKUP; hth. Donat. "Allan Brocklehurst" <brock@ns.sympatico.ca> wrote in message news:22FDE073-C9AF-455B-A229-91DCD1841821@news.elevatesoft.com... > hello; > > Stats D4.25B2 > > I am in the middle of writing s Script that will create and alter a > ton of tables > this part is giving me allot of grief. > I would like to have the "if Exists" Clause. This will be run remotely. > > DROPPING AN INDEX !!!! > i tried > > DROP INDEX IF EXISTS "MTCode" ON "Facilities" ("MTCode"); > > and > > DROP INDEX "ELRLogTable"."User" > > and > > DROP INDEX "ELRLogTable.dat"."User" > > > either way I'm not getting this at all > > any suggestions > > tia > > Allan B > |
This web page was last updated on Tuesday, May 7, 2024 at 02:40 AM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |