zfs - get the name of the last snapshot

I have installed Solaris 11 Express on my server and want to set up automatic backuping using zfs snapshots. In the backup script I need to find out the name of the last snapshot of the given filesystem (in order to refer to it as the startpoint of an incremental backup). What is the best way to do that?

Thanks in advance,
Dusan

Each dataset has its creation time stored as a read-only native property:

zfs get creation pool/snapshot

Thanks for your reply.

When the script starts, it has no idea of what snapshots have been made so far. It first needs to find that out and choose the newest. After that's been determined, it can make a new snapshot and send the difference to the backup disk.

So the problem is I cannot call

zfs get creation pool/snapshot

directly - I first need to find out what snapshots to call it on.

I have the idea of calling

zfs list -t snapshot

and manually parsing the output for a list of snapshots made so far. Is this the easiest way to do that?

It seems to me that default output of

zfs list -t snapshot

is sorted by date of snapshot creation. Anyway, if you want to be sure, try this:

zfs list -t snapshot -o name,creation -s creation

Thank you bartus11! That help solved my problem.