spring-projects / spring-projects/spring-batch

Include "if not exists" in table creation scripts [BATCH-1729]

Open
#1,855 3 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

related-to: ddl-scripts type: enhancement
Dominant language
Java
Stars
3k
Forks
2.5k
Avg merge
6d 53m
Merged PRs (30d)
3

Description

Matthew T. Adams opened BATCH-1729 and commented

Adding conditional table creation to the creation scripts would be nice: CREATE TABLE IF NOT EXISTS ...

That way, the scripts could be run without having to have them bomb out because a table already exists. Using <jdbc:initialize-database ignore-failures="ALL" ... /> doesn't really help when you want to ensure that the schema either already exists or needs to be created.


No further details from BATCH-1729

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the database table-creation scripts referenced by the issue and review how they handle schemas that already exist. Update the relevant scripts so rerunning them does not fail on existing tables, then verify behavior across the supported database scripts or schema initialization checks.

Written by the indexing model from the issue text.

Assessment

Tech stack
sql
Domain
databases
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.