Giter Site home page Giter Site logo

MESSAGES in Exception about styleguides HOT 2 OPEN

sap avatar sap commented on June 11, 2024 3
MESSAGES in Exception

from styleguides.

Comments (2)

openPhiL avatar openPhiL commented on June 11, 2024

I prefer using raises this way, but not all the time I realize.
Just recently, I wanted to log "more" - And found out that inside the exception, you do not have access to the message you added to it with your syntax above.
I haven't worked with a 7.52 system where you can do
raise exception xxx using message, that would solve this problem.

from styleguides.

AndreasHauer-STELACON avatar AndreasHauer-STELACON commented on June 11, 2024

I would also add this! I constantly work with this type of exception handling.
Additionally, I put all relevant variables (msgid, msgty & msgno) into constants defined in an interface. This way I think exceptions are easy to read AND maintain.
Example:
RAISE EXCEPTION TYPE zcx_dummy MESSAGE ID zif_dummy=>c_msg_class-general TYPE 'E'
NUMBER zif_dummy=>c_general_msg-variable_not_found WITH variable.

from styleguides.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.