I think some of the murkiness surrounding the origins of the "Hoodah" song comes from the fact that there are three distinct songs that converge in time and subject matter. The apparent first of these is "Ho! For California" written by Jesse Hutchinson of the popular Hutchinson Familay Singers. The sheet music for this was published in early 1849. The song was purportedly written for and performed as a send-off for a group of Massachusetts fortune hunters who were headed by land to the gold fields of California. The Hutchinson's were active in the abolitionist movement and the last verse and chorus managed to bring in their anti-slavery sentiments:
"O the land we'll save for the bold and braveHutchinson, incidentally borrowed melody elements from Dan Emmet's "Boatman Dance" song.
Have determined there never shall breathe a slave
Let foes recoil, for the sons of toil
Shall make California God's Free Soil.
Then, ho! boys ho!
To California go,
No slave shall toil on God's free soil
On the banks of the Sacramento.
Heigh ho! and away we go,
Chanting our songs of Freedom O.
Heigh ho! and away we go,
Chanting our songs of Freedom O."
My reading of Doerflinger is that the song that was sung on the ship LaGrange as it sailed for California also in 1849 was the Hutchinson song and not the "Hoodah" song.
The second song is Foster's "Camptown Races". This song was first published in February 1850 by F D Benteen of Baltimore under the title "Gwine to Run All Night, or De Camptown Races". The second part of the title stuck with the song and the second edition was called "The celebrated Ethiopian Song/Camptown Races" Foster wrote the song for the minstrel stage with a solo/chorus etc framework. He pursuaded Ed Christy's Minstrels to feature the song. It was hugely popular but not much of a money maker for Foster. In sever years it sold only about 5000 copies and Foster netted only a little over $100 before he sold all rights to it in 1857. It was probably too easy to remember and sing, so people didn't need the music. Richard Jackson in "Popular Songs of Nineteenth Century America" says the song was likely written in 1849 when Foster was in Cincinnati.
The third song is the "Hoodah" song more commonly known as "Banks of Sacramento". This song seems to be rather clearly a composite of the two previous songs. The melody is "Camptown Races" and so is the pattern of the verses; line/ Hoodah (Doo Dah) etc. The chorus lyrics are derived from the Hutchinson song. Specific verses and story lines were either created or brought in from other sea songs. Doerflinger supports this view "Tune and short refrains of Foster's son are combined in the shanty with the chorus of one introduced by the Hutchinson Family..." Irwin Silber in "Songs of The Great American West" includes both the Hutchinson song and the shanty and says basically the same thing.
One added element is that many of the versions of "Sacramento" make reference to trips around the Horn in 90 days (Lingenfelter, Hugill, Silber, Silverman). That timing was not achieved until after the famous American clipper ships began regular service on that route in 1851. Those sets of lyrics must be 1851 or later, i.e after both the Hutchinson and Foster songs gained pouplarity.