Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Automatic placeholder containing name of schema I'm operating on. #1384

Closed
janzankowski opened this issue Aug 1, 2016 · 1 comment

Comments

@janzankowski
Copy link

@janzankowski janzankowski commented Aug 1, 2016

Problem

I'd like to run a Flyway SQL script using the command line interface, and apply it in sequence to multiple schemas. Inside of the SQL script, I'd like to use a placeholder for the schema name that I'm currently operating on.

Proposed solution

Automatically define a placeholder variable with some distinct name, e.g. CURRENT_SCHEMA, containing the name of the schema that Flyway is currently acting on.

Existing workaround

Use -placeholders.myPlaceholder=.. option.

Why proposed solution is better than workaround

  • Shorter commands.
  • Avoid errors when I forget to specify the placeholder.
  • Avoid errors when I set placeholder to something else than the schema name specified in the Flyway URL.
@axelfontaine

This comment has been minimized.

Copy link
Member

@axelfontaine axelfontaine commented Nov 20, 2017

Related to #1039

@axelfontaine axelfontaine added this to the Flyway 5.1.0 milestone Nov 20, 2017
@MikielAgutu MikielAgutu closed this Nov 7, 2019
@alextercete alextercete added the r: fixed label Nov 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.