Replication of column statistics with CRTDUPOBJ versus CPYF

You can replicate column statistics with the Create Duplicate Object (CRTDUPOBJ) or the Copy File (CPYF) commands.

Statistics are not copied to new tables when using the Copy File (CPYF) command. If statistics are needed immediately after using this command, then you must manually generate the statistics using iSeries™ Navigator or the statistics APIs. If statistics are not needed immediately, then the creation of column statistics may be performed automatically by the system after the first touch of a column by a query.

Statistics are copied when using Create Duplicate Object (CRTDUPOBJ) command with DATA(*YES). You can use this as an alternative to creating statistics automatically after using a Copy File (CPYF) command.

Related information
Create Duplicate Object (CRTDUPOBJ) command
Copy File (CPYF) command