It will have no effect on SEO, no.
As for the changes, not quite - no
change
<Virtualhost 1.2.3.4:443>
[…]
ServerName www.yourdomainname2.com
ServerAlias *.yourdomainname2.com yourdomainname2.com
</VirtualHost>
to
<Virtualhost 1.2.3.4:443>
[…]
ServerName yourdomainname2.com
ServerAlias www.yourdomainname2.com
</VirtualHost>
I’m assuming since the certificate is only valid for the domain an www.domain then there are no “wildcard” subdomains.