i have a list. in that each and every approver need to approve. here i want to store the last approver name to a list column
in the "Common" tab of the references you can insert almost everywhere in your workflow, there is a "Last Task Respondent Display Name". This variable stores the name of the person who recently completed a task (e. g. an approval).
Which means after your first approval, you can put an "update item" action on your canvas and configure it to set your field with the value of "Last Task Respondent Display Name".
This get's a little more tricky if you assign a task to a whole group of users. But I can adress that too, if it's necessary for you.
I'm not sure I entirely understand your question, but if you are saying-
That sounds straightforward. You would create an "on modified" workflow that does roughly the following-
One thing to watch out for. You can't use the standard Sharepoint "Draft/Approved" functionality on the list. The standard SP feature makes any approved item non-approved (draft) again whenever the approved version is changed. However the workflow writing the approver name into a field constitutes a change, so whenever you approve an item a few seconds later the system will set it back to Draft !
You either have to "roll your own" Draft / Approved status field, and modify the list views to hide items based on your custom approval status column, or store the approver data in a separate list in a 1:1 relationship with the primary list.
My experience is that workflows and the built-in draft/approved feature just dont play together. You are better off to create your own.
Retrieving data ...