I have a problem with my wrapper & servers.
On my server (db210.5 c express on windows) having 3 databases(d1,d2,d3). I have created one more database as d4. By keeping the d4 as base, I created one wrapper & 3 servers for (d1,d2,d3) databases. I can able to access data, update & all other operations on all the tables under d1,d2,d3 databases. I am having the SYSADM privilege too.
All these things are happened fine till yesterday. But today, when my wrappers & servers are working fine. But I am facing some problem : as
I have a table called t1 on d1 database. From d4 i altered the table , added 2 more columns . On IBM data studio from d1 tab I can view the newly added columns on table t1. If I query the same table from d4 tab, i can't able to find the newly added columns.
I don't have any problem with my wrappers & servers because I am altering the federated tables from d4 database itself. I can find the newly added columns from d1, I can find the same table from d4 but without the newly added columns.
I don't know what might be the reason for this. As I haven't changed any server settings too.
Can someone kindly let me know, what might be the reason under this.
Just as I suspected. You essentially just did the same as altering the table directly on d1. What you need to do after this is to drop and recreate the nickname for d1.t1 on d4. This will force d4 to recreate the definition for the table in its own catalog.
I am trying a basic thing. Andy Kindly correct me.
I have created a nickname on table d1.s1.t1 as s1.t1.
Now I am trying to alter the d1.s1.t1 table from d4 using its nickname. I am getting the below error.
These are my statement. which I am trying alone( I mean as a statements not embedded in any procedures)
CREATE NICKNAME s1.t1 FOR d1.s1.t1 ;
ALTER TABLE s1.t1 ADD COLUMN id1 INTEGER NOT NULL WITH DEFAULT 0 ;
The statement references "t1" which identifies a(n) "NICKNAME" rather than a(n) "TABLE".. SQLCODE=-159, SQLSTATE=42809
According to this error :The above statement is expecting for a table name where it is occupied with nickname.
Can you please correct the syntax. And kindly excuse me If I am wrong.
Even I tried with different nickname (not as a part of original table name) it is still throwing the same error.
Can you tell me what are all the possible ways to alter a federated table programmatically.