I think in PostgreSQL you can use a function to generate your primary key in a table instead of just using auto_increment. Something similar to:
CREATE TABLE `blah` (
`id` bigint(20) unsigned NOT NULL my_generator_function(),
etc.
Where my_generator_function() would return a bigint.
Is that possible with MySQL or do I have to do that from the application code myself?
You can create a trigger –