Finally this is the script used.