Uploaded image for project: 'Apache MetaModel (Retired)'
  1. Apache MetaModel (Retired)
  2. METAMODEL-6

Get back update status after invoking executeUpdate(...)

    XMLWordPrintableJSON

Details

    • Wish
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 5.0.0
    • None

    Description

      In the current API design of MetaModel, the DataContext.executeUpdate(...) method is a void method. This was initially chosen because not all implementations have the capability to report anything about a particular update. But some do, for instance the no. of inserted, updated or deleted records from a JDBC call. It would be nice to expose this information when available.

      My suggestion for this would be to let the DataContext.executeUpdate(...) method return an object with this information. All methods on the new object type would be optionally returning null, if no information is available. But when available, we can at least expose it this way.

      The change wouldn't have a major impact, since any project using MetaModel would already need to recompile because of the namespace change to org.apache.metamodel. And the change would be compile-time compatible with having a void return type.

      Attachments

        Activity

          People

            kaspersor Kasper Sørensen
            kaspersor Kasper Sørensen
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: