We have a partitioned table in which we are running an update. The columns being updated are not part of the partitioning scheme but are part of the tables primary key.
create table val_time(
field_id integer not null,
ins_index smallint not null,
arr_index smallint not null,
pid integer not null,
value ingresdate not null,
packet_id integer not null default -1,
status i1 not null default 0
)
with duplicates,
nojournaling,
page_size = 32768,
location = (ii_database),
partition = (HASH on field_id
partition val_time_pp1,
partition val_time_pp2,
partition val_time_pp3,
partition val_time_pp4
),
security_audit=(table,norow)
The update is: update val_time set arr_index=0 where arr_index = -1
There are no cases in the table where this would cause a violation of the primary key.
To avoid an awful lot of unnecessary action from an associated rule we are doing this with set norules in effect.
[45676 , 2478 , 00002aaae04b8200, dmrreplace.c:313 ]: Thu Jun 14 14:10:28 2012 E_DM0022_BAD_MASTER_OP Invalid dmrreplace DMF operation on partitioned master ace.val_time.
45676 , 2478 , 00002aaae04b8200, qeq.c:3638 ]: ULE_FORMAT: qeferror.c:916 Couldn't look up message 30022 (reason: ER error 10903)
E_CL0903_ER_BADPARAM Bad parameter
45676 , 2478 , 00002aaae04b8200, qeferror.c:738 ]: Thu Jun 14 14:10:28 2012 E_QE009C_UNKNOWN_ERROR Unexpected error received from another facility. Check the server error log.
45676 , 2478 , 00002aaae04b8200, scsqncr.c:14023 ]: Thu Jun 14 14:10:28 2012 E_SC0216_QEF_ERROR Error returned by QEF.
45676 , 2478 , 00002aaae04b8200, scsqncr.c:14024 ]: Thu Jun 14 14:10:28 2012 E_SC0206_CANNOT_PROCESS An internal error prevents further processing of this query.
Associated error messages which provide more detailed information about the problem can be found in the error log, II_CONFIG:errlog.log
45676 , 2478 , 00002aaae04b8200, scsqncr.c:14024 ]: PQuery: UPDATE val_time SET arr_index = 0 WHERE arr_index = -1
45676 , 2478 , 00002aaae04b8200, scsqncr.c:14024 ]: Query: UPDATE val_time SET arr_index = 0 WHERE arr_index = -1
I've transferred the table in question (sans rules) to a test database and ran the update there with no problem. The table was structured and partitioned on the test database exactly as per the real one.
I suspect that this is some strange interaction with the rules on the table.
-----Original Message-----
From: Karl Schendel [mailto:schen...@kbcomputer.com] Sent: 14 June 2012 15:08
To: Ingres and related product discussion forum
Subject: Re: [Info-Ingres] Strange error when updating a partitioned table
On Jun 14, 2012, at 2:43 PM, Martin Bowes wrote:
> Hi All,
> On II 10.0.0 (a64.lnx/132)NPTL + p14200
> We have a partitioned table in which we are running an update. The columns being updated are not part of the partitioning scheme but are part of the tables primary key....
> The update is: update val_time set arr_index=0 where arr_index = -1
> There are no cases in the table where this would cause a violation of the primary key.
> To avoid an awful lot of unnecessary action from an associated rule we are doing this with set norules in effect.
> [45676 , 2478 , 00002aaae04b8200, dmrreplace.c:313 ]: Thu Jun 14 14:10:28 2012 E_DM0022_BAD_MASTER_OP Invalid dmrreplace DMF operation on partitioned master ace.val_time
> ...
> Anyone know what might be happening?
I think you have found a bug, and I have a bad feeling that it might not be fixed. Run your query with "set optimizeonly" and "set trace point op149"; is the top of the query plan an UPD or a PUPD? If it's PUPD, I think the partition DMR_CB is not being set up.
> We have a partitioned table in which we are running an update. The columns being updated are not part of the partitioning scheme but are part of the tables primary key....
> The update is: update val_time set arr_index=0 where arr_index = -1
> There are no cases in the table where this would cause a violation of the primary key.
> To avoid an awful lot of unnecessary action from an associated rule we are doing this with set norules in effect.
> [45676 , 2478 , 00002aaae04b8200, dmrreplace.c:313 ]: Thu Jun 14 14:10:28 2012 E_DM0022_BAD_MASTER_OP Invalid dmrreplace DMF operation on partitioned master ace.val_time
> ...
> Anyone know what might be happening?
I think you have found a bug, and I have a bad feeling that it might not
be fixed. Run your query with "set optimizeonly" and "set trace point op149";
is the top of the query plan an UPD or a PUPD? If it's PUPD, I think the
partition DMR_CB is not being set up.