If you have Civil War soldiers from Alabama in your family tree, you will want to check out the Alabama State Archives. Like many archives, this one offers a free genealogy resource for online visitors. The Alabama Civil War Service Database allows you to search in a variety of ways. You can search by first or last name, service branch, unit, company (or ship name) or company unit name. All search fields allow for partial entries, which is handy since names aren't always spelled the way you expect.
The results screen has columns for the name, branch, regiment, company unit, unit name and other info. Clicking on the individual's name will take you to a more detailed entry. This page includes full name, date and information of birth, date and information of death, date and information of discharge, branch, regimental unit, company unit and name, pension record, authority, marital status, occupation, date and information of enlistment, engagements, remarks and other information.
As with most databases, some entries have more fields filled than others. You may notice that some entries have only the surname for the soldier. While this can make things difficult if your ancestor is one of these individuals, hopefully the other information in the entry will be sufficient to identify them.