RE: Change Column data type on a BIG table
Posted in 2000
You could specify:
SELECT 'Creating table A....' FROM systables
WHERE tabid = 1;
or you could escape dbaccess and use the UNIX echo command:
! echo "Creating table A...."
The leading exclamation point escapes dbaccess and issues an UNIX command.
-----Original Message-----
From: vtnguyen
To: informix-list@iiug.org
Sent: 4/23/00 7:07 PM
Subject: Re: Change Column data type on a BIG table
Thanks for the reply,
1. The Informix version is Online 7.23.
2. My question about the select statement might not very clear.
Basically,
I would like to print messages for each SQL statements in the scripts.
For
examples:
PRINT A MESSAGE SAYING "Creating table A...."
Create table A (id int);PRINT A MESSAGE SAYING "Creating index AIDX..."
Create index aidx on A(id);...
...
The question is how do I display the messages to the console.
In Sybase I can do like:
select "Creating table A...."
Create table A (id int)select "Creating index AIDX..."
Create index aidx on A(id)
Thanks again for all your help
Tung Nguyen
Obnoxio The Clown wrote:
> From: vtnguyen <vtnguyen@home.com>
> >
> >The table has about 50 million records. The data type of one of the
> >columns currently is DECIMAL(13,2). We want to change it to
> >DECIMAL(9,2).
> >
> >What we did was:
> > Alter table TabA modify colA(9,2)> >
> >And it took forever (the server is running in no-log mode).
> >
> >Is there any other better/faster way?
>
> What version? Recent versions support in-place alter....
>
> >Another question about SQL in Informix
> >In Sybase I can do this:
> > select 'abc..... '
> >With Oracle I can do similar as:
> > select 'abc......' from dual
> >Can/how I do it on Informix?
>
> Huh? Can you have a SELECT statement in Informix? Of course.
>
________________________________________________________________________
> Get Your Private, Free E-mail from MSN Hotmail at
http://www.hotmail.com