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

How do I connect to a particular Schema? #278

Open
shaileshsolanki16 opened this issue Jul 4, 2022 · 1 comment
Open

How do I connect to a particular Schema? #278

shaileshsolanki16 opened this issue Jul 4, 2022 · 1 comment

Comments

@shaileshsolanki16
Copy link

Hello Rodel!

I added as string Schema= while setting up the environment variable SETX YUNIQL_CONNECTION_STRING="Host=localhost;Port=5432;Username=;Password=;Database=;Schema="

Below is the error and I think it is due to the addtional string Schema= in the connection string. Please let me know how do i mention the schema name.

ERR 2022-07-04 14:06:18Z Failed to execute run function. Couldn't set schema (Parameter 'schema')
Diagnostics stack trace captured a System.ArgumentException:
---> System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary.
at Npgsql.NpgsqlConnectionStringBuilder.GeneratedSetter(String keyword, Object value)
at Npgsql.NpgsqlConnectionStringBuilder.set_Item(String keyword, Object value)
--- End of inner exception stack trace ---
at Npgsql.NpgsqlConnectionStringBuilder.set_Item(String keyword, Object value)
at System.Data.Common.DbConnectionStringBuilder.set_ConnectionString(String value)
at Npgsql.NpgsqlConnectionStringBuilder..ctor(String connectionString)
at Yuniql.PostgreSql.PostgreSqlDataService.GetConnectionInfo()
at Yuniql.Core.MigrationService.Run(String workspace, String targetVersion, Nullable1 isAutoCreateDatabase, List1 tokens, Nullable1 isVerifyOnly, String bulkSeparator, String metaSchemaName, String metaTableName, Nullable1 commandTimeout, Nullable1 bulkBatchSize, String appliedByTool, String appliedByToolVersion, String environment, Nullable1 isContinueAfterFailure, String transactionMode, Boolean isRequiredClearedDraft)
at Yuniql.Core.MigrationService.Run()
at Yuniql.CLI.CommandLineService.RunRunOption(RunOption opts)
If you think this is a bug, please report an issue here https://github.com/rdagumampan/yuniql/issues.

Thank you,
Shailesh

@rdagumampan
Copy link
Owner

Hi @shaileshsolanki16 , thanks for reaching out! Im not sure I follow your use case but you its about setting up one database with multiple schema, please explore this option in local or test database and let me know.

https://github.com/rdagumampan/yuniql/releases/tag/v1.2.25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants