Skip to Main Content
IBM Power Ideas Portal


This portal is to open public enhancement requests against IBM Power Systems products, including IBM i. To view all of your ideas submitted to IBM, create and manage groups of Ideas, or create an idea explicitly set to be either visible by all (public) or visible only to you and IBM (private), use the IBM Unified Ideas Portal (https://ideas.ibm.com).


Shape the future of IBM!

We invite you to shape the future of IBM, including product roadmaps, by submitting ideas that matter to you the most. Here's how it works:

Search existing ideas

Start by searching and reviewing ideas and requests to enhance a product or service. Take a look at ideas others have posted, and add a comment, vote, or subscribe to updates on them if they matter to you. If you can't find what you are looking for,

Post your ideas
  1. Post an idea.

  2. Get feedback from the IBM team and other customers to refine your idea.

  3. Follow the idea through the IBM Ideas process.


Specific links you will want to bookmark for future use

Welcome to the IBM Ideas Portal (https://www.ibm.com/ideas) - Use this site to find out additional information and details about the IBM Ideas process and statuses.

IBM Unified Ideas Portal (https://ideas.ibm.com) - Use this site to view all of your ideas, create new ideas for any IBM product, or search for ideas across all of IBM.

ideasibm@us.ibm.com - Use this email to suggest enhancements to the Ideas process or request help from IBM for submitting your Ideas.

Status Not under consideration
Workspace IBM i
Categories Db2 for i
Created by Guest
Created on Mar 17, 2023

Foreign Key enhancement

I would like to request an enhancement to DB2.


Through the years, we have had various developers who have set up files and tables with different numeric data types, that hold the same data. For example, in one file, a Customer number might be defined as DEC(6) or PACKED(6) and in others it could be defined as NUM(6) or ZONED(6). Both fields refer to the same Customer Number. The values are the same, just the storage specification is different.


I would like to request that DB2 for i allows Foreign Key Constraints to be defined in this way. Currently, I can only define Foreign Key Constraints using PACKED(6) to PACKED(6) or ZONED(6) to ZONED(6). I cannot define a Foreign Key Constraints between a Customer Number defined as PACKED(6) in one table, and ZONED(6) in another table, even though that is a valid constraint.


The request would be to allow Foreign Key Constraints be implemented using Data types and Sizes, rather than an exact definition [ZONED(6) could be have a Foreign Key Constraint with a PACKED(6) data type.


Not having this capability is preventing me from more fully taking advantage of the the features of DB2 which would help with data quality by not having "phantom" records in the system, as well as helping to limit possibly erroneous data being added to table via ODBC Inserts and Updates.


Thank you.


Idea priority Medium
  • Guest
    Reply
    |
    Apr 18, 2023
    IBM does not intend to provide a solution to this Idea at this time, so it is being closed.

    While it is a valid request, the data base team has many higher priority requirements, so this request is not likely to be implemented anytime soon.

    As an alternative, you could consider improving your data model to use compatible data types. Using CREATE OR REPLACE TABLE to make this modification uses an industry leading technique to modify the table definition, without losing data.

    Db2 for i development team
    IBM Power Systems Development