× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On 19 February 2018 at 11:19, Craig Richards <craig@xxxxxxxxxxxxxxxx> wrote:

But when the trigger fires and I execute an SQL insert in my RPG from
After.UniqueID into MessageID I see the following message in the joblog:

Message ID . . . . . . : SQL7939 Severity . . . . . . . : 00
Message type . . . . . : Information

Message . . . . : Data conversion required on INSERT or UPDATE.
-snip
I don't understand why there is conversion going on.
Am I missing something obvious?

Is the file being read and the file being updated the same files that
the compiler used? (Rule zero: check the library list)
What does the compiler listing cross reference say about the fields?
In particular, are there multiple definitions of either MESSAGEID or
UNIQUEID? Sub-procedure differs from main? (Rule one: trust the
compiler)
Is the program checking SQLSTATE after the INSERT/UPDATE? If so, is
there a deliberate reason to skip warnings like this?

I find some of these SQL errors hard to diagnose because there can be
multiple columns that have issues, and there's just one generic
SQLSTATE telling me that something went awry. It gets particularly
ugly when stored procedures, triggers, UDFs, and views of views are
involved. Is this particular program a simple TABLE to TABLE update
with no other Db2 functionality? I've scoured TRIGGER1 for hours when
it was really TRIGGER2 that had the issue. Doh!
--buck

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 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.