I don't believe that's quite the correct procedure. From the manual (http://www.porscheownersmanuals.com/2017-718-cayman-manual/17/305/Malfunctions-Power-windows)
Storing final position of windows
The final positions of the windows are lost after the battery is disconnected and reconnected. Windows automatic mode is not operative.
Perform the following steps for all windows:
- Close window completely once by pulling the switch to the second setting.
- When the window is completely closed, briefly pull the switch to the second setting again three times.
- Completely open the window once by pressing the switch.