You can specify a range of lines to operate on. For example, to operate on all lines, (which is of course the default):
sed -e \"1,$ s/a/b/\"
I know it is not sed, but I feel that head gets the easiest and most flexible way:
sed
head
head -n -1 the-file
Use -2, -3... instead of -1, to retrieve all but the last two lines, etc.