What causes constant pain from stomach straight through back even whilst eating food?

Several things. This could be related to several things, including your pancreas, liver or gallbladder, depending on the location of your pain. You should see a physician who will take a complete history and perform a thorough medical exam before ordering the appropriate diagnostic tests.