
See 008: Trade Details (Part 1) for the start of this series
We are going to use the Grouping (also referred to as stacking) option to keep all history and visually clean up & fit more data into the trading pane. This is what we currently have:
(Click to zoom)

Grouping trades ONLY changes the view, it DOES NOT change internal calculations
Grouping allows you to logically follow the flow of trades. It also allows hiding the underlying actions that you may not want to see day-to-day. For example: You have multiple securities providing monthly dividends that could be grouped together so you only 'see' the security by default, but you can expand the view for details. Stocklog+ allows maximum flexibility so you can view it to make sense for you!

It's STRONGLY suggested keeping individual transactions & grouping vs modifying one row and deleting one row. You loose detailed history.
Some details:
- TradeID (TID): Unique ID for that transaction, it will never change or be reused. It is a visual reference for grouping
- P/C ID (PCID): Parent / Child ID used to group trades together. Only numbers from TID are valid
- Top-line Parent is TID + PCID = 0
- Parent can have a child or children
- Child can also be a Parent of a child/children
- You can immediately convert child to Top-line parent by entering zero (0) in P/C ID column

Be sure to select an Account from the Account drop-down before trying to add/delete/modify or group trades
Let's fix our TSLA trade first; because of the flexibility, you could do something like:
Option-->Assignment-->Options-->Sell of security
OR
Security assignment-->Options-->Sell of security
For this example, we're going to go with 'Option-->Assignment-->Options-->Sell of security' to follow a straight-line history of actions. We sold a Cash Secured Put (TID#5) first, that's going to be the top-line-parent. We were assign the shares (TID#7), this is going to be a child of (TID#5). Let's make it happen:
Double-click (DC) the PCID zero (0) on line TID#7, enter 5. You will immediately see a small arrow in the INFO column next to PCID#5

>> TID#7 is a CHILD of TID#5 >>

We then created Covered Calls for TSLA shares (TID#7). Change TID#8 & 9's PCID to 7, they are now children under TID#7. Finally, we sold TSLA separately, not under the Covered Call (we bought it back), so TID#10 becomes a child directly under TID#5.

<< TID#7 & 10 are children of TID#5 -->

<< TD#8 & 9 are children of 7
The panel is less noisy with all the TSLA trades that actually created one long trade over several months folded under TID#5, the start of this chain.
We need to decide how we want to show the close of the security. We choose to show the gain on TID#7 (bought @ 290 / sold @ 319.47) .vs. a short position gain on TID#10 (short @ 319.47 / buy back @ 290). To perform this, we debit TID#10 'close price' 319.47 to zero-out the credit/gain on that line. We then change TID#7 'close price' to 319.47:
Now, we group the MU tickers. We submitted a buy for 100 shares, the broker sold us two lots, 99-shares & 1-share; it's not unusual that your broker may split your buy/sell depending on how they can fulfill the transaction. We then wrote a Covered Call, that expired worthless, and we sold the stock for a .25/share gain. The expanded pane with all trades closed & showing expanded:
Finally, we show the collapsed grouping. This is easier to read: