there are a bunch of ways to look at this (dynamite as a specific kind of explosive, dynamite as a stand in for explosives in general, dynamite in the context of what else we would use for similar purposes if dynamite specifically wasn't invented)
and most of them come out on top. It's main innovation is that its a more stable explosive, much safer to use. Without it, I think a lot more people would have died in mining and construction accidents. It's not typically the kind of thing used for warfare, but im sure it has been for some (but would they just use something else?)