Hi,
Quote:
Originally posted by grofaty
Hi,
Is column USERS column in lib.tab table or you would like to get 'user' so the USER should be written?
Hope this helps,
Grofaty
|
Sorry, I should have done copy and paste :-/
There is a column USER in lib.tab. Here again with copy and paste:
db2inst1@dev:~> db2 'SELECT USER,ROW_NUMBER() OVER(ORDER BY USER) AS RN FROM lib.tab FETCH FIRST 5 ROWS ONLY OPTIMIZE FOR 5 ROWS'
SQL0104N Auf "" folgte das unerwartete Token "(". Zu den möglichen Token
gehören: ", FROM INTO". SQLSTATE=42601
I know that USER is a reserved word and that i should better use e. g.
SELECT lib.tab.USER FROM lib.tab ... but for my problem it doesnt matter, it appears when i add row_number() to the query.
Thank you very much for your help so far.
kind regards
.Ape