While the news of cancer is always difficult , it is no reason to be sad! he is only 12 and has a host of medical alternatives to choose from depending on the type of cancer - which you did not suggest. As you know, cancer is not just one disease so as an oncologist, when someone says someone as cancer, to me that tells me very little. Cancers are different and treatments are also unique.
Research the type of cancer and how dogs go through it, ask your pet oncologist what s/he recommends and always get other opinions. Talk to others and there are several boards about this, some very specific to the type of cancer.
Good luck!!!! I do hope your dog will be fine!
"There are two means of refuge from the miseries of life: music and cats" Albert Schweitzer