stable sorting and report copying

(19 posts) (3 voices)
  1. myDBR Team, Key Master

    Hi,
    1. Multi-column sorting is considered to be added for the future releases. Should do pretty much the same as the stable sorting.

    2. You can already copy a report under another name through the UI although it requires bit of work. Easiest way of doing this is that you:

    - You open up the report code
    - Select all paste the code to another tab while renaming the procedure.
    - Execute the code i.e save the procedure
    - Attach the code to a new report.

    We'll take a look at the report copying feature.

    --
    myDBR Team

  2. aschwa, Blocked

    Thanks. What does the UI for multi-column sorting look like? Also, from my limited knowledge of mydbr, I think that the steps you outline in #2 does not take into account the things that are stored in the mydbr_params table (optional, default_value, title I think).

  3. myDBR Team, Key Master

    Thanks. What does the UI for multi-column sorting look like?

    No final decision has been made for the UI. Most likely user simply click's on column headers to add subsequent sort levels. We'll see what we can do to make the UI intuitive for the user when doing single level / multi level sort.

    Also, from my limited knowledge of mydbr, I think that the steps you outline in #2 does not take into account the things that are stored in the mydbr_params table (optional, default_value, title I think).

    That is true. For this the copying feature would be better. As said, we'll take a look at the report copying feature.

    --
    myDBR Team

  4. myDBR Team, Key Master

    Thanks. What does the UI for multi-column sorting look like?

    We've enabled the upcoming multi-column sorting in the online demo. Just click on headers to sort as usual, shift-click will extend the sort to multiple columns.

    --
    myDBR Team

  5. aschwa, Blocked

    Thanks.

    Any idea on the report copying feature?

    We just purchased a full MyDBR license to support the project :). We're trying to resolve a few things that we've run into:

    1. Is it possible for the user to be shown SQL errors? As far as I can tell, when a SQL error occurs, the stored procedure just stops where it was, and no error is displayed (the user sees a partial report).

    2. One thing that we're trying to resolve is the issue of shared code across stored procedures. We often have reports that are very similar, and copy-and-pasting may be problematic for maintainability.

    3. It would be really neat if there were some way to have all of the report code under version control, so that errors that are made could be reverted, and the history could be visibility.

  6. myDBR Team, Key Master

    Any idea on the report copying feature?

    It is on the TODO list. Hope to get in to the next update.

    1. Is it possible for the user to be shown SQL errors? As far as I can tell, when a SQL error occurs, the stored procedure just stops where it was, and no error is displayed (the user sees a partial report).

    We can look into improving error messages for the admin. Normal user should not see the internals for security reasons.

    2. One thing that we're trying to resolve is the issue of shared code across stored procedures. We often have reports that are very similar, and copy-and-pasting may be problematic for maintainability.

    Sharing code and logic between reports can quite easily be done by separating common logic to separate stored procedures that all reports can use (using call/exec). You can use temporary tables to pass information between the reports.

    3. It would be really neat if there were some way to have all of the report code under version control, so that errors that are made could be reverted, and the history could be visibility.

    One of the features we are planning to introduce is the export functionality where all myDBR related objects can be exported and then put into version control. In any case, keeping the code in version control is a good thing.

    --
    myDBR Team

  7. aschwa, Blocked

    Neat.

    I would think that a normal user should be allowed to know that some error occurred, though not the code or text of the error.

    Writing "helper" stored procedures is certainly possible. It would be nice if there were a cleaner interface for editing them as standalone objects.

    Would the export functionality know to export helper stored procedures and views? Would it dump them in a way that could be easily reimported to reconstruct everything?

    Regarding modularization of the code, another thing we've run into is that every once in a while, we want to build up a long complicated query which is the UNION of two almost-identical subqueries, but with subtle differences. It would be nice to avoid copy-and-pasting. The solution we've come to thus far has involved treating them as strings and using prepared statements that concatenate the subquery with itself. Do you have any other suggestions?

    Thanks.

  8. myDBR Team, Key Master

    I would think that a normal user should be allowed to know that some error occurred, though not the code or text of the error.

    Yes, we'll see if this could be improved.

    Writing "helper" stored procedures is certainly possible. It would be nice if there were a cleaner interface for editing them as standalone objects.

    Any wishes you would have?
    myDBR allows direct editing of "helper" stored procedures dirtectly from the SQL Browser and if you have one in the currently edited report, you can highlight it and click "Show object" and you will have the full code in your disposal.

    Would the export functionality know to export helper stored procedures and views? Would it dump them in a way that could be easily reimported to reconstruct everything?

    Since all objects reside in myDBR's own database, we are able to distinquish reports from helper procedures quite easily.

    Regarding modularization of the code, another thing we've run into is that every once in a while, we want to build up a long complicated query which is the UNION of two almost-identical subqueries, but with subtle differences. It would be nice to avoid copy-and-pasting. The solution we've come to thus far has involved treating them as strings and using prepared statements that concatenate the subquery with itself. Do you have any other suggestions?

    Using prepared statements is sometimes handy, but using prepared statements in our opinion should be a last resort action. There are some downsides to using prepared statements (more difficult optimizations, more error-prone code, more difficul maintenance). In general, you should be fine using normal stored procedures and perhaps break down the code a bit if identical logic exists.

    --
    myDBR Team

  9. brad@foreverybody, Blocked

    i'd like to give a +1 to error reporting for admin. that would make my day.

  10. aschwa, Blocked

    Hello myDBR team. Congratulations on 2.0. Did either the error reporting or report copying features make it into this release?

  11. myDBR Team, Key Master

    Error reporting is improved. Admin should now get more detailed error messages. Report copying is still in the TODO list.

    --
    myDBR Team

  12. aschwa, Blocked

    Thanks. Can you provide an ETA for the report copying feature? If it will take a while, we will probably just write our own tool that modifies the backend manually.

  13. myDBR Team, Key Master

    We'll try to see that it will be in for the next release.

    We can see if you would get a sp for the backend stuff. Then you would just copy the proc and run the sp to copy the rest.

    --
    myDBR Team

  14. myDBR Team, Key Master

    FYI,
    Just wanted to confirm that report copying will be included in the next release.

    --
    myDBR Team

  15. aschwa, Blocked

    hi myDBR team. Just wondering whether you were considering the version control idea. It would be nice to be able to keep all of the relevant myDBR config under version control.

  16. myDBR Team, Key Master

    Yes, we've been working with that one as well.

    The first version of the tool that allows reports exported to version control should be available in next few days.

    --
    myDBR Team

  17. aschwa, Blocked

    Thanks. Will it be available in the next myDBR release or standalone?

  18. myDBR Team, Key Master

    It is a separate tool. See the post here.

    --
    myDBR Team


Reply

You must log in to post.