Convert the sentence into indirect speech.
He said, "I am going to the store."
He said that he was going to the store.
Complete the following task based on the instruction and optional input provided.### Instruction:
Convert the sentence into indirect speech.

### Input:
He said, "I am going to the store."

### Output:
He said that he was going to the store.