Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nested categories #1477

Closed
slodki opened this issue Mar 16, 2018 · 101 comments
Closed

nested categories #1477

slodki opened this issue Mar 16, 2018 · 101 comments
Assignees
Milestone

Comments

@slodki
Copy link
Contributor

slodki commented Mar 16, 2018

Ability to use multiple levels of nested categories will be nice. We manage categories as a tree already but limited to 2 levels.

Then reports based on categories should have parameter to aggregate values on first/second/third... categories level.

@slodki slodki added the feature label Mar 16, 2018
@vomikan
Copy link
Member

vomikan commented Mar 17, 2018

My opinion is better to provide "project" & "tags" functionality.
#896
#490

@slodki
Copy link
Contributor Author

slodki commented Apr 5, 2018

Categories are similar to tags, but are different. Transaction should belong to only one category and sum of categories should be always 100% (including empty/unknown/other category).

Category should be the first dimension for reports/analyses/etc. with ability to show or hide details of different levels. This is important for budgeting and accounting.
Tags could be the second dimension allowing ad-hoc tagging, selecting groups of transactions and crossing category boundaries, eliminating category duplication.

Tags can be nested too.

Our internal implementation for categories can use tags of specific type which enforce specific rules for category type tags. But storage, manipulation dialogs, filtering etc. could be the same.

@ovari
Copy link
Contributor

ovari commented Sep 7, 2018

+1 for "ability to use multiple levels of nested categories".

  • Required for importing Quicken files.
  • An example of a use case:
    1 Automobile
    1.1 Car1
    1.1.1 Gas
    1.1.2 Maintenance
    1.1.3 Parking
    1.1.4 Registration
    1.2 Car2
    1.2.1 Gas
    1.2.2 Maintenance
    1.2.3 Parking
    1.2.4 Registration

Thank you

@vomikan
Copy link
Member

vomikan commented Oct 6, 2018

For calculate car1 and car2 expenses it's enought to add tag, notes or some info into "check number" field.
Or add one more subcategory.

@vomikan vomikan closed this as completed Oct 6, 2018
@ovari
Copy link
Contributor

ovari commented Oct 6, 2018

A limitation of MS Money was only having a category and a subcategory, no nested categories. Please don't limit Money Manager Ex like MS Money was limited.

Nested categories are required to enable users to switch from Quicken to Money Manager Ex. Without nested categories another program is required, such as https://skrooge.org/

Please reopen this enhancement issue and implement nested categories.

Thank you

@slodki
Copy link
Contributor Author

slodki commented Oct 6, 2018

@vomikan So we can simplify MMEX even more: for calculate not only car expenses but many different things it's enough to have flat category list (without subcategories) and add tag, notes or some info into check number. Or to have no category list at all and add tag, notes or some info into check number... Or not use MMEX at all.

Categories are used in budgeting, reporting etc. and cannot be replaced with tags, notes or check numbers. Financial data uses hierarchical structure very often and this should be implemented in MMEX in the future. There is no reason to have category structure limited to arbitrary selected two levels in place of 0, 1, 3, 4, 5... levels.

@vomikan
Copy link
Member

vomikan commented Dec 2, 2018

I don't understand 'Nested categories'.
For gas 'Automobile:Gas' subcategiry is enought plus tag or notes 'CarX'.
In that case quite easy to calculate gas spending separatly for car1 and car2.

@slodki
Copy link
Contributor Author

slodki commented Dec 2, 2018

Example:

  • Transportation
    • taxi
    • uber
    • car
      • parking
        • monthly fee
        • parking meters
      • repairs
      • maintenance
        • inspections
        • parts
        • car wash
      • fuel
        • gasoline
        • LPG
    • bus
      • city card
      • single tickets

@vomikan
Copy link
Member

vomikan commented Dec 3, 2018

I am on the same point of view. Nested categories is complex to develop and excess for personal finances.
I'll prefer:
Other:transport (notes: uber)
Other:gass (notes: carX)
Other:parking

@ovari
Copy link
Contributor

ovari commented Dec 3, 2018

Personal accounting software from Intuit, Reckon, Quicken all provide nested categories in their desktop personal finance software range.

You can try old versions of Quicken by clicking here.

Nested categories in Quicken personal finance software has been available at least since the 1990s. Nested categories in Quicken was not, and still is not, complex nor excessive for personal finance software on 16-bit, 32-bit and now 64-bit versions of Windows.

@ovari
Copy link
Contributor

ovari commented Dec 3, 2018

The History of Quicken.pdf

"And the best is yet to come" with MoneyManagerEx.

@slodki
Copy link
Contributor Author

slodki commented Dec 4, 2018

No, nested categories are not complex to develop. The current MMEX categories implementation is hard to change and develop new features. Two different tables for storing the same object causes problems with updating structure (requires updating all db records) - i.e. moving an existing category in the hierarchy.
The proposed change is aligned with wxTreeCtrl control and separates categories hierarchy from transaction data. A category can be moved using a drag-and-drop wxTreeCtrl feature and only one field of moved category definition must be updated.
Dynamic reports with drill-down ability are very popular nowadays and can be easily implemented - see #1689 for a working example.

@vomikan Do you remember the famous Bill Gates statement (dated 1981):

Two levels of categories ought to be enough for anybody.

;-)

@vomikan
Copy link
Member

vomikan commented Dec 6, 2018

@slodki in 1981 I was 10 years old soviet boy. In my childhood there was no computers, programs and any available info regarding this. And then become 90x. There was no time for computers.

"The current MMEX categories implementation is hard to change and develop new features." Agree.
But now we implement a lot of changes and can't made stable release since 2 years ago.

@vomikan vomikan reopened this Dec 8, 2018
@vomikan
Copy link
Member

vomikan commented Dec 8, 2018

@vomikan vomikan modified the milestones: v1.5.3, v1.6.0 May 13, 2021
@vomikan
Copy link
Member

vomikan commented Jan 11, 2022

@luisdev
Copy link

luisdev commented Jan 18, 2022

@n-stein
Copy link
Contributor

n-stein commented Oct 20, 2022

I have a semi-working proof of concept for nested categories. My method discards the "SUBCATEGORY_1" table altogether and uses only the CATEGORY_V1 table to maintain a full relational hierarchy. Database is updated to include new columns to track the hierarchy level, parent, first child, and next sibling. You can walk the hierarchy easily via recursion.
image

Organize Categories now allows you to order in a true hierarchy. You can also have two categories of the same name, provided they have different parents. Drag & drop reassigns the entire subtree to a new parent as you would expect.
image

Selection works as expected in transaction dialogs, correct category is reported in checking lists.
image
image

Not sure if this is a direction we want to go in, just thought I'd put it forth for the sake of discussion.

@whalley
Copy link
Member

whalley commented Oct 20, 2022

@n-stein Personally I don't need this feature (tags would be better) but I know others have asked for it. But I do like the idea of removing the SUBCATEGORY table.

Out of interest, in terms of your DB structure, why do you need to maintain LEVEL, CHILDID, and NEXTID?

@ovari
Copy link
Contributor

ovari commented Oct 21, 2022

Thank you @n-stein for nested categories.

Does this allow for assigning multiple categories to a single transaction, i.e. Split Transaction? A Split Transaction is a great way to see a single transaction in more detail. Image below shows a Split Transaction Window from Quicken Personal 2004/Quicken Personal Plus 2004/Quicken CashBook 2004.
Split Transaction Window

Thank you

@tactilis
Copy link

Testing Version: 1.6.2-Alpha.1 64-bit commit: 1bfd4d2 (2022-11-22)

Dragging a category onto its own parent should do nothing.
Instead you are asked to confirm the move Yes or No - both of which do nothing.

mmex_ook6swPzfN.mp4

In the video, it is acceptable for nothing to happen if CCC is dropped onto BBB. However, it would be even better if the the 'CCC'
text that is being dragged became a 🚫 symbol (i.e. Prohibited) when over an invalid drop target.

n-stein added a commit to n-stein/moneymanagerex that referenced this issue Nov 22, 2022
@n-stein
Copy link
Contributor

n-stein commented Nov 22, 2022

PR #5369 contains fixes for everything identified so far. Will have to think about the changing drag symbol part.

n-stein added a commit to n-stein/moneymanagerex that referenced this issue Nov 22, 2022
n-stein added a commit to n-stein/moneymanagerex that referenced this issue Nov 22, 2022
n-stein added a commit to n-stein/moneymanagerex that referenced this issue Nov 22, 2022
n-stein added a commit to n-stein/moneymanagerex that referenced this issue Nov 22, 2022
n-stein added a commit to n-stein/moneymanagerex that referenced this issue Nov 22, 2022
@ovari
Copy link
Contributor

ovari commented Nov 23, 2022

I'll mark as fixed for now, I'm sure others will do more exhaustive testing.

Can a request for action to test the nested categories feature please be added to MMEX facebook, Twitter and any other social media page?

Perhaps a message could be posted like:

Help test "Nested categories" in MMEX development builds. Please report issues on GitHub. Thank you
https://moneymanagerex.org/docs/downloads/development/
#1477

What do you think?

Thank you

@whalley
Copy link
Member

whalley commented Nov 23, 2022

Can a request for action to test the nested categories feature please be added to MMEX facebook, Twitter and any other social media page?

My preference is to keep the testing to those that currently take the development builds before more widely circulating.

Most appropriate would be perhaps a post to the forums. But we need to be careful in wording to make sure that people know this is an 'Alpha' build and may contain bugs (along with some fixes of course 😁 ), and to fall back they need to revert to an older version of DB.

What we don't want is to have to answer numerous questions on why people can't open the DB now with the 'stable' version, etc.

@tactilis
Copy link

My preference is to keep the testing to those that currently take the development builds before more widely circulating.

I agree with you Mark.

We know from experience that we'd get a flood of questions from people don't know to revert to a backup DB.

If you(?) do put up a forum post, then I think this needs to be made explicit...

  • This Alpha build is for experienced MMEX users/testers only.
  • It should only be used with a copy of your database.
  • If you don't know how to revert to a backup database, then please don't install the Alpha.
  • If you don't know how to report problems effectively via github, then please don't install the Alpha.

@n-stein
Copy link
Contributor

n-stein commented Nov 23, 2022

I think budgeting in particular will benefit from the eyes of those who routinely use that feature. Honestly I had never even clicked the "Budget" icon in the nav panel until I started work on this issue. I might actually use it now that I have a bit of experience, I quite like it.

@gabriele-v
Copy link
Contributor

I haven't had time to test this major new change that looks really interesting, but I think that it deserves at least a 1.7.0 version, it's not a minor change.

Have you considered the impact on GRM SQL queries? Maybe we could consider adding a step during upgrade process which shows a warning in case some queries return results? In this case if a query (pseudosql) "Select count(*) from GRM where SQL like '%subcategory%'" returns > 0, a warning similar to "Database subcategories structure has been changed, please double check all your GRM reports" should be pop up after upgrade.

@n-stein
Copy link
Contributor

n-stein commented Dec 18, 2022

The standard GRM reports were already updated as part of this change, but good idea to check the user's custom reports.

@whalley
Copy link
Member

whalley commented Dec 18, 2022

Too late, the release is out. The release notes advise the user of the change and give advise.

@gabriele-v
Copy link
Contributor

You can retire it and reissue 1.7.0 with that change.
Still better than all the complains we will have for GRM not working IMHO.

@whalley
Copy link
Member

whalley commented Dec 18, 2022

We will get complaints regardless of whether we report a warning or declare in release notes. I view GRM users as power users and as such should be able to accomodate the change given the release notes and examples in the GRM templates.

nuvitong added a commit to nuvitong/general-reports that referenced this issue Dec 30, 2022
Categories are stored as adjacency list since 1.6.2
(moneymanagerex/moneymanagerex#1477)
nuvitong added a commit to nuvitong/general-reports that referenced this issue Dec 30, 2022
Categories are stored as adjacency list since 1.6.2
(moneymanagerex/moneymanagerex#1477)
nuvitong added a commit to nuvitong/general-reports that referenced this issue Dec 30, 2022
Categories are stored as adjacency list since 1.6.2
(moneymanagerex/moneymanagerex#1477)
@SJK55
Copy link

SJK55 commented Feb 2, 2023

What I can't work out it was fine in the releases before approx December. Why or what caused it to suddenly fail and take huge cycle time to not work? I've kept silent about my experience as I felt I was being too critical.

@tactilis
Copy link

tactilis commented Feb 2, 2023

What I can't work out it was fine in the releases before approx December. Why or what caused it to suddenly fail and take huge cycle time to not work? I've kept silent about my experience as I felt I was being too critical.

@SJK55 You have resurrected a Closed enhancement issue, the implementation of which was released in December.

It would be helpful if you could raise a new issue, explaining clearly the problem that you are experiencing in 1.6.3.

@SJK55
Copy link

SJK55 commented Feb 2, 2023

Martin please refer Search Feature issue introduced 1 - 2 updates ago not resolved #5606
I didn't realize this thread existed and N Stein posted to me the link to this
Definitely broken by #1477. Filtering currently works for top level categories, but not for nested.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

9 participants