How to use the «checkout_submit_all_after» event?

I’m developing module in magento 2. I have to save some data to another table. I try use event checkout_submit_all_after to catch event when customers submit order in checkout page but I can’t save own data to custom table. I tried copy code save data to another controller to test and it is working fine. Can you help me how to use event checkout_submit_all_after event in magento 2. Thanks

How is the checkout_submit_all_after event fired?

Case 1

Case 2

Case 3

Case 4

How is the checkout_submit_all_after event processed?

Example 1

Example 2

Example 3

Example 4

Thank you so much. I have problem when using event and get data from order but now all things working fine for me.

Thank You so much.