Automate

 View Only
  • 1.  Query to check is data exists

    Posted 02-13-2020 02:57
    Hi All,

    With use of query we can download data and check if this data is correct.
    But now I have a challenge.
    I need to know if all needed data is created already.
    An example:
    Materials are created and also inforecords must be created.
    The data in the inforecords must be checked.
    But as long as the inforecord isn't created there is no entry in the table.
    Using a query it won't find an entry and doesn't return data.
    How can I set up a query that gives a reply like f.e. "Record not created yet" if a record is not found?
    If there is no inforecord then it must still be created.

    Any ideas?

    kind regards,
    Jan

    ------------------------------
    Jan van Asseldonk | Consultant
    CTAC | +31629078169
    ------------------------------


  • 2.  RE: Query to check is data exists

    Posted 02-13-2020 09:57
    Hi Jan -

    This may not be the most sophisticated, but instead of using Query for this you could use Transaction to do an ME12 or ME13 by trying to open up into a PIR.  If there is one, you'd end up on the main PIR screen, if there isn't one, you'd get a hard stop saying "Info record for vendor XYZ and material 123456 does not exist".

    Thanks!

    ------------------------------
    JENNIFER HWANG | SE
    Winshuttle North America
    ------------------------------