It's difficult to figure what his detached duty was summer of 1862. Could be as a teamster, guarding prisoners, hospital attendant, courier, etc.
George W. Thomas, 18 year old Student, resident of McKinly, Wilson County, Alabama, enlisted in Company D (Canebrake Rifle Guards) April 25, 1861 at Uniontown, Perry County, Alabama for one year, reenlisted December 11, 1861, Gallant & Meritorious Promoted to 5th Sergt. 1863, recorded on the Jan & Feb, 1865 at Absent, on detached service to bring clothing from Alabama for regiment, surrendered May 1865 and paroled at Demopolis, Alabama June 13, 1865,
,
THOMAS, George W., Sgt. (saved from a wound at Gettysburg by a Bible belonging to Harrison Patton REID and found earlier. The bullet hit the Bible but not the men || CV [Confederate Veteran Magazine] XIX:214; Hudson)
http://history-sites.com/~kjones/4dmstr.html
See also: http://myweb.cableone.net/mpenny1842/law%27salabamabrigade/lawalabrigade/regiments/al4th/index.html
http://history-sites.com/~kjones/CSal-az.html#AL-Inf
http://www.archives.state.al.us/referenc/alamilor/4thinf.html
http://www.civilwarhome.com/4alainf.htm
THE FOURTH ALABAMA INFANTRY.
The Fourth Alabama regiment, commanded by Col. Egbert
I. Jones, was organized at Dalton, Gal, May, 1861, and
immediately proceeded to Virginia. It fought with great
distinction at Manassas, Seven Pines, Cold Harbor, Second
Manassas, Boonesboro, Sharpsburg, Gettysburg,
Chickamauga, The Wilderness, Spottsylvania, battles around
Richmond and Petersburg. When General Lee surrendered
at Appomattox, the regiment numbered but 202 men.
Among the many officers who were killed in these battles
were Col. Egbert I. Jones and Captain Lindsay, both of
whom fell at Manassas; Capt. G. B. Mastin at Seven Pines;
William Lee at Malvern Hill; Lieut. C. C. Ferris at Second
Manassas; Capt. J. Sullivan at Sharpsburg; Colonel
McLemore at Boonesboro; Capt. J. Keith at Fredericksburg;
Capt. W. W. Leftwich at Gettysburg; Major Coleman at
Chickamauga; Captain Kidd at Chickamauga; Capt. Bayless
C. Brown at The Wilderness; Capt. H. Armistead at Gaines'
Mill; Capt. Alfred C. Price at Gaines' Mill, and Capt. A.
Murray at Petersburg.
Source: Confederate Military History, vol. VIII, p. 61