Re: New to informix.
Posted in 1998
josephatl@mindspring.com wrote:
>
> Hello everyone. I'm new to informix & isql in general, so this is going to be
> simple for you.
>
> I need to know how to find the field names in all my tables, and then
Either run dbaccess mydatabase and choose table>info from the menus or
run dbschema -d mydatabase.
how to
> replace the value of a field in one record based on the value of another
> field. ie...:
>
> replace port_number with "5061" where switch_id = "2XO"
>
> but I don't know how to tell it which table to look in.
Assuming:
table A (
key1 int,
port_number int
)
table B (
key2 int,
key1 int,
switch_id char(3)
)
Then:
update table A set port_number = 5061 where A.key1 in (
select B.key1 from B where B.switch_id = "2X0");
Something like that?
Art S. Kagel