Starting with Version 17 (Developer Preview) Opera includes a Search-Engine Manager, which allows the user to add his own search engines. But the default search engines included with Opera cannot be edited in this way! To edit them use the first part of this answer, Versions 15-16 can also use the second part:
Disabling the default Search Providers (because they take up many keywords I would rather use for other searches - I just left Google with the classical 'g')
To do so, you have to edit the default_partner_content.json which is usually found in C:\Program Files\Opera\resources\
You can edit it by hand, or just replace it's content with the following:
"name": "Google Search",
Embedding your custom Search Engines in the Web Data File (usually found in C:\Users\#username#\AppData\Roaming\Opera Software\Opera\ You can edit the SQLite3 format which is shared by Opera in 2 easy ways: Either install Chrome, create your custom searches and copy the Web Data File over to Opera.
Or edit the File using a free SQLite-Editor like http://sourceforge.net/projects/sqlitedbrowser/
(You should copy the Web-Data File to your home-folder, so you have full write-access, or opening the file may fail) There you can enter your own search-engines into the keywords table - most of the fields should be self-explaining...