anchor.diff:  	}
   ----
   <1> Set the comment prefix and the separator in SQL scripts.
  +
  +
  +[[spring-testing-annotation-sqlmergemode]]
  +===== `@SqlMergeMode`
  +
  +`@SqlMergeMode` is used to annotate a test class or test method to configure whether
  +method-level `@Sql` declarations are merged with class-level `@Sql` declarations. If
  +`@SqlMergeMode` is not declared on a test class or test method, the `OVERRIDE` merge mode
  +will be used by default. With the `OVERRIDE` mode, method-level `@Sql` declarations will
  +effectively override class-level `@Sql` declarations.
  +
  +Note that a method-level `@SqlMergeMode` declaration overrides a class-level declaration.
  +
  +The following example shows how to use `@SqlMergeMode` at the class level.
  +
  +[source,java,indent=0]
  +[subs="verbatim,quotes"]
  +----
  +	@SpringJUnitConfig(TestConfig.class)
  +	@Sql("/test-schema.sql")
  +	@SqlMergeMode(MERGE) <1>
  +	class UserTests {
  +
  +		@Test
  +		@Sql("/user-test-data-001.sql")
  +		void standardUserProfile {
  +			// execute code that relies on test data set 001
  +		}
  +	}
  +----
  +<1> Set the `@Sql` merge mode to `MERGE` for all test methods in the class.
  +
  +The following example shows how to use `@SqlMergeMode` at the method level.
  +
  +[source,java,indent=0]
  +[subs="verbatim,quotes"]
  +----
  +	@SpringJUnitConfig(TestConfig.class)
  +	@Sql("/test-schema.sql")
  +	class UserTests {
  +
  +		@Test
  +		@Sql("/user-test-data-001.sql")
  +		@SqlMergeMode(MERGE) <1>
  +		void standardUserProfile {
  +			// execute code that relies on test data set 001
  +		}
  +	}
  +----
  +<1> Set the `@Sql` merge mode to `MERGE` for a specific test method.
   
   
   [[spring-testing-annotation-sqlgroup]]
  
positive.code: 	}
  ----
  
  ====== Script Execution Phases
  
  By default, SQL scripts are executed before the corresponding test method. However, if
  
negative.code: individual attributes in {api-spring-framework}/test/context/jdbc/Sql.html[`@Sql`] and
  {api-spring-framework}/test/context/jdbc/SqlConfig.html[`@SqlConfig`] for details.
  
  [[testcontext-executing-sql-declaratively-tx]]
  *Transaction management for `@Sql`*
  
  