Re: Passing current_database to BackgroundWorkerInitializeConnection - Mailing list pgsql-hackers

From Jeremy Finzel
Subject Re: Passing current_database to BackgroundWorkerInitializeConnection
Date
Msg-id CAMa1XUgwWgVGt7j8zRHyKu=7xfQFAGyGd49F9QG5wdwuUB213w@mail.gmail.com
Whole thread Raw
In response to Re: Passing current_database to BackgroundWorkerInitializeConnection  (Andres Freund <andres@anarazel.de>)
Responses Re: Passing current_database to BackgroundWorkerInitializeConnection  (Andres Freund <andres@anarazel.de>)
List pgsql-hackers

What do you mean with "current database"? Before you
BackgroundWorkerInitializeConnection() there is no such thing?

My module is based directly off the worker_spi example. The worker is dynamically launched via SQL command. But in the worker_spi example, the database postgres is just hardcoded as the database in which to start the background worker process. Instead, I want to start it in the database in which I run the SQL command.

Thank you!

Jeremy 

pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: Change RangeVarGetRelidExtended() to take flags argument?
Next
From: Andres Freund
Date:
Subject: Re: Passing current_database to BackgroundWorkerInitializeConnection