In an interview or before an offer, when the interviewer asks me to
specify my salary expectation, should I give the amount that I want
I try to avoid discussing salary specifics as long into the interview process as I can. Before talking dollars, I want to know other aspects of the job, and assess if its a good fit for me otherwise, or not.
When I have to reply, I typically find it best to avoid a specific number, and to specify a range when asked my salary expectations. I might say "Somewhere in the high $60ks" or "I'm looking for something in the mid $100ks", depending on the numbers you are looking for.
In a few cases, the new job was particularly attractive and I might have be willing to settle for less than my current position. In those cases, I said something like "Well, I'm currently making $X, but I'm open to offers."
In my mind, at the bottom of the range I usually consider the minimum I must receive in order to feel that the position financially viable. At the top of the range I consider what I think I might reasonably receive in the best case, but not so high as to come across as unrealistic.
Remember that salary is just one component of a job offer. Benefits, perks, commute, possibilities for advancement, etc - all are important factors as well. Try not to specify a salary until you know as much as possible about other aspects.