question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Identity column with seed in Oracle

See original GitHub issue

I’m getting “Specified cast is not valid.” when trying to use FluentMigrator.Oracle.OracleExtensions.Identity(syntax, FluentMigrator.OracleGenerationType.ByDefault, 1, 1)

This works fine: FluentMigrator.Oracle.OracleExtensions.Identity(syntax, FluentMigrator.OracleGenerationType.ByDefault)

Exception details: System.InvalidCastException: Specified cast is not valid. at FluentMigrator.Infrastructure.Extensions.AdditionalFeaturesExtensions.GetAdditionalFeature[T](ISupportAdditionalFeatures additionalFeatures, String key, T defaultValue) at FluentMigrator.Runner.Generators.Oracle.Oracle12CColumn.GetIdentityString(ColumnDefinition column) at FluentMigrator.Runner.Generators.Oracle.Oracle12CColumn.FormatIdentity(ColumnDefinition column) at FluentMigrator.Runner.Generators.Base.ColumnBase.Generate(ColumnDefinition column) at FluentMigrator.Runner.Generators.Generic.GenericGenerator.Generate(CreateColumnExpression expression) at FluentMigrator.Runner.Generators.Oracle.OracleGenerator.Generate(CreateColumnExpression expression) at FluentMigrator.Runner.Processors.ProcessorBase.Process(CreateColumnExpression expression) at FluentMigrator.Expressions.CreateColumnExpression.ExecuteWith(IMigrationProcessor processor) at FluentMigrator.Runner.MigrationRunner.<>c__DisplayClass79_0.<ExecuteExpressions>b__1() at FluentMigrator.Runner.StopWatch.Time(Action action) at FluentMigrator.Runner.MigrationRunner.ExecuteExpressions(ICollection1 expressions)`

Please advise how to get it working.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
BigYellowHammercommented, Oct 4, 2019

I believe this bug can be closed

0reactions
jzabroskicommented, Oct 4, 2019

Thanks for catching that.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Using the IDENTITY Column - NoSQL Database
Declare a column as identity to have Oracle NoSQL Database automatically assign values to it, where the values are generated from a sequence...
Read more >
Creating Tables With an IDENTITY Column
You can create an IDENTITY column when you create a table, or change an existing table to add an IDENTITY column using ALTER...
Read more >
Using identity column and DataSeeding with ...
Imagine a simple table USER with just an ID and NAME column (just for example). I want to use ID as an identiy...
Read more >
Adding an IDENTITY Column to an Existing Table
To add an IDENTITY column to a table, the table must be at a top level. You cannot add an IDENTITY column as...
Read more >
Oracle Identity Column: A Step-by-Step Guide with Examples
This tutorial shows you how to use the Oracle identity column to easily define an automatic generated numeric column for a table.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found