MetaData Mismatch Warning
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 284
- Joined: Fri Oct 13, 2006 4:31 am
-
- Participant
- Posts: 284
- Joined: Fri Oct 13, 2006 4:31 am
What exactly did u specify in the modify stage?thebird wrote:I have faced similar problem- but when using the Aggregator Stage to do a summing. For the new aggregated column (which contains the aggregated value), the same warning was thrown, eventhough it was defined as Nullable NO.When I changed this to nullable YES, this warning disappeared.
I then included a modify stage to convert this field to a Nullable NO field.
Regards
The Bird
-
- Participant
- Posts: 284
- Joined: Fri Oct 13, 2006 4:31 am
Sure, you can sign up for premium content at any time you wish to see a lot of informational and (hopefully) helpful content.
AMT(SUM) is a new column and not in your DDL, it can have different metadata. When you are sure that a warning message is handled appropriately, you can demote it to informational.
AMT(SUM) is a new column and not in your DDL, it can have different metadata. When you are sure that a warning message is handled appropriately, you can demote it to informational.
-
- Participant
- Posts: 284
- Joined: Fri Oct 13, 2006 4:31 am
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Aggreagator calculated columns are delivered as dfloat.
There is a "Decimal Output" property that you can deploy to manage them as decimal. This is available for the output link as a whole (as Default to Decimal Output), or for individual fields (as Decimal Output).
There is a "Decimal Output" property that you can deploy to manage them as decimal. This is available for the output link as a whole (as Default to Decimal Output), or for individual fields (as Decimal Output).
Last edited by ray.wurlod on Fri Nov 17, 2006 11:38 am, edited 1 time in total.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 284
- Joined: Fri Oct 13, 2006 4:31 am
I am afraid but I can't view the Premium Content. Anyway, we are getting off the track here. Where does this dfloat come from? I have used Aggregator in my job and have been able to see off one warning(Refer my first post in this thread. The first warning is not appearing now after using Aggregator). Now the only warning that remains is given below:
When checking operator: When binding output interface field "AMT" to field "AMT": Converting a nullable source to a non-nullable result;
a fatal runtime error could occur; use the modify operator to
specify a value to which the null should be converted.
I dont know why this is happening. How can it tell that the source is nullable...when I am damn sure it is not. Everything right from the source DB2 table to target flat file is non nullable I repeat NON NULLABLE. Then why DS is saying "Converting a nullable source to a non-nullable result"
As TheBird suggested I am thinking of using modify stage to convert nullable to non nullable. But in modify stage, it asks for specification. What should I give there? What is the syntax for that?
When checking operator: When binding output interface field "AMT" to field "AMT": Converting a nullable source to a non-nullable result;
a fatal runtime error could occur; use the modify operator to
specify a value to which the null should be converted.
I dont know why this is happening. How can it tell that the source is nullable...when I am damn sure it is not. Everything right from the source DB2 table to target flat file is non nullable I repeat NON NULLABLE. Then why DS is saying "Converting a nullable source to a non-nullable result"
As TheBird suggested I am thinking of using modify stage to convert nullable to non nullable. But in modify stage, it asks for specification. What should I give there? What is the syntax for that?
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Sign up. My previous post explained where the dfloat comes from. We need the funding to help to support the site - none of the premium posters is paid - it all goes to purchasing bandwidth and administration of the website.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 284
- Joined: Fri Oct 13, 2006 4:31 am
My problem is un resolved as of yet. Can anyone tell me the syntax of the function for converting nullable to non nullable? I wil use this in the modify stage. I am trying to use NullToValue function on the field AMT. I want the modify stage to convert any null value coming out of the previous stage to be converted to 0.00.
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
There is an error in the Parallel Job Developer's Guide in the Modify stage chapter. The name of the function that handles null values is incorrectly given as NullToValue(), which is the Transformer stage's function.
In a Modify stage the function you need to use is handle_null().
But didn't this thread begin as a question about generation of dfloat data by the Aggregator stage? How has it morphed into handling NULL in the Modify stage?!!
In a Modify stage the function you need to use is handle_null().
But didn't this thread begin as a question about generation of dfloat data by the Aggregator stage? How has it morphed into handling NULL in the Modify stage?!!
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 284
- Joined: Fri Oct 13, 2006 4:31 am
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Sign up or Search. My earlier post explained where the dfloat comes from. We need the funding to help to support the site - none of the premium posters is paid - it all goes to purchasing bandwidth and administration of the website.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 284
- Joined: Fri Oct 13, 2006 4:31 am
The problem has been resolved now. It was very simple. I wanted to carry forward the sum of the values of the field AMT from DB2 stage to a flat file. The metadata for AMT was decimal (9,2) and non nullable in the original table. But I came to know that when we perform a sum function in PX it always is defaulted as decimal(31,2) and nullable. So I just changed the metadata for the particular columnin the DB2 stage to suit the above. However the requirement was that in the flat file AMT should be decimal (9,2) and non nullable.
I put a transformer between the two stages wherein I declared a stage variable which had a null handling function. So the value of SUM(AMT) was loaded into the flat file as non nullable. In short decimal(31,2) was implicitly converted to decimal (9,2). That was cool and PX took care of that. No warnings were thrown.
One other thing..i am unable to mark this topic as resolved.Some bug in that. Please take a note
I put a transformer between the two stages wherein I declared a stage variable which had a null handling function. So the value of SUM(AMT) was loaded into the flat file as non nullable. In short decimal(31,2) was implicitly converted to decimal (9,2). That was cool and PX took care of that. No warnings were thrown.
One other thing..i am unable to mark this topic as resolved.Some bug in that. Please take a note