and when you have this loss. generally in time, the loss( I mean NOL, not the loss from stock exchange you have as a hobby) can be carried back to 5,4,3,2,1 years which is subject to rule changes
anyway, it is complicated. need to know the detail of the specific case