0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

【保険商品管理システムの開発】シュミレーション履歴画面のエラー修正

0
Posted at

エラー内容

スクリーンショット 2025-10-26 10.38.02.png

このエラーは SQLite に AutoPremiumCalculationResults テーブルが存在しない ことが原因です。EF Core ではモデルを変更したら、マイグレーションを作成してデータベースに反映する必要があります。手順は以下の通りです。

1️⃣ マイグレーション作成

ターミナルでプロジェクトディレクトリに移動して次を実行:

dotnet ef migrations add AddAutoPremiumCalculationResults

• これで Migrations フォルダに新しいマイグレーションが作られます。
• AutoPremiumCalculationResults テーブルが作成される SQL が含まれます。

2️⃣ データベース更新

dotnet ef database update

• これで SQLite にテーブルが作成されます。

修正完了

スクリーンショット 2025-10-26 10.42.36.png
画面表示ができました。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?