Search notes:

set-winFileExtAssociation

Associate the extension .ext with the prog id progId. I copied this function from the excellent work of Danysys and the github repository PS-SFTA and then slightly adapted it for my purposes
set-winFileExtAssociation  png PBrush                   # associate .png with MS Paint
set-winFileExtAssociation .sql applications\code.exe

See also

Powershell module: winFileExtProgId

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/Windows/...', 1758200863, '216.73.216.150', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/Windows/PowerShell/modules/personal/winFileExtProgId/set-winFileExtAssociation/index(40): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78