Is there any way to specify a default schema in a properties file using r2dbc-mssql?
The connection works fine with:
spring:
r2dbc:
url: 'r2dbc:mssql://zzzzz.database.windows.net:1433/dbname'
username: 'xxxxxx'
password: 'xxxxxx'
but i have to use a static schema:
@Table("schemaname.foo")
public class Foo {
@Id
private Long id;
I've found something similar in r2dbc-postgresql: https://github.com/pgjdbc/r2dbc-postgresql/issues/37
In a Spring Boot application, I think you can execute a sql statement to switch schemas in the
@PostConstruct
method of a@Configuration
class.