|
So, giddy with excitement over getting the new TEXT column added to
the SYSPARTITIONSTAT view, I attempted to wrap the following into a
view:
SELECT A.DBXLIB as SRCPF_LIBR
, A.DBXFIL as SRCPF_NAME
, B.SYSTEM_TABLE_MEMBER as SrcMbrName
, B.SOURCE_TYPE as SrcMbrType
, B.LAST_SOURCE_UPDATE_TIMESTAMP as SrcMbrUpdT
, b.CREATE_TIMESTAMP as SrcMbrCrtT
, b.LAST_CHANGE_TIMESTAMP as SrcMbrLCTS
, b.TEXT as SrcMbrText
FROM QSYS.QADBXATR A
, LATERAL
( SELECT * FROM TABLE
( QSYS2.PARTITION_STATISTICS(A.DBXLIB, A.DBXFIL)
) AS X
) AS B
WHERE A.DBXATR = 'PF'
and A.DBXREL = 'Y'
and A.DBXTYP = 'S'
AND B.SOURCE_TYPE IS NOT NULL
But, when I wrapped the above query with "CREATE VIEW ABC AS (" and
")", I got
SQL7008: QADBXATR in QSYS not valid for operation. The reason code is
7. 7 -- A based-on table used in creation of a view is not valid.
Either the table is program described table or it is in a temporary
schema.
It doesn't appear to me that either reason provided applies to
QADBXATR in QSYS.
Ideas?
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.