To amplify the previous comments, your inserts into rda2, 3 and 4 are probably failing because you have a column mismatch. You have dropped the column chekval from rda1. Have you also dropped it from rda2, 3 and 4? If not the insert will fail because of the column mismatch as described by the other comments.
Albert

On 11/4/2014 10:23 AM, Hodges, Dennis wrote:

I have a process that extracts a single day's records, edits them and reinserts them into the permanent file.

I am running the following code in an EEP. Everything is working correctly except the next to last line (INSERT INTO daily3 SELECT * FROM rda3).

The problem is that I can run this exact code from the r:Prompt and it works fine, which in my sample data replaces 2 records, but in the EEP it only inserts the first of the 2 records. I have reviewed the table columns, keys/indexes, rules and triggers and can find no conflicts, in fact the daily3 table has no rules, etc. All rules are applied to the rda3 table.

Here is the segment of code in question.

DELETE ROWS FROM daily1 WHERE datex EQ "11/15/14" AND (priflag EQ "Y" OR priflag EQ "X")

DELETE ROWS FROM daily2 WHERE datex EQ "11/15/14"

DELETE ROWS FROM daily3 WHERE datex EQ "11/15/14"

DELETE ROWS FROM daily4 WHERE datex EQ "11/15/14"

DROP COL chekval FROM rda1

INSERT INTO daily1 (crew, datex, units1, units2, units3, units4, cmpsite1, cmpsite2, cmpsite3, cmpsite4, cr_page, priflag) SELECT crew, datex, units1, units2, units3, units4, cmpsite1, cmpsite2, cmpsite3, cmpsite4, cr_page, priflag FROM rda1

INSERT INTO daily2 SELECT * FROM rda2

INSERT INTO daily3 SELECT * FROM rda3

INSERT INTO daily4 SELECT * FROM rda4

*Dennis Hodges*

Maintenance Management Manager

FDOT Office of Maintenance MS #52

PH: (850) 410-5635

FAX: (850) 410-5511

[email protected] <mailto:[email protected]>

As far as we know, our computer has never had an undetected error.

Please note: e-mail may be subject to public disclosure.


Reply via email to