truncate table stmt question
Posted in 2006
A user on IDS 9.40.FC8 got error -201 (syntax error) trying every form of TRUNCATE TABLE, despite the 9.4 syntax manual not flagging any restriction. Art Kagel quoted the manual saying TRUNCATE is only in Extended Parallel Server (XPS 8.x) and was a pending enhancement request for IDS. Other posters corrected this: TRUNCATE for local tables was actually added in IDS 10.00.xC4, as listed in that version's release notes. So the statement simply isn't available on 9.40 and requires an upgrade to 10.00.xC4 or later.
Auto-generated by DrWatson from the posts below — may be imperfect; read the full thread.
Topics: Installation, Setup & Upgrades, Triggers, Constraints & Referential Integrity
Hello, We recently upgraded to 94fc8. Per TFM, I am attempting to use the truncate table sql. It is generating the illuminating 201 error. The table has no constraints or views. It's data is generated via a trigger from a master table. syntax to date: truncate table yadda; truncate yadda; truncate only yadda; I saw a reference to this functionality being available only in XPS; however Syntax manual for 94 does not give that restriction. Thanks in advance, Doug
Doug Fossmeyer wrote: > Hello, We recently upgraded to 94fc8. Per TFM, I am attempting to use the truncate table sql. It is generating the illuminating 201 error. The table has no constraints or views. It's data is generated via a trigger from a master table. > syntax to date: > truncate table yadda; > truncate yadda; > truncate only yadda; > > I saw a reference to this functionality being available only in XPS; however Syntax manual for 94 does not give that restriction. From TFM: TRUNCATE Use the TRUNCATE statement for quick removal of all rows from a table and all corresponding index data. Only Extended Parallel Server supports this statement, which is an extension to the ANSI/ISO standard for SQL. In effect this only works in XPS (Informix 8.xx). There is an outstanding request to include this functionality in one of the next couple of releases. You'll have to await the official final features list for IDS 10.50 tentatively due out end of 2006Q4. Art S. Kagel
Doug Fossmeyer wrote: > Hello, We recently upgraded to 94fc8. Per TFM, I am attempting to use the truncate table sql. It is generating the illuminating 201 error. The table has no constraints or views. It's data is generated via a trigger from a master table. > syntax to date: > truncate table yadda; > truncate yadda; > truncate only yadda; > > I saw a reference to this functionality being available only in XPS; however Syntax manual for 94 does not give that restriction. From TFM: TRUNCATE Use the TRUNCATE statement for quick removal of all rows from a table and all corresponding index data. Only Extended Parallel Server supports this statement, which is an extension to the ANSI/ISO standard for SQL. In effect this only works in XPS (Informix 8.xx). There is an outstanding request to include this functionality in one of the next couple of releases. You'll have to await the official final features list for IDS 10.50 tentatively due out end of 2006Q4. Art S. Kagel
Actually this was introduced in 10.00.xC4. I use it in several jobs. Scott Crockford Art S. Kagel wrote: > Doug Fossmeyer wrote: >> Hello, We recently upgraded to 94fc8. Per TFM, I am attempting to use the truncate table sql. It is generating the illuminating 201 error. The table has no constraints or views. It's data is generated via a trigger from a master table. >> syntax to date: >> truncate table yadda; >> truncate yadda; >> truncate only yadda; >> >> I saw a reference to this functionality being available only in XPS; however Syntax manual for 94 does not give that restriction. > > From TFM: > > TRUNCATE > > Use the TRUNCATE statement for quick removal of all rows from a table and > all corresponding index data. > > Only Extended Parallel Server supports this statement, which is an extension > to the ANSI/ISO standard for SQL. > > In effect this only works in XPS (Informix 8.xx). There is an outstanding > request to include this functionality in one of the next couple of releases. > You'll have to await the official final features list for IDS 10.50 > tentatively due out end of 2006Q4. > > Art S. Kagel > _______________________________________________ > Informix-list mailing list > Informix-list@iiug.org > http://www.iiug.org/mailman/listinfo/informix-list > >
Hi all. Truncate statement is supported in 10.00.xC4. Here is a part of release note. ids_unix_relnotes_10.0.txt 1.5.1 New Features in 10.00.xC4 IBM Informix Dynamic Server, Version 10.00.xC4 contains the following new features: * TRUNCATE table support 1.5.1.1 TRUNCATE Table support TRUNCATE is a SQL keyword that quickly deletes active rows from a table and the b-tree structures of its indexes. The active rows are deleted without dropping the table or its schema, access privileges, triggers, constraints, and other attributes. With TRUNCATE TABLE, you can de-populate a local table and release (or reuse for the same table) the storage space that formerly held its data rows and b-tree structures. For more information, see the Guide to SQL: Syntax. Regards. -- Tsutomu Ogiwara from Tokyo Japan. >From: "Art S. Kagel" <kagel@BLOOMBERG.NET> >To: Doug Fossmeyer <DougF@SpokaneSchools.org> >CC: informix-list@iiug.org >Subject: Re: truncate table stmt question >Date: Wed, 30 Aug 2006 16:01:35 -0400 > >Doug Fossmeyer wrote: > > Hello, We recently upgraded to 94fc8. Per TFM, I am attempting to use >the truncate table sql. It is generating the illuminating 201 error. The >table has no constraints or views. It's data is generated via a trigger >from a master table. > > syntax to date: > > truncate table yadda; > > truncate yadda; > > truncate only yadda; > > > > I saw a reference to this functionality being available only in XPS; >however Syntax manual for 94 does not give that restriction. > > From TFM: > >TRUNCATE > >Use the TRUNCATE statement for quick removal of all rows from a table and >all corresponding index data. > >Only Extended Parallel Server supports this statement, which is an >extension >to the ANSI/ISO standard for SQL. > >In effect this only works in XPS (Informix 8.xx). There is an outstanding >request to include this functionality in one of the next couple of >releases. > You'll have to await the official final features list for IDS 10.50 >tentatively due out end of 2006Q4. > >Art S. Kagel >_______________________________________________ >Informix-list mailing list >Informix-list@iiug.org >http://www.iiug.org/mailman/listinfo/informix-list