Truusvlugindewind
Programmer
At the office we've got V8 on the mainframe (test only for now) and at home I've got V9 in my linux-laptop.
And now the business case is: 1 table with actual data, and 1 table with history-data. Can you delete rows from the actual table and store those in the history?
Hmm ... all those new features... can I do this in only 1 SQL?
So I think of this (AA = actual table/HH = history)
No go. Not valid SQL. try this:
even that does not work.
end-of-day: go home: laptop on lap:
1st SQL := no go
2nd SQL := yeah! it works
and now: confused. that "old table" thing was introduced in V8 right? Also for mainframe, right? then why does it not work?
And now the business case is: 1 table with actual data, and 1 table with history-data. Can you delete rows from the actual table and store those in the history?
Hmm ... all those new features... can I do this in only 1 SQL?
So I think of this (AA = actual table/HH = history)
Code:
insert into HH (a, b)
values
(select a, b from old table
(delete from aa))
Code:
select a, b from old table
(delete from aa)
end-of-day: go home: laptop on lap:
1st SQL := no go
2nd SQL := yeah! it works
and now: confused. that "old table" thing was introduced in V8 right? Also for mainframe, right? then why does it not work?