├── .gitignore ├── cqrs ├── .mvn │ └── wrapper │ │ ├── maven-wrapper.jar │ │ └── maven-wrapper.properties ├── src │ ├── main │ │ ├── java │ │ │ └── ch │ │ │ │ └── martinelli │ │ │ │ └── demo │ │ │ │ └── cqrs │ │ │ │ ├── query │ │ │ │ ├── Product.java │ │ │ │ ├── OrderItem.java │ │ │ │ ├── FindOrders.java │ │ │ │ ├── Customer.java │ │ │ │ ├── PurchaseOrder.java │ │ │ │ ├── OrderQueryController.java │ │ │ │ └── OrderRepository.java │ │ │ │ ├── CqrsApplication.java │ │ │ │ └── command │ │ │ │ ├── OrderCommandController.java │ │ │ │ ├── OrderCommand.java │ │ │ │ ├── OrderCommandHandler.java │ │ │ │ ├── OrderController.java │ │ │ │ └── OrderService.java │ │ └── resources │ │ │ ├── application.properties │ │ │ └── db │ │ │ └── migration │ │ │ └── V001__Create.sql │ └── test │ │ ├── java │ │ └── ch │ │ │ └── martinelli │ │ │ └── demo │ │ │ └── cqrs │ │ │ ├── TestCqrsApplication.java │ │ │ └── api │ │ │ ├── query │ │ │ └── OrderQueryControllerTest.java │ │ │ └── command │ │ │ ├── OrderCommandControllerTest.java │ │ │ └── OrderControllerTest.java │ │ └── resources │ │ └── db │ │ └── migration │ │ └── V997__Product_Data.sql ├── HELP.md ├── pom.xml ├── mvnw.cmd └── mvnw ├── traditional ├── .mvn │ └── wrapper │ │ ├── maven-wrapper.jar │ │ └── maven-wrapper.properties ├── src │ ├── main │ │ ├── resources │ │ │ ├── application.properties │ │ │ └── db │ │ │ │ └── migration │ │ │ │ └── V001__Create.sql │ │ └── java │ │ │ └── ch │ │ │ └── martinelli │ │ │ └── demo │ │ │ └── traditional │ │ │ ├── repository │ │ │ ├── CustomerRepository.java │ │ │ └── PurchaseOrderRepository.java │ │ │ ├── TraditionalApplication.java │ │ │ ├── api │ │ │ ├── ProductDTO.java │ │ │ ├── OrderItemDTO.java │ │ │ ├── PurchaseOrderDTO.java │ │ │ ├── CustomerDTO.java │ │ │ └── OrderController.java │ │ │ ├── trace │ │ │ ├── MethodTraceAspect.java │ │ │ └── MethodTracer.java │ │ │ └── entity │ │ │ ├── Product.java │ │ │ ├── OrderItem.java │ │ │ ├── PurchaseOrder.java │ │ │ └── Customer.java │ └── test │ │ └── java │ │ └── ch │ │ └── martinelli │ │ └── demo │ │ └── traditional │ │ ├── TestTraditionalApplication.java │ │ └── api │ │ └── TraditionalOrderControllerTest.java ├── HELP.md ├── pom.xml ├── mvnw.cmd └── mvnw ├── README.md └── requests.http /.gitignore: -------------------------------------------------------------------------------- 1 | .idea 2 | cqrs/target 3 | traditional/target -------------------------------------------------------------------------------- /cqrs/.mvn/wrapper/maven-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/simasch/cqrs-meets-modern-java/HEAD/cqrs/.mvn/wrapper/maven-wrapper.jar -------------------------------------------------------------------------------- /traditional/.mvn/wrapper/maven-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/simasch/cqrs-meets-modern-java/HEAD/traditional/.mvn/wrapper/maven-wrapper.jar -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/query/Product.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.query; 2 | 3 | record Product(Long id, String name, double price) { 4 | } 5 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/query/OrderItem.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.query; 2 | 3 | record OrderItem(Long id, int quantity, Product product) { 4 | } -------------------------------------------------------------------------------- /cqrs/src/main/resources/application.properties: -------------------------------------------------------------------------------- 1 | server.port=8081 2 | 3 | spring.mvc.problemdetails.enabled=true 4 | 5 | logging.level.org.jooq=debug 6 | logging.level.ch.martinelli.demo=trace 7 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/query/FindOrders.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.query; 2 | 3 | record FindOrders(String firstName, String lastName, int offset, int limit) { 4 | } 5 | -------------------------------------------------------------------------------- /traditional/src/main/resources/application.properties: -------------------------------------------------------------------------------- 1 | spring.jpa.properties.hibernate.generate_statistics=false 2 | 3 | logging.level.org.hibernate.SQL=debug 4 | logging.level.ch.martinelli.demo=trace -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/query/Customer.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.query; 2 | 3 | record Customer(Long id, String firstName, String lastName, String street, String postalCode, String city) { 4 | } 5 | -------------------------------------------------------------------------------- /cqrs/.mvn/wrapper/maven-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.5/apache-maven-3.9.5-bin.zip 2 | wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar 3 | -------------------------------------------------------------------------------- /traditional/.mvn/wrapper/maven-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.5/apache-maven-3.9.5-bin.zip 2 | wrapperUrl=https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar 3 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/query/PurchaseOrder.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.query; 2 | 3 | import java.time.LocalDateTime; 4 | import java.util.List; 5 | 6 | record PurchaseOrder(Long id, LocalDateTime orderDate, 7 | Customer customer, List items) { 8 | } -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/repository/CustomerRepository.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.repository; 2 | 3 | import ch.martinelli.demo.traditional.entity.Customer; 4 | import org.springframework.data.jpa.repository.JpaRepository; 5 | 6 | public interface CustomerRepository extends JpaRepository { 7 | } 8 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/CqrsApplication.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | 6 | @SpringBootApplication 7 | public class CqrsApplication { 8 | 9 | public static void main(String[] args) { 10 | SpringApplication.run(CqrsApplication.class, args); 11 | } 12 | 13 | } 14 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/TraditionalApplication.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | 6 | @SpringBootApplication 7 | public class TraditionalApplication { 8 | 9 | public static void main(String[] args) { 10 | SpringApplication.run(TraditionalApplication.class, args); 11 | } 12 | 13 | } 14 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/repository/PurchaseOrderRepository.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.repository; 2 | 3 | import ch.martinelli.demo.traditional.entity.PurchaseOrder; 4 | import org.springframework.data.domain.Pageable; 5 | import org.springframework.data.jpa.repository.JpaRepository; 6 | 7 | import java.util.List; 8 | 9 | public interface PurchaseOrderRepository extends JpaRepository { 10 | 11 | List findAllByCustomerFirstNameIgnoreCaseLikeOrCustomerLastNameIgnoreCaseLike(String firstName, String lastName, Pageable pageable); 12 | } 13 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # CQRS Meets Modern Java 2 | 3 | This project is used as an example for my 4 | talk [CQRS meets modern Java](https://speakerdeck.com/simas/cqrs-meets-modern-java) 5 | 6 | ## Prerequisite: jOOQ Build 7 | 8 | The CQRS project uses jOOQ and therefore the database model classes must be created with Maven. 9 | 10 | Change into the cqrs directory and run: 11 | 12 | ./mvnw compile 13 | 14 | ## Running the applications 15 | 16 | Both applications use Testcontainers support of Spring Boot. Run the TestCqrsApplication and the 17 | TestTraditionalApplication in src/test 18 | 19 | ## Testing 20 | 21 | The file requests.http contains the http test requests to test the endpoints. -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/api/ProductDTO.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.api; 2 | 3 | public class ProductDTO { 4 | 5 | private Long id; 6 | private String name; 7 | private double price; 8 | 9 | public Long getId() { 10 | return id; 11 | } 12 | 13 | public void setId(Long id) { 14 | this.id = id; 15 | } 16 | 17 | public String getName() { 18 | return name; 19 | } 20 | 21 | public void setName(String name) { 22 | this.name = name; 23 | } 24 | 25 | public double getPrice() { 26 | return price; 27 | } 28 | 29 | public void setPrice(double price) { 30 | this.price = price; 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/trace/MethodTraceAspect.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.trace; 2 | 3 | import org.aspectj.lang.ProceedingJoinPoint; 4 | import org.aspectj.lang.annotation.Around; 5 | import org.aspectj.lang.annotation.Aspect; 6 | import org.springframework.context.annotation.Configuration; 7 | 8 | @Aspect 9 | @Configuration 10 | public class MethodTraceAspect { 11 | 12 | private final MethodTracer methodTracer = new MethodTracer(); 13 | 14 | @Around("execution(* ch.martinelli.demo.*.*(..)) || execution(* org.springframework.data.repository.CrudRepository+.*(..))))") 15 | public Object logMethod(ProceedingJoinPoint joinPoint) throws Throwable { 16 | return methodTracer.logMethod(joinPoint); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/api/OrderItemDTO.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.api; 2 | 3 | public class OrderItemDTO { 4 | 5 | private Long id; 6 | private int quantity; 7 | private ProductDTO product; 8 | 9 | public Long getId() { 10 | return id; 11 | } 12 | 13 | public void setId(Long id) { 14 | this.id = id; 15 | } 16 | 17 | public int getQuantity() { 18 | return quantity; 19 | } 20 | 21 | public void setQuantity(int quantity) { 22 | this.quantity = quantity; 23 | } 24 | 25 | public ProductDTO getProduct() { 26 | return product; 27 | } 28 | 29 | public void setProduct(ProductDTO product) { 30 | this.product = product; 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/query/OrderQueryController.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.query; 2 | 3 | import org.springframework.web.bind.annotation.GetMapping; 4 | import org.springframework.web.bind.annotation.RequestMapping; 5 | import org.springframework.web.bind.annotation.RestController; 6 | 7 | import java.util.List; 8 | 9 | @RequestMapping("orders") 10 | @RestController 11 | class OrderQueryController { 12 | 13 | private final OrderRepository orderRepository; 14 | 15 | OrderQueryController(OrderRepository orderRepository) { 16 | this.orderRepository = orderRepository; 17 | } 18 | 19 | @GetMapping 20 | List getCustomersWithOrders(FindOrders query) { 21 | return orderRepository.findOrders(query.firstName(), query.lastName(), query.offset(), query.limit()); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /cqrs/src/test/java/ch/martinelli/demo/cqrs/TestCqrsApplication.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.test.context.TestConfiguration; 5 | import org.springframework.boot.testcontainers.service.connection.ServiceConnection; 6 | import org.springframework.context.annotation.Bean; 7 | import org.testcontainers.containers.PostgreSQLContainer; 8 | import org.testcontainers.utility.DockerImageName; 9 | 10 | @TestConfiguration(proxyBeanMethods = false) 11 | public class TestCqrsApplication { 12 | 13 | @Bean 14 | @ServiceConnection 15 | PostgreSQLContainer postgresContainer() { 16 | return new PostgreSQLContainer<>(DockerImageName.parse("postgres:latest")); 17 | } 18 | 19 | public static void main(String[] args) { 20 | SpringApplication.from(CqrsApplication::main).with(TestCqrsApplication.class).run(args); 21 | } 22 | 23 | } 24 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/entity/Product.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.entity; 2 | 3 | import jakarta.persistence.*; 4 | 5 | @Entity 6 | public class Product { 7 | 8 | @Id 9 | @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "product_seq") 10 | @SequenceGenerator(name = "product_seq", sequenceName = "product_seq", initialValue = 1000) 11 | private Long id; 12 | private String name; 13 | private double price; 14 | 15 | public Long getId() { 16 | return id; 17 | } 18 | 19 | public void setId(Long id) { 20 | this.id = id; 21 | } 22 | 23 | public String getName() { 24 | return name; 25 | } 26 | 27 | public void setName(String name) { 28 | this.name = name; 29 | } 30 | 31 | public double getPrice() { 32 | return price; 33 | } 34 | 35 | public void setPrice(double price) { 36 | this.price = price; 37 | } 38 | } -------------------------------------------------------------------------------- /traditional/src/test/java/ch/martinelli/demo/traditional/TestTraditionalApplication.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.test.context.TestConfiguration; 5 | import org.springframework.boot.testcontainers.service.connection.ServiceConnection; 6 | import org.springframework.context.annotation.Bean; 7 | import org.testcontainers.containers.PostgreSQLContainer; 8 | import org.testcontainers.utility.DockerImageName; 9 | 10 | @TestConfiguration(proxyBeanMethods = false) 11 | public class TestTraditionalApplication { 12 | 13 | @Bean 14 | @ServiceConnection 15 | PostgreSQLContainer postgresContainer() { 16 | return new PostgreSQLContainer<>(DockerImageName.parse("postgres:latest")); 17 | } 18 | 19 | public static void main(String[] args) { 20 | SpringApplication.from(TraditionalApplication::main).with(TestTraditionalApplication.class).run(args); 21 | } 22 | 23 | } 24 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/command/OrderCommandController.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.command; 2 | 3 | import jakarta.validation.Valid; 4 | import org.springframework.http.HttpStatus; 5 | import org.springframework.http.ProblemDetail; 6 | import org.springframework.web.bind.annotation.*; 7 | 8 | import java.util.Optional; 9 | 10 | @RequestMapping("commands/order") 11 | @RestController 12 | class OrderCommandController { 13 | 14 | private final OrderCommandHandler commandHandler; 15 | 16 | OrderCommandController(OrderCommandHandler commandHandler) { 17 | this.commandHandler = commandHandler; 18 | } 19 | 20 | @PostMapping 21 | Optional execute(@RequestBody @Valid OrderCommand orderCommand) { 22 | return commandHandler.handle(orderCommand); 23 | } 24 | 25 | @ExceptionHandler 26 | ProblemDetail handle(IllegalArgumentException ex) { 27 | return ProblemDetail.forStatusAndDetail(HttpStatus.PRECONDITION_FAILED, ex.getMessage()); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/entity/OrderItem.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.entity; 2 | 3 | import jakarta.persistence.*; 4 | 5 | @Entity 6 | public class OrderItem { 7 | 8 | @Id 9 | @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "order_item_seq") 10 | @SequenceGenerator(name = "order_item_seq", sequenceName = "order_item_seq", initialValue = 100000) 11 | private Long id; 12 | 13 | private int quantity; 14 | 15 | @ManyToOne(fetch = FetchType.LAZY) 16 | private Product product; 17 | 18 | public Long getId() { 19 | return id; 20 | } 21 | 22 | public void setId(Long id) { 23 | this.id = id; 24 | } 25 | 26 | public int getQuantity() { 27 | return quantity; 28 | } 29 | 30 | public void setQuantity(int quantity) { 31 | this.quantity = quantity; 32 | } 33 | 34 | public Product getProduct() { 35 | return product; 36 | } 37 | 38 | public void setProduct(Product product) { 39 | this.product = product; 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/api/PurchaseOrderDTO.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.api; 2 | 3 | import java.time.LocalDateTime; 4 | import java.util.List; 5 | 6 | public class PurchaseOrderDTO { 7 | 8 | private Long id; 9 | private LocalDateTime orderDate; 10 | private CustomerDTO customer; 11 | private List items; 12 | 13 | public Long getId() { 14 | return id; 15 | } 16 | 17 | public void setId(Long id) { 18 | this.id = id; 19 | } 20 | 21 | public LocalDateTime getOrderDate() { 22 | return orderDate; 23 | } 24 | 25 | public void setOrderDate(LocalDateTime orderDate) { 26 | this.orderDate = orderDate; 27 | } 28 | 29 | public CustomerDTO getCustomer() { 30 | return customer; 31 | } 32 | 33 | public void setCustomerDTO(CustomerDTO customer) { 34 | this.customer = customer; 35 | } 36 | 37 | public List getItems() { 38 | return items; 39 | } 40 | 41 | public void setItems(List items) { 42 | this.items = items; 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/command/OrderCommand.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.command; 2 | 3 | import com.fasterxml.jackson.annotation.JsonSubTypes; 4 | import com.fasterxml.jackson.annotation.JsonTypeInfo; 5 | import jakarta.validation.constraints.Max; 6 | import jakarta.validation.constraints.Min; 7 | 8 | @JsonTypeInfo( 9 | use = JsonTypeInfo.Id.SIMPLE_NAME 10 | ) 11 | @JsonSubTypes({ 12 | @JsonSubTypes.Type(value = OrderCommand.CreateOrderCommand.class), 13 | @JsonSubTypes.Type(value = OrderCommand.AddOrderItemCommand.class), 14 | @JsonSubTypes.Type(value = OrderCommand.UpdateQuantityCommand.class), 15 | }) 16 | sealed interface OrderCommand { 17 | 18 | record CreateOrderCommand( 19 | @Min(1) long customerId) implements OrderCommand { 20 | } 21 | 22 | record AddOrderItemCommand( 23 | @Min(1) long orderId, 24 | @Min(1) long productId, 25 | @Min(1) @Max(10) int quantity) implements OrderCommand { 26 | } 27 | 28 | record UpdateQuantityCommand( 29 | @Min(1) long orderItemId, 30 | @Min(1) @Max(10) int quantity) implements OrderCommand { 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/command/OrderCommandHandler.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.command; 2 | 3 | import org.springframework.stereotype.Component; 4 | 5 | import java.util.Optional; 6 | 7 | @Component 8 | class OrderCommandHandler { 9 | 10 | private final OrderService orderService; 11 | 12 | OrderCommandHandler(OrderService orderService) { 13 | this.orderService = orderService; 14 | } 15 | 16 | Optional handle(OrderCommand orderCommand) { 17 | switch (orderCommand) { 18 | case OrderCommand.CreateOrderCommand(long customerId) -> { 19 | var purchaseOrder = orderService.createOrder(customerId); 20 | return Optional.of(purchaseOrder.getId()); 21 | } 22 | case OrderCommand.AddOrderItemCommand(long orderId, long productId, int quantity) -> { 23 | var orderItemRecord = orderService.addItem(orderId, productId, quantity); 24 | return Optional.of(orderItemRecord.getId()); 25 | } 26 | case OrderCommand.UpdateQuantityCommand(long orderItemId, int quantity) -> { 27 | orderService.updateQuantity(orderItemId, quantity); 28 | return Optional.empty(); 29 | } 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/api/CustomerDTO.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.api; 2 | 3 | public class CustomerDTO { 4 | 5 | private Long id; 6 | private String firstName; 7 | private String lastName; 8 | private String street; 9 | private String postalCode; 10 | private String city; 11 | 12 | public Long getId() { 13 | return id; 14 | } 15 | 16 | public void setId(Long id) { 17 | this.id = id; 18 | } 19 | 20 | public String getFirstName() { 21 | return firstName; 22 | } 23 | 24 | public void setFirstName(String firstName) { 25 | this.firstName = firstName; 26 | } 27 | 28 | public String getLastName() { 29 | return lastName; 30 | } 31 | 32 | public void setLastName(String lastName) { 33 | this.lastName = lastName; 34 | } 35 | 36 | public String getStreet() { 37 | return street; 38 | } 39 | 40 | public void setStreet(String street) { 41 | this.street = street; 42 | } 43 | 44 | public String getPostalCode() { 45 | return postalCode; 46 | } 47 | 48 | public void setPostalCode(String postalCode) { 49 | this.postalCode = postalCode; 50 | } 51 | 52 | public String getCity() { 53 | return city; 54 | } 55 | 56 | public void setCity(String city) { 57 | this.city = city; 58 | } 59 | 60 | } 61 | -------------------------------------------------------------------------------- /traditional/src/main/resources/db/migration/V001__Create.sql: -------------------------------------------------------------------------------- 1 | CREATE SEQUENCE customer_seq start with 100000 increment by 50; 2 | 3 | CREATE TABLE customer 4 | ( 5 | id bigint not null primary key, 6 | first_name varchar not null, 7 | last_name varchar not null, 8 | street varchar not null, 9 | postal_code varchar not null, 10 | city varchar not null 11 | ); 12 | 13 | CREATE SEQUENCE product_seq start with 100000 increment by 50; 14 | 15 | CREATE TABLE product 16 | ( 17 | id bigint not null primary key, 18 | name varchar not null, 19 | price double precision 20 | ); 21 | 22 | CREATE SEQUENCE purchase_order_seq start with 100000 increment by 50; 23 | 24 | CREATE TABLE purchase_order 25 | ( 26 | id bigint not null primary key, 27 | order_date timestamp not null, 28 | 29 | customer_id bigint not null references customer (id) 30 | ); 31 | 32 | create index ux_purchase_order_customer_id on purchase_order (customer_id); 33 | 34 | 35 | CREATE SEQUENCE order_item_seq start with 100000 increment by 50; 36 | 37 | CREATE TABLE order_item 38 | ( 39 | id bigint not null primary key, 40 | quantity int not null, 41 | 42 | purchase_order_id bigint not null references purchase_order (id), 43 | product_id bigint not null references product (id) 44 | ); 45 | 46 | create index ux_order_item_purchase_order_id on order_item (purchase_order_id); 47 | create index ux_order_item_product_id on order_item (product_id); 48 | -------------------------------------------------------------------------------- /cqrs/src/test/java/ch/martinelli/demo/cqrs/api/query/OrderQueryControllerTest.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.api.query; 2 | 3 | import ch.martinelli.demo.cqrs.TestCqrsApplication; 4 | import org.junit.jupiter.api.Test; 5 | import org.slf4j.Logger; 6 | import org.slf4j.LoggerFactory; 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc; 9 | import org.springframework.boot.test.context.SpringBootTest; 10 | import org.springframework.context.annotation.Import; 11 | import org.springframework.test.web.servlet.MockMvc; 12 | import org.springframework.util.StopWatch; 13 | 14 | import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get; 15 | import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; 16 | 17 | @Import(TestCqrsApplication.class) 18 | @SpringBootTest 19 | @AutoConfigureMockMvc 20 | class OrderQueryControllerTest { 21 | 22 | private static final Logger LOGGER = LoggerFactory.getLogger(OrderQueryControllerTest.class); 23 | 24 | @Autowired 25 | private MockMvc mockMvc; 26 | 27 | @Test 28 | void getOrders() throws Exception { 29 | var stopWatch = new StopWatch(); 30 | stopWatch.start(); 31 | 32 | mockMvc.perform(get("/orders?firstName=%&lastName=%&offset=0&limit=500")) 33 | .andExpect(status().isOk()); 34 | 35 | stopWatch.stop(); 36 | LOGGER.info("Test took {} ms", stopWatch.getTotalTimeMillis()); 37 | } 38 | } -------------------------------------------------------------------------------- /requests.http: -------------------------------------------------------------------------------- 1 | ### Traditional: Get Orders 2 | GET http://localhost:8080/orders?firstName=%25&lastName=%25&pageNumber=0&pageSize=9999 3 | 4 | ### CQRS: Get Orders 5 | GET http://localhost:8081/orders?firstName=%25&lastName=%25&offset=0&limit=9999 6 | 7 | ### CQRS: Create Order 8 | POST http://localhost:8081/orders 9 | Content-Type: application/json 10 | 11 | { 12 | "@type": "CreateOrderCommand", 13 | "customerId": 99999 14 | } 15 | 16 | ### CQRS: Add item 17 | POST http://localhost:8081/orders/100000/items 18 | Content-Type: application/json 19 | 20 | { 21 | "@type": "AddOrderItemCommand", 22 | "orderId": 100000, 23 | "productId": 1, 24 | "quantity": 1 25 | } 26 | 27 | ### CQRS: Update quantity 28 | PATCH http://localhost:8081/orders/100000/items/100000 29 | Content-Type: application/json 30 | 31 | { 32 | "@type": "UpdateQuantityCommand", 33 | "orderItemId": 100000, 34 | "quantity": 2 35 | } 36 | 37 | ### CQRS using Command Endpoint: Create Order 38 | POST http://localhost:8081/commands/order 39 | Content-Type: application/json 40 | 41 | { 42 | "@type": "CreateOrderCommand", 43 | "customerId": 1 44 | } 45 | 46 | ### CQRS using Command Endpoint: Add item 47 | POST http://localhost:8081/commands/order 48 | Content-Type: application/json 49 | 50 | { 51 | "@type": "AddOrderItemCommand", 52 | "orderId": 100000, 53 | "productId": 1, 54 | "quantity": 1 55 | } 56 | 57 | ### CQRS using Command Endpoint: Update quantity 58 | POST http://localhost:8081/commands/order 59 | Content-Type: application/json 60 | 61 | { 62 | "@type": "UpdateQuantityCommand", 63 | "orderItemId": 100000, 64 | "quantity": 2 65 | } 66 | 67 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/trace/MethodTracer.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.trace; 2 | 3 | import org.aspectj.lang.ProceedingJoinPoint; 4 | import org.slf4j.Logger; 5 | import org.slf4j.LoggerFactory; 6 | import org.springframework.util.StopWatch; 7 | 8 | import java.util.Arrays; 9 | import java.util.stream.Collectors; 10 | 11 | public class MethodTracer { 12 | 13 | public Object logMethod(ProceedingJoinPoint joinPoint) throws Throwable { 14 | Class clazz = joinPoint.getTarget().getClass(); 15 | if (clazz.getPackage().getName().startsWith("jdk.proxy") && clazz.getInterfaces().length > 0) { 16 | clazz = clazz.getInterfaces()[0]; 17 | } 18 | 19 | Logger logger = LoggerFactory.getLogger(clazz); 20 | if (logger.isTraceEnabled()) { 21 | StopWatch stopWatch = new StopWatch(); 22 | stopWatch.start(); 23 | StringBuilder message = (new StringBuilder(joinPoint.getSignature().getName())).append("("); 24 | String args = Arrays.stream(joinPoint.getArgs()).map((o) -> o != null ? o.toString() : "null").collect(Collectors.joining(", ")); 25 | message.append(args).append(")"); 26 | 27 | try { 28 | Object retVal = joinPoint.proceed(); 29 | stopWatch.stop(); 30 | message.append(" | ").append(stopWatch.getTotalTimeMillis()).append(" ms"); 31 | logger.trace(message.toString()); 32 | return retVal; 33 | } catch (Throwable throwable) { 34 | logger.error(message.toString(), throwable); 35 | throw throwable; 36 | } 37 | } else { 38 | return joinPoint.proceed(); 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /cqrs/src/main/resources/db/migration/V001__Create.sql: -------------------------------------------------------------------------------- 1 | CREATE SEQUENCE customer_seq start with 100000 increment by 50; 2 | 3 | CREATE TABLE customer 4 | ( 5 | id bigint not null default nextval('customer_seq') primary key, 6 | first_name varchar not null, 7 | last_name varchar not null, 8 | street varchar not null, 9 | postal_code varchar not null, 10 | city varchar not null 11 | ); 12 | 13 | CREATE SEQUENCE product_seq start with 100000 increment by 50; 14 | 15 | CREATE TABLE product 16 | ( 17 | id bigint not null default nextval('product_seq') primary key, 18 | name varchar not null, 19 | price double precision 20 | ); 21 | 22 | CREATE SEQUENCE purchase_order_seq start with 100000 increment by 50; 23 | 24 | CREATE TABLE purchase_order 25 | ( 26 | id bigint not null default nextval('purchase_order_seq') primary key, 27 | order_date timestamp not null, 28 | 29 | customer_id bigint not null references customer (id) 30 | ); 31 | 32 | create index ux_purchase_order_customer_id on purchase_order (customer_id); 33 | 34 | 35 | CREATE SEQUENCE order_item_seq start with 100000 increment by 50; 36 | 37 | CREATE TABLE order_item 38 | ( 39 | id bigint not null default nextval('order_item_seq') primary key, 40 | quantity int not null, 41 | 42 | purchase_order_id bigint not null references purchase_order (id), 43 | product_id bigint not null references product (id) 44 | ); 45 | 46 | create index ux_order_item_purchase_order_id on order_item (purchase_order_id); 47 | create index ux_order_item_product_id on order_item (product_id); 48 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/entity/PurchaseOrder.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.entity; 2 | 3 | import jakarta.persistence.*; 4 | 5 | import java.time.LocalDateTime; 6 | import java.util.ArrayList; 7 | import java.util.List; 8 | 9 | @Entity 10 | public class PurchaseOrder { 11 | 12 | @Id 13 | @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "purchase_order_seq") 14 | @SequenceGenerator(name = "purchase_order_seq", sequenceName = "purchase_order_seq", initialValue = 100000) 15 | private Long id; 16 | private LocalDateTime orderDate; 17 | 18 | @ManyToOne(cascade = CascadeType.ALL, optional = false) 19 | private Customer customer; 20 | 21 | @OrderBy("id") 22 | @OneToMany(cascade = CascadeType.ALL, orphanRemoval = true) 23 | @JoinColumn(name = "purchase_order_id", nullable = false) 24 | private List items = new ArrayList<>(); 25 | 26 | public Long getId() { 27 | return id; 28 | } 29 | 30 | public void setId(Long id) { 31 | this.id = id; 32 | } 33 | 34 | public LocalDateTime getOrderDate() { 35 | return orderDate; 36 | } 37 | 38 | public void setOrderDate(LocalDateTime orderDate) { 39 | this.orderDate = orderDate; 40 | } 41 | 42 | public List getItems() { 43 | return items; 44 | } 45 | 46 | public void setItems(List items) { 47 | this.items = items; 48 | } 49 | 50 | public Customer getCustomer() { 51 | return customer; 52 | } 53 | 54 | public void setCustomer(Customer customer) { 55 | this.customer = customer; 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /cqrs/HELP.md: -------------------------------------------------------------------------------- 1 | # Getting Started 2 | 3 | ### Reference Documentation 4 | 5 | For further reference, please consider the following sections: 6 | 7 | * [Official Apache Maven documentation](https://maven.apache.org/guides/index.html) 8 | * [Spring Boot Maven Plugin Reference Guide](https://docs.spring.io/spring-boot/docs/3.2.1/maven-plugin/reference/html/) 9 | * [Create an OCI image](https://docs.spring.io/spring-boot/docs/3.2.1/maven-plugin/reference/html/#build-image) 10 | * [Spring Boot Testcontainers support](https://docs.spring.io/spring-boot/docs/3.2.1/reference/html/features.html#features.testing.testcontainers) 11 | * [Testcontainers Postgres Module Reference Guide](https://java.testcontainers.org/modules/databases/postgres/) 12 | * [JOOQ Access Layer](https://docs.spring.io/spring-boot/docs/3.2.1/reference/htmlsingle/index.html#data.sql.jooq) 13 | * [Spring Web](https://docs.spring.io/spring-boot/docs/3.2.1/reference/htmlsingle/index.html#web) 14 | * [Flyway Migration](https://docs.spring.io/spring-boot/docs/3.2.1/reference/htmlsingle/index.html#howto.data-initialization.migration-tool.flyway) 15 | * [Testcontainers](https://java.testcontainers.org/) 16 | 17 | ### Guides 18 | 19 | The following guides illustrate how to use some features concretely: 20 | 21 | * [Building a RESTful Web Service](https://spring.io/guides/gs/rest-service/) 22 | * [Serving Web Content with Spring MVC](https://spring.io/guides/gs/serving-web-content/) 23 | * [Building REST services with Spring](https://spring.io/guides/tutorials/rest/) 24 | 25 | ### Testcontainers support 26 | 27 | This project 28 | uses [Testcontainers at development time](https://docs.spring.io/spring-boot/docs/3.2.1/reference/html/features.html#features.testing.testcontainers.at-development-time). 29 | 30 | Testcontainers has been configured to use the following Docker images: 31 | 32 | * [`postgres:latest`](https://hub.docker.com/_/postgres) 33 | 34 | Please review the tags of the used images and set them to the same as you're running in production. 35 | 36 | -------------------------------------------------------------------------------- /traditional/HELP.md: -------------------------------------------------------------------------------- 1 | # Getting Started 2 | 3 | ### Reference Documentation 4 | 5 | For further reference, please consider the following sections: 6 | 7 | * [Official Apache Maven documentation](https://maven.apache.org/guides/index.html) 8 | * [Spring Boot Maven Plugin Reference Guide](https://docs.spring.io/spring-boot/docs/3.2.1/maven-plugin/reference/html/) 9 | * [Create an OCI image](https://docs.spring.io/spring-boot/docs/3.2.1/maven-plugin/reference/html/#build-image) 10 | * [Spring Boot Testcontainers support](https://docs.spring.io/spring-boot/docs/3.2.1/reference/html/features.html#features.testing.testcontainers) 11 | * [Testcontainers Postgres Module Reference Guide](https://java.testcontainers.org/modules/databases/postgres/) 12 | * [Testcontainers](https://java.testcontainers.org/) 13 | * [Spring Data JPA](https://docs.spring.io/spring-boot/docs/3.2.1/reference/htmlsingle/index.html#data.sql.jpa-and-spring-data) 14 | * [Flyway Migration](https://docs.spring.io/spring-boot/docs/3.2.1/reference/htmlsingle/index.html#howto.data-initialization.migration-tool.flyway) 15 | * [Spring Web](https://docs.spring.io/spring-boot/docs/3.2.1/reference/htmlsingle/index.html#web) 16 | 17 | ### Guides 18 | 19 | The following guides illustrate how to use some features concretely: 20 | 21 | * [Accessing Data with JPA](https://spring.io/guides/gs/accessing-data-jpa/) 22 | * [Building a RESTful Web Service](https://spring.io/guides/gs/rest-service/) 23 | * [Serving Web Content with Spring MVC](https://spring.io/guides/gs/serving-web-content/) 24 | * [Building REST services with Spring](https://spring.io/guides/tutorials/rest/) 25 | 26 | ### Testcontainers support 27 | 28 | This project 29 | uses [Testcontainers at development time](https://docs.spring.io/spring-boot/docs/3.2.1/reference/html/features.html#features.testing.testcontainers.at-development-time). 30 | 31 | Testcontainers has been configured to use the following Docker images: 32 | 33 | * [`postgres:latest`](https://hub.docker.com/_/postgres) 34 | 35 | Please review the tags of the used images and set them to the same as you're running in production. 36 | 37 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/entity/Customer.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.entity; 2 | 3 | import jakarta.persistence.*; 4 | 5 | import java.util.ArrayList; 6 | import java.util.List; 7 | 8 | @Entity 9 | public class Customer { 10 | 11 | @Id 12 | @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "customer_seq") 13 | @SequenceGenerator(name = "customer_seq", sequenceName = "customer_seq", initialValue = 1000) 14 | private Long id; 15 | private String firstName; 16 | private String lastName; 17 | private String street; 18 | private String postalCode; 19 | private String city; 20 | 21 | @OrderBy("orderDate DESC") 22 | @OneToMany(mappedBy = "customer", cascade = CascadeType.ALL, orphanRemoval = true) 23 | private List orders = new ArrayList<>(); 24 | 25 | public Long getId() { 26 | return id; 27 | } 28 | 29 | public void setId(Long id) { 30 | this.id = id; 31 | } 32 | 33 | public String getFirstName() { 34 | return firstName; 35 | } 36 | 37 | public void setFirstName(String firstName) { 38 | this.firstName = firstName; 39 | } 40 | 41 | public String getLastName() { 42 | return lastName; 43 | } 44 | 45 | public void setLastName(String lastName) { 46 | this.lastName = lastName; 47 | } 48 | 49 | public String getStreet() { 50 | return street; 51 | } 52 | 53 | public void setStreet(String street) { 54 | this.street = street; 55 | } 56 | 57 | public String getPostalCode() { 58 | return postalCode; 59 | } 60 | 61 | public void setPostalCode(String postalCode) { 62 | this.postalCode = postalCode; 63 | } 64 | 65 | public String getCity() { 66 | return city; 67 | } 68 | 69 | public void setCity(String city) { 70 | this.city = city; 71 | } 72 | 73 | public List getOrders() { 74 | return orders; 75 | } 76 | 77 | public void setOrders(List orders) { 78 | this.orders = orders; 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/command/OrderController.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.command; 2 | 3 | import jakarta.validation.Valid; 4 | import org.springframework.http.HttpStatus; 5 | import org.springframework.http.ProblemDetail; 6 | import org.springframework.http.ResponseEntity; 7 | import org.springframework.web.bind.annotation.*; 8 | 9 | import static org.springframework.http.ResponseEntity.created; 10 | import static org.springframework.http.ResponseEntity.ok; 11 | import static org.springframework.web.servlet.support.ServletUriComponentsBuilder.fromCurrentRequest; 12 | 13 | @RequestMapping("/orders") 14 | @RestController 15 | class OrderController { 16 | 17 | private final OrderCommandHandler commandHandler; 18 | 19 | OrderController(OrderCommandHandler commandHandler) { 20 | this.commandHandler = commandHandler; 21 | } 22 | 23 | @PostMapping 24 | ResponseEntity createOrder(@RequestBody @Valid OrderCommand.CreateOrderCommand createOrderCommand) { 25 | 26 | var purchaseOrderId = commandHandler.handle(createOrderCommand).orElse(null); 27 | 28 | return created(fromCurrentRequest().path("/{id}").buildAndExpand(purchaseOrderId).toUri()).build(); 29 | } 30 | 31 | @PostMapping("{orderId}/items") 32 | ResponseEntity addItem(@PathVariable long orderId, 33 | @RequestBody @Valid OrderCommand.AddOrderItemCommand addOrderItemCommand) { 34 | 35 | if (orderId != addOrderItemCommand.orderId()) throw new IllegalArgumentException(); 36 | 37 | var orderItemId = commandHandler.handle(addOrderItemCommand).orElse(null); 38 | 39 | return created(fromCurrentRequest().path("/{id}").buildAndExpand(orderItemId).toUri()).build(); 40 | } 41 | 42 | @PatchMapping("{orderId}/items/{orderItemId}") 43 | ResponseEntity updateQuantity(@PathVariable long orderId, @PathVariable long orderItemId, 44 | @Valid @RequestBody OrderCommand.UpdateQuantityCommand updateQuantityCommand) { 45 | 46 | if (orderItemId != updateQuantityCommand.orderItemId()) throw new IllegalArgumentException(); 47 | 48 | commandHandler.handle(updateQuantityCommand); 49 | 50 | return ok().build(); 51 | } 52 | 53 | @ExceptionHandler 54 | ProblemDetail handle(IllegalArgumentException ex) { 55 | return ProblemDetail.forStatusAndDetail(HttpStatus.PRECONDITION_FAILED, ex.getMessage()); 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/query/OrderRepository.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.query; 2 | 3 | import org.jooq.DSLContext; 4 | import org.springframework.stereotype.Repository; 5 | 6 | import java.util.List; 7 | 8 | import static ch.martinelli.demo.cqrs.db.tables.OrderItem.ORDER_ITEM; 9 | import static ch.martinelli.demo.cqrs.db.tables.PurchaseOrder.PURCHASE_ORDER; 10 | import static org.jooq.Records.mapping; 11 | import static org.jooq.impl.DSL.*; 12 | 13 | @Repository 14 | class OrderRepository { 15 | 16 | private final DSLContext ctx; 17 | 18 | OrderRepository(DSLContext ctx) { 19 | this.ctx = ctx; 20 | } 21 | 22 | List findOrders(String firstName, String lastName, int offset, int limit) { 23 | return ctx.select(PURCHASE_ORDER.ID, 24 | PURCHASE_ORDER.ORDER_DATE, 25 | row(PURCHASE_ORDER.customer().ID, 26 | PURCHASE_ORDER.customer().FIRST_NAME, 27 | PURCHASE_ORDER.customer().LAST_NAME, 28 | PURCHASE_ORDER.customer().STREET, 29 | PURCHASE_ORDER.customer().POSTAL_CODE, 30 | PURCHASE_ORDER.customer().CITY 31 | ).mapping(Customer::new), 32 | multiset( 33 | select(ORDER_ITEM.ID, 34 | ORDER_ITEM.QUANTITY, 35 | row(ORDER_ITEM.product().ID, 36 | ORDER_ITEM.product().NAME, 37 | ORDER_ITEM.product().PRICE 38 | ).mapping(Product::new)) 39 | .from(ORDER_ITEM) 40 | .where(ORDER_ITEM.PURCHASE_ORDER_ID.eq(PURCHASE_ORDER.ID)) 41 | .orderBy(ORDER_ITEM.ID) 42 | ).convertFrom(r -> r.map(mapping(OrderItem::new)))) 43 | .from(PURCHASE_ORDER) 44 | .where(PURCHASE_ORDER.customer().FIRST_NAME.likeIgnoreCase(firstName) 45 | .or(PURCHASE_ORDER.customer().LAST_NAME.likeIgnoreCase(lastName))) 46 | .orderBy(PURCHASE_ORDER.ORDER_DATE) 47 | .offset(offset) 48 | .limit(limit) 49 | .fetch(mapping(PurchaseOrder::new)); 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /cqrs/src/main/java/ch/martinelli/demo/cqrs/command/OrderService.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.command; 2 | 3 | import ch.martinelli.demo.cqrs.db.tables.records.OrderItemRecord; 4 | import ch.martinelli.demo.cqrs.db.tables.records.PurchaseOrderRecord; 5 | import org.jooq.DSLContext; 6 | import org.springframework.stereotype.Service; 7 | import org.springframework.transaction.annotation.Transactional; 8 | 9 | import java.time.LocalDateTime; 10 | 11 | import static ch.martinelli.demo.cqrs.db.tables.Customer.CUSTOMER; 12 | import static ch.martinelli.demo.cqrs.db.tables.OrderItem.ORDER_ITEM; 13 | import static ch.martinelli.demo.cqrs.db.tables.Product.PRODUCT; 14 | import static ch.martinelli.demo.cqrs.db.tables.PurchaseOrder.PURCHASE_ORDER; 15 | 16 | @Service 17 | class OrderService { 18 | 19 | private final DSLContext ctx; 20 | 21 | OrderService(DSLContext ctx) { 22 | this.ctx = ctx; 23 | } 24 | 25 | @Transactional 26 | PurchaseOrderRecord createOrder(long customerId) { 27 | var customer = ctx 28 | .selectFrom(CUSTOMER) 29 | .where(CUSTOMER.ID.eq(customerId)) 30 | .fetchOptional() 31 | .orElseThrow(() -> new IllegalArgumentException("Customer does not exist")); 32 | 33 | var purchaseOrder = ctx.newRecord(PURCHASE_ORDER); 34 | purchaseOrder.setOrderDate(LocalDateTime.now()); 35 | purchaseOrder.setCustomerId(customer.getId()); 36 | 37 | purchaseOrder.store(); 38 | 39 | return purchaseOrder; 40 | } 41 | 42 | @Transactional 43 | OrderItemRecord addItem(long purchaseOrderId, long productId, int quantity) { 44 | if (!ctx.fetchExists(ctx.selectFrom(PURCHASE_ORDER).where(PURCHASE_ORDER.ID.eq(purchaseOrderId)))) { 45 | throw new IllegalArgumentException("Purchase order does not exist"); 46 | } 47 | 48 | if (!ctx.fetchExists(ctx.selectFrom(PRODUCT).where(PRODUCT.ID.eq(productId)))) { 49 | throw new IllegalArgumentException("Product does not exist"); 50 | } 51 | 52 | var orderItem = ctx.newRecord(ORDER_ITEM); 53 | orderItem.setPurchaseOrderId(purchaseOrderId); 54 | orderItem.setProductId(productId); 55 | orderItem.setQuantity(quantity); 56 | orderItem.store(); 57 | 58 | return orderItem; 59 | } 60 | 61 | @Transactional 62 | void updateQuantity(long orderItemId, int quantity) { 63 | int numRowsUpdated = ctx.update(ORDER_ITEM) 64 | .set(ORDER_ITEM.QUANTITY, quantity) 65 | .where(ORDER_ITEM.ID.eq(orderItemId)) 66 | .execute(); 67 | 68 | if (numRowsUpdated == 0) { 69 | throw new IllegalArgumentException("Order item does not exist"); 70 | } 71 | } 72 | } 73 | -------------------------------------------------------------------------------- /traditional/src/main/java/ch/martinelli/demo/traditional/api/OrderController.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.api; 2 | 3 | import ch.martinelli.demo.traditional.entity.PurchaseOrder; 4 | import ch.martinelli.demo.traditional.repository.CustomerRepository; 5 | import ch.martinelli.demo.traditional.repository.PurchaseOrderRepository; 6 | import org.modelmapper.ModelMapper; 7 | import org.modelmapper.convention.MatchingStrategies; 8 | import org.springframework.data.domain.PageRequest; 9 | import org.springframework.data.domain.Sort; 10 | import org.springframework.http.HttpStatus; 11 | import org.springframework.web.bind.annotation.*; 12 | 13 | import java.util.List; 14 | 15 | @RequestMapping("orders") 16 | @RestController 17 | class OrderController { 18 | 19 | private final PurchaseOrderRepository purchaseOrderRepository; 20 | private final CustomerRepository customerRepository; 21 | private final ModelMapper modelMapper; 22 | 23 | OrderController(PurchaseOrderRepository purchaseOrderRepository, 24 | CustomerRepository customerRepository) { 25 | this.purchaseOrderRepository = purchaseOrderRepository; 26 | this.customerRepository = customerRepository; 27 | this.modelMapper = new ModelMapper(); 28 | this.modelMapper.getConfiguration().setMatchingStrategy(MatchingStrategies.LOOSE); 29 | } 30 | 31 | @ResponseStatus(HttpStatus.CREATED) 32 | @PostMapping 33 | void post(@RequestBody PurchaseOrderDTO purchaseOrderDTO) { 34 | var purchaseOrder = modelMapper.map(purchaseOrderDTO, PurchaseOrder.class); 35 | 36 | customerRepository.findById(purchaseOrder.getCustomer().getId()) 37 | .ifPresent(purchaseOrder::setCustomer); 38 | 39 | purchaseOrderRepository.save(purchaseOrder); 40 | } 41 | 42 | @PutMapping("{id}") 43 | void put(@PathVariable Long id, @RequestBody PurchaseOrderDTO purchaseOrderDTO) { 44 | if (id.equals(purchaseOrderDTO.getId())) throw new IllegalArgumentException(); 45 | 46 | var purchaseOrder = modelMapper.map(purchaseOrderDTO, PurchaseOrder.class); 47 | 48 | purchaseOrderRepository.save(purchaseOrder); 49 | } 50 | 51 | @GetMapping 52 | List getPurchaseOrders(@RequestParam String firstName, 53 | @RequestParam String lastName, 54 | @RequestParam int pageNumber, 55 | @RequestParam int pageSize) { 56 | var purchaseOrders = purchaseOrderRepository 57 | .findAllByCustomerFirstNameIgnoreCaseLikeOrCustomerLastNameIgnoreCaseLike( 58 | firstName, lastName, 59 | PageRequest.of(pageNumber, pageSize, Sort.by("orderDate"))); 60 | 61 | return purchaseOrders.stream() 62 | .map(order -> modelMapper.map(order, PurchaseOrderDTO.class)) 63 | .toList(); 64 | } 65 | } 66 | -------------------------------------------------------------------------------- /traditional/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 4.0.0 5 | 6 | org.springframework.boot 7 | spring-boot-starter-parent 8 | 3.4.3 9 | 10 | 11 | 12 | ch.martinelli.demo 13 | traditional 14 | 0.0.1-SNAPSHOT 15 | 16 | 17 | 21 18 | 19 | 20 | 21 | 22 | org.springframework.boot 23 | spring-boot-starter-data-jpa 24 | 25 | 26 | org.springframework.boot 27 | spring-boot-starter-web 28 | 29 | 30 | 31 | org.flywaydb 32 | flyway-core 33 | 34 | 35 | org.flywaydb 36 | flyway-database-postgresql 37 | 38 | 39 | 40 | org.modelmapper 41 | modelmapper 42 | 3.2.0 43 | 44 | 45 | 46 | org.postgresql 47 | postgresql 48 | runtime 49 | 50 | 51 | 52 | org.springframework.boot 53 | spring-boot-starter-test 54 | test 55 | 56 | 57 | org.springframework.boot 58 | spring-boot-testcontainers 59 | test 60 | 61 | 62 | org.testcontainers 63 | junit-jupiter 64 | test 65 | 66 | 67 | org.testcontainers 68 | postgresql 69 | test 70 | 71 | 72 | 73 | 74 | 75 | 76 | org.springframework.boot 77 | spring-boot-maven-plugin 78 | 79 | 80 | 81 | 82 | -------------------------------------------------------------------------------- /cqrs/src/test/java/ch/martinelli/demo/cqrs/api/command/OrderCommandControllerTest.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.api.command; 2 | 3 | import ch.martinelli.demo.cqrs.TestCqrsApplication; 4 | import org.junit.jupiter.api.Test; 5 | import org.slf4j.Logger; 6 | import org.slf4j.LoggerFactory; 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc; 9 | import org.springframework.boot.test.context.SpringBootTest; 10 | import org.springframework.context.annotation.Import; 11 | import org.springframework.test.web.servlet.MockMvc; 12 | import org.springframework.util.StopWatch; 13 | 14 | import static org.springframework.http.MediaType.APPLICATION_JSON; 15 | import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post; 16 | import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; 17 | 18 | @Import(TestCqrsApplication.class) 19 | @SpringBootTest 20 | @AutoConfigureMockMvc 21 | class OrderCommandControllerTest { 22 | 23 | private static final Logger LOGGER = LoggerFactory.getLogger(OrderCommandControllerTest.class); 24 | 25 | @Autowired 26 | private MockMvc mockMvc; 27 | 28 | @Test 29 | void createPurchaseOrderWithOneItem() throws Exception { 30 | var stopWatch = new StopWatch(); 31 | stopWatch.start(); 32 | 33 | var createOrderResult = mockMvc.perform(post("/commands/order") 34 | .contentType(APPLICATION_JSON) 35 | .content(""" 36 | { 37 | "@type": "CreateOrderCommand", 38 | "customerId": 1 39 | }""")) 40 | .andExpect(status().isOk()) 41 | .andReturn(); 42 | 43 | stopWatch.stop(); 44 | LOGGER.info("Create order took {} ms", stopWatch.getTotalTimeMillis()); 45 | 46 | stopWatch.start(); 47 | 48 | var addOrderItemResult = mockMvc.perform(post("/commands/order") 49 | .contentType(APPLICATION_JSON) 50 | .content(""" 51 | { 52 | "@type": "AddOrderItemCommand", 53 | "orderId": %s, 54 | "productId": 1, 55 | "quantity": 1 56 | }""".formatted(createOrderResult.getResponse().getContentAsString()))) 57 | .andExpect(status().isOk()) 58 | .andReturn(); 59 | 60 | mockMvc.perform(post("/commands/order") 61 | .contentType(APPLICATION_JSON) 62 | .content(""" 63 | { 64 | "@type": "UpdateQuantityCommand", 65 | "orderItemId": %s, 66 | "quantity": 1 67 | }""".formatted(addOrderItemResult.getResponse().getContentAsString()))) 68 | .andExpect(status().isOk()); 69 | 70 | stopWatch.stop(); 71 | LOGGER.info("Add order item took {} ms", stopWatch.getTotalTimeMillis()); 72 | } 73 | } -------------------------------------------------------------------------------- /traditional/src/test/java/ch/martinelli/demo/traditional/api/TraditionalOrderControllerTest.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.traditional.api; 2 | 3 | import ch.martinelli.demo.traditional.TestTraditionalApplication; 4 | import org.junit.jupiter.api.Test; 5 | import org.slf4j.Logger; 6 | import org.slf4j.LoggerFactory; 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc; 9 | import org.springframework.boot.test.context.SpringBootTest; 10 | import org.springframework.context.annotation.Import; 11 | import org.springframework.test.web.servlet.MockMvc; 12 | import org.springframework.util.StopWatch; 13 | 14 | import static org.springframework.http.MediaType.APPLICATION_JSON; 15 | import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get; 16 | import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post; 17 | import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; 18 | 19 | @Import(TestTraditionalApplication.class) 20 | @SpringBootTest 21 | @AutoConfigureMockMvc 22 | class TraditionalOrderControllerTest { 23 | 24 | private static final Logger LOGGER = LoggerFactory.getLogger(TraditionalOrderControllerTest.class); 25 | 26 | @Autowired 27 | private MockMvc mockMvc; 28 | 29 | @Test 30 | void getOrders() throws Exception { 31 | var stopWatch = new StopWatch(); 32 | stopWatch.start(); 33 | 34 | mockMvc.perform(get("/orders?firstName=%&lastName=%&pageNumber=0&pageSize=500")) 35 | .andExpect(status().isOk()); 36 | 37 | stopWatch.stop(); 38 | 39 | LOGGER.info("Test took {} ms", stopWatch.getTotalTimeMillis()); 40 | } 41 | 42 | @Test 43 | void postOrder() throws Exception { 44 | var stopWatch = new StopWatch(); 45 | stopWatch.start(); 46 | 47 | mockMvc.perform(post("/orders") 48 | .contentType(APPLICATION_JSON) 49 | .content(""" 50 | { 51 | "orderDate": "2024-01-02T14:49:10", 52 | "customer": { 53 | "id": 2, 54 | "firstName": "Kelci", 55 | "lastName": "Grinnov", 56 | "street": "88889 Lawn Point", 57 | "postalCode": "1000", 58 | "city": "Tangguhang" 59 | }, 60 | "items": [ 61 | { 62 | "quantity": 1, 63 | "product": { 64 | "id": 1, 65 | "name": "Sobe - Berry Energy", 66 | "price": 24.96 67 | } 68 | } 69 | ] 70 | }""")) 71 | .andExpect(status().isCreated()); 72 | 73 | stopWatch.stop(); 74 | 75 | LOGGER.info("Test took {} ms", stopWatch.getTotalTimeMillis()); 76 | } 77 | } -------------------------------------------------------------------------------- /cqrs/src/test/java/ch/martinelli/demo/cqrs/api/command/OrderControllerTest.java: -------------------------------------------------------------------------------- 1 | package ch.martinelli.demo.cqrs.api.command; 2 | 3 | import ch.martinelli.demo.cqrs.TestCqrsApplication; 4 | import org.junit.jupiter.api.Test; 5 | import org.slf4j.Logger; 6 | import org.slf4j.LoggerFactory; 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc; 9 | import org.springframework.boot.test.context.SpringBootTest; 10 | import org.springframework.context.annotation.Import; 11 | import org.springframework.test.web.servlet.MockMvc; 12 | import org.springframework.test.web.servlet.MvcResult; 13 | import org.springframework.util.StopWatch; 14 | 15 | import java.util.Objects; 16 | import java.util.regex.Pattern; 17 | 18 | import static org.hamcrest.Matchers.startsWith; 19 | import static org.springframework.http.MediaType.APPLICATION_JSON; 20 | import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.patch; 21 | import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post; 22 | import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.header; 23 | import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; 24 | 25 | @Import(TestCqrsApplication.class) 26 | @SpringBootTest 27 | @AutoConfigureMockMvc 28 | class OrderControllerTest { 29 | 30 | private static final Logger LOGGER = LoggerFactory.getLogger(OrderControllerTest.class); 31 | 32 | @Autowired 33 | private MockMvc mockMvc; 34 | 35 | @Test 36 | void createPurchaseOrderWithOneItem() throws Exception { 37 | var stopWatch = new StopWatch(); 38 | stopWatch.start(); 39 | 40 | MvcResult postOrderResult = mockMvc.perform(post("/orders") 41 | .contentType(APPLICATION_JSON) 42 | .content(""" 43 | { 44 | "@type": "CreateOrderCommand", 45 | "customerId": 1 46 | }""")) 47 | .andExpect(status().isCreated()) 48 | .andExpect(header().string("location", startsWith("http://localhost/orders/"))) 49 | .andReturn(); 50 | 51 | var orderId = getId(postOrderResult); 52 | 53 | stopWatch.stop(); 54 | LOGGER.info("Create order took {} ms", stopWatch.getTotalTimeMillis()); 55 | 56 | stopWatch.start(); 57 | 58 | var addOrderItemResult = mockMvc.perform(post("/orders/%s/items".formatted(orderId)) 59 | .contentType(APPLICATION_JSON) 60 | .content(""" 61 | { 62 | "@type": "AddOrderItemCommand", 63 | "orderId": %s, 64 | "productId": 1, 65 | "quantity": 1 66 | }""".formatted(orderId))) 67 | .andExpect(status().isCreated()) 68 | .andExpect(header().string("location", startsWith("http://localhost/orders/%s/items/".formatted(orderId)))) 69 | .andReturn(); 70 | 71 | var orderItemId = getId(addOrderItemResult); 72 | 73 | mockMvc.perform(patch("/orders/%s/items/%s".formatted(orderId, orderItemId)) 74 | .contentType(APPLICATION_JSON) 75 | .content(""" 76 | { 77 | "@type": "UpdateQuantityCommand", 78 | "orderItemId": %s, 79 | "quantity": 1 80 | }""".formatted(orderItemId))) 81 | .andExpect(status().isOk()); 82 | 83 | stopWatch.stop(); 84 | LOGGER.info("Add order item took {} ms", stopWatch.getTotalTimeMillis()); 85 | } 86 | 87 | private long getId(MvcResult mvcResult) { 88 | var location = mvcResult.getResponse().getHeader("location"); 89 | var pattern = Pattern.compile("(\\d+)$"); 90 | var matcher = pattern.matcher(Objects.requireNonNull(location)); 91 | boolean found = matcher.find(); 92 | return found ? Long.parseLong(matcher.group(), 10) : 0L; 93 | } 94 | } -------------------------------------------------------------------------------- /cqrs/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 4.0.0 5 | 6 | org.springframework.boot 7 | spring-boot-starter-parent 8 | 3.4.3 9 | 10 | 11 | 12 | ch.martinelli.demo 13 | cqrs 14 | 0.0.1-SNAPSHOT 15 | 16 | 17 | 21 18 | 2.7.0 19 | 0.0.4 20 | 21 | 22 | 23 | 24 | org.springframework.boot 25 | spring-boot-starter-jooq 26 | 27 | 28 | org.springframework.boot 29 | spring-boot-starter-web 30 | 31 | 32 | org.springdoc 33 | springdoc-openapi-starter-webmvc-ui 34 | ${spring-doc.version} 35 | 36 | 37 | 38 | org.flywaydb 39 | flyway-core 40 | 41 | 42 | org.flywaydb 43 | flyway-database-postgresql 44 | 45 | 46 | 47 | org.postgresql 48 | postgresql 49 | runtime 50 | 51 | 52 | 53 | org.springframework.boot 54 | spring-boot-starter-test 55 | test 56 | 57 | 58 | org.springframework.boot 59 | spring-boot-testcontainers 60 | test 61 | 62 | 63 | org.testcontainers 64 | junit-jupiter 65 | test 66 | 67 | 68 | org.testcontainers 69 | postgresql 70 | test 71 | 72 | 73 | org.springframework.boot 74 | spring-boot-starter-validation 75 | 76 | 77 | 78 | 79 | 80 | 81 | org.springframework.boot 82 | spring-boot-maven-plugin 83 | 84 | 85 | org.testcontainers 86 | testcontainers-jooq-codegen-maven-plugin 87 | ${testcontainers-jooq-codgen-maven-plugin.version} 88 | 89 | 90 | org.testcontainers 91 | postgresql 92 | ${testcontainers.version} 93 | 94 | 95 | org.postgresql 96 | postgresql 97 | ${postgresql.version} 98 | 99 | 100 | org.jooq 101 | jooq-codegen 102 | ${jooq.version} 103 | 104 | 105 | 106 | 107 | generate-jooq-sources 108 | 109 | generate 110 | 111 | generate-sources 112 | 113 | 114 | POSTGRES 115 | 116 | 117 | 118 | 119 | 120 | public 121 | flyway_schema_history 122 | 123 | 124 | ch.martinelli.demo.cqrs.db 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | -------------------------------------------------------------------------------- /cqrs/mvnw.cmd: -------------------------------------------------------------------------------- 1 | @REM ---------------------------------------------------------------------------- 2 | @REM Licensed to the Apache Software Foundation (ASF) under one 3 | @REM or more contributor license agreements. See the NOTICE file 4 | @REM distributed with this work for additional information 5 | @REM regarding copyright ownership. The ASF licenses this file 6 | @REM to you under the Apache License, Version 2.0 (the 7 | @REM "License"); you may not use this file except in compliance 8 | @REM with the License. You may obtain a copy of the License at 9 | @REM 10 | @REM https://www.apache.org/licenses/LICENSE-2.0 11 | @REM 12 | @REM Unless required by applicable law or agreed to in writing, 13 | @REM software distributed under the License is distributed on an 14 | @REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | @REM KIND, either express or implied. See the License for the 16 | @REM specific language governing permissions and limitations 17 | @REM under the License. 18 | @REM ---------------------------------------------------------------------------- 19 | 20 | @REM ---------------------------------------------------------------------------- 21 | @REM Apache Maven Wrapper startup batch script, version 3.2.0 22 | @REM 23 | @REM Required ENV vars: 24 | @REM JAVA_HOME - location of a JDK home dir 25 | @REM 26 | @REM Optional ENV vars 27 | @REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands 28 | @REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a keystroke before ending 29 | @REM MAVEN_OPTS - parameters passed to the Java VM when running Maven 30 | @REM e.g. to debug Maven itself, use 31 | @REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 32 | @REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files 33 | @REM ---------------------------------------------------------------------------- 34 | 35 | @REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on' 36 | @echo off 37 | @REM set title of command window 38 | title %0 39 | @REM enable echoing by setting MAVEN_BATCH_ECHO to 'on' 40 | @if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO% 41 | 42 | @REM set %HOME% to equivalent of $HOME 43 | if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%") 44 | 45 | @REM Execute a user defined script before this one 46 | if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre 47 | @REM check for pre script, once with legacy .bat ending and once with .cmd ending 48 | if exist "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %* 49 | if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\mavenrc_pre.cmd" %* 50 | :skipRcPre 51 | 52 | @setlocal 53 | 54 | set ERROR_CODE=0 55 | 56 | @REM To isolate internal variables from possible post scripts, we use another setlocal 57 | @setlocal 58 | 59 | @REM ==== START VALIDATION ==== 60 | if not "%JAVA_HOME%" == "" goto OkJHome 61 | 62 | echo. 63 | echo Error: JAVA_HOME not found in your environment. >&2 64 | echo Please set the JAVA_HOME variable in your environment to match the >&2 65 | echo location of your Java installation. >&2 66 | echo. 67 | goto error 68 | 69 | :OkJHome 70 | if exist "%JAVA_HOME%\bin\java.exe" goto init 71 | 72 | echo. 73 | echo Error: JAVA_HOME is set to an invalid directory. >&2 74 | echo JAVA_HOME = "%JAVA_HOME%" >&2 75 | echo Please set the JAVA_HOME variable in your environment to match the >&2 76 | echo location of your Java installation. >&2 77 | echo. 78 | goto error 79 | 80 | @REM ==== END VALIDATION ==== 81 | 82 | :init 83 | 84 | @REM Find the project base dir, i.e. the directory that contains the folder ".mvn". 85 | @REM Fallback to current working directory if not found. 86 | 87 | set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR% 88 | IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir 89 | 90 | set EXEC_DIR=%CD% 91 | set WDIR=%EXEC_DIR% 92 | :findBaseDir 93 | IF EXIST "%WDIR%"\.mvn goto baseDirFound 94 | cd .. 95 | IF "%WDIR%"=="%CD%" goto baseDirNotFound 96 | set WDIR=%CD% 97 | goto findBaseDir 98 | 99 | :baseDirFound 100 | set MAVEN_PROJECTBASEDIR=%WDIR% 101 | cd "%EXEC_DIR%" 102 | goto endDetectBaseDir 103 | 104 | :baseDirNotFound 105 | set MAVEN_PROJECTBASEDIR=%EXEC_DIR% 106 | cd "%EXEC_DIR%" 107 | 108 | :endDetectBaseDir 109 | 110 | IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig 111 | 112 | @setlocal EnableExtensions EnableDelayedExpansion 113 | for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a 114 | @endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS% 115 | 116 | :endReadAdditionalConfig 117 | 118 | SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe" 119 | set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar" 120 | set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain 121 | 122 | set WRAPPER_URL="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" 123 | 124 | FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO ( 125 | IF "%%A"=="wrapperUrl" SET WRAPPER_URL=%%B 126 | ) 127 | 128 | @REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central 129 | @REM This allows using the maven wrapper in projects that prohibit checking in binary data. 130 | if exist %WRAPPER_JAR% ( 131 | if "%MVNW_VERBOSE%" == "true" ( 132 | echo Found %WRAPPER_JAR% 133 | ) 134 | ) else ( 135 | if not "%MVNW_REPOURL%" == "" ( 136 | SET WRAPPER_URL="%MVNW_REPOURL%/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" 137 | ) 138 | if "%MVNW_VERBOSE%" == "true" ( 139 | echo Couldn't find %WRAPPER_JAR%, downloading it ... 140 | echo Downloading from: %WRAPPER_URL% 141 | ) 142 | 143 | powershell -Command "&{"^ 144 | "$webclient = new-object System.Net.WebClient;"^ 145 | "if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^ 146 | "$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^ 147 | "}"^ 148 | "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%WRAPPER_URL%', '%WRAPPER_JAR%')"^ 149 | "}" 150 | if "%MVNW_VERBOSE%" == "true" ( 151 | echo Finished downloading %WRAPPER_JAR% 152 | ) 153 | ) 154 | @REM End of extension 155 | 156 | @REM If specified, validate the SHA-256 sum of the Maven wrapper jar file 157 | SET WRAPPER_SHA_256_SUM="" 158 | FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO ( 159 | IF "%%A"=="wrapperSha256Sum" SET WRAPPER_SHA_256_SUM=%%B 160 | ) 161 | IF NOT %WRAPPER_SHA_256_SUM%=="" ( 162 | powershell -Command "&{"^ 163 | "$hash = (Get-FileHash \"%WRAPPER_JAR%\" -Algorithm SHA256).Hash.ToLower();"^ 164 | "If('%WRAPPER_SHA_256_SUM%' -ne $hash){"^ 165 | " Write-Output 'Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised.';"^ 166 | " Write-Output 'Investigate or delete %WRAPPER_JAR% to attempt a clean download.';"^ 167 | " Write-Output 'If you updated your Maven version, you need to update the specified wrapperSha256Sum property.';"^ 168 | " exit 1;"^ 169 | "}"^ 170 | "}" 171 | if ERRORLEVEL 1 goto error 172 | ) 173 | 174 | @REM Provide a "standardized" way to retrieve the CLI args that will 175 | @REM work with both Windows and non-Windows executions. 176 | set MAVEN_CMD_LINE_ARGS=%* 177 | 178 | %MAVEN_JAVA_EXE% ^ 179 | %JVM_CONFIG_MAVEN_PROPS% ^ 180 | %MAVEN_OPTS% ^ 181 | %MAVEN_DEBUG_OPTS% ^ 182 | -classpath %WRAPPER_JAR% ^ 183 | "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" ^ 184 | %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %* 185 | if ERRORLEVEL 1 goto error 186 | goto end 187 | 188 | :error 189 | set ERROR_CODE=1 190 | 191 | :end 192 | @endlocal & set ERROR_CODE=%ERROR_CODE% 193 | 194 | if not "%MAVEN_SKIP_RC%"=="" goto skipRcPost 195 | @REM check for post script, once with legacy .bat ending and once with .cmd ending 196 | if exist "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat" 197 | if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\mavenrc_post.cmd" 198 | :skipRcPost 199 | 200 | @REM pause the script if MAVEN_BATCH_PAUSE is set to 'on' 201 | if "%MAVEN_BATCH_PAUSE%"=="on" pause 202 | 203 | if "%MAVEN_TERMINATE_CMD%"=="on" exit %ERROR_CODE% 204 | 205 | cmd /C exit /B %ERROR_CODE% 206 | -------------------------------------------------------------------------------- /traditional/mvnw.cmd: -------------------------------------------------------------------------------- 1 | @REM ---------------------------------------------------------------------------- 2 | @REM Licensed to the Apache Software Foundation (ASF) under one 3 | @REM or more contributor license agreements. See the NOTICE file 4 | @REM distributed with this work for additional information 5 | @REM regarding copyright ownership. The ASF licenses this file 6 | @REM to you under the Apache License, Version 2.0 (the 7 | @REM "License"); you may not use this file except in compliance 8 | @REM with the License. You may obtain a copy of the License at 9 | @REM 10 | @REM https://www.apache.org/licenses/LICENSE-2.0 11 | @REM 12 | @REM Unless required by applicable law or agreed to in writing, 13 | @REM software distributed under the License is distributed on an 14 | @REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 | @REM KIND, either express or implied. See the License for the 16 | @REM specific language governing permissions and limitations 17 | @REM under the License. 18 | @REM ---------------------------------------------------------------------------- 19 | 20 | @REM ---------------------------------------------------------------------------- 21 | @REM Apache Maven Wrapper startup batch script, version 3.2.0 22 | @REM 23 | @REM Required ENV vars: 24 | @REM JAVA_HOME - location of a JDK home dir 25 | @REM 26 | @REM Optional ENV vars 27 | @REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands 28 | @REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a keystroke before ending 29 | @REM MAVEN_OPTS - parameters passed to the Java VM when running Maven 30 | @REM e.g. to debug Maven itself, use 31 | @REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 32 | @REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files 33 | @REM ---------------------------------------------------------------------------- 34 | 35 | @REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on' 36 | @echo off 37 | @REM set title of command window 38 | title %0 39 | @REM enable echoing by setting MAVEN_BATCH_ECHO to 'on' 40 | @if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO% 41 | 42 | @REM set %HOME% to equivalent of $HOME 43 | if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%") 44 | 45 | @REM Execute a user defined script before this one 46 | if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre 47 | @REM check for pre script, once with legacy .bat ending and once with .cmd ending 48 | if exist "%USERPROFILE%\mavenrc_pre.bat" call "%USERPROFILE%\mavenrc_pre.bat" %* 49 | if exist "%USERPROFILE%\mavenrc_pre.cmd" call "%USERPROFILE%\mavenrc_pre.cmd" %* 50 | :skipRcPre 51 | 52 | @setlocal 53 | 54 | set ERROR_CODE=0 55 | 56 | @REM To isolate internal variables from possible post scripts, we use another setlocal 57 | @setlocal 58 | 59 | @REM ==== START VALIDATION ==== 60 | if not "%JAVA_HOME%" == "" goto OkJHome 61 | 62 | echo. 63 | echo Error: JAVA_HOME not found in your environment. >&2 64 | echo Please set the JAVA_HOME variable in your environment to match the >&2 65 | echo location of your Java installation. >&2 66 | echo. 67 | goto error 68 | 69 | :OkJHome 70 | if exist "%JAVA_HOME%\bin\java.exe" goto init 71 | 72 | echo. 73 | echo Error: JAVA_HOME is set to an invalid directory. >&2 74 | echo JAVA_HOME = "%JAVA_HOME%" >&2 75 | echo Please set the JAVA_HOME variable in your environment to match the >&2 76 | echo location of your Java installation. >&2 77 | echo. 78 | goto error 79 | 80 | @REM ==== END VALIDATION ==== 81 | 82 | :init 83 | 84 | @REM Find the project base dir, i.e. the directory that contains the folder ".mvn". 85 | @REM Fallback to current working directory if not found. 86 | 87 | set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR% 88 | IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir 89 | 90 | set EXEC_DIR=%CD% 91 | set WDIR=%EXEC_DIR% 92 | :findBaseDir 93 | IF EXIST "%WDIR%"\.mvn goto baseDirFound 94 | cd .. 95 | IF "%WDIR%"=="%CD%" goto baseDirNotFound 96 | set WDIR=%CD% 97 | goto findBaseDir 98 | 99 | :baseDirFound 100 | set MAVEN_PROJECTBASEDIR=%WDIR% 101 | cd "%EXEC_DIR%" 102 | goto endDetectBaseDir 103 | 104 | :baseDirNotFound 105 | set MAVEN_PROJECTBASEDIR=%EXEC_DIR% 106 | cd "%EXEC_DIR%" 107 | 108 | :endDetectBaseDir 109 | 110 | IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig 111 | 112 | @setlocal EnableExtensions EnableDelayedExpansion 113 | for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a 114 | @endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS% 115 | 116 | :endReadAdditionalConfig 117 | 118 | SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe" 119 | set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar" 120 | set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain 121 | 122 | set WRAPPER_URL="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" 123 | 124 | FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO ( 125 | IF "%%A"=="wrapperUrl" SET WRAPPER_URL=%%B 126 | ) 127 | 128 | @REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central 129 | @REM This allows using the maven wrapper in projects that prohibit checking in binary data. 130 | if exist %WRAPPER_JAR% ( 131 | if "%MVNW_VERBOSE%" == "true" ( 132 | echo Found %WRAPPER_JAR% 133 | ) 134 | ) else ( 135 | if not "%MVNW_REPOURL%" == "" ( 136 | SET WRAPPER_URL="%MVNW_REPOURL%/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" 137 | ) 138 | if "%MVNW_VERBOSE%" == "true" ( 139 | echo Couldn't find %WRAPPER_JAR%, downloading it ... 140 | echo Downloading from: %WRAPPER_URL% 141 | ) 142 | 143 | powershell -Command "&{"^ 144 | "$webclient = new-object System.Net.WebClient;"^ 145 | "if (-not ([string]::IsNullOrEmpty('%MVNW_USERNAME%') -and [string]::IsNullOrEmpty('%MVNW_PASSWORD%'))) {"^ 146 | "$webclient.Credentials = new-object System.Net.NetworkCredential('%MVNW_USERNAME%', '%MVNW_PASSWORD%');"^ 147 | "}"^ 148 | "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; $webclient.DownloadFile('%WRAPPER_URL%', '%WRAPPER_JAR%')"^ 149 | "}" 150 | if "%MVNW_VERBOSE%" == "true" ( 151 | echo Finished downloading %WRAPPER_JAR% 152 | ) 153 | ) 154 | @REM End of extension 155 | 156 | @REM If specified, validate the SHA-256 sum of the Maven wrapper jar file 157 | SET WRAPPER_SHA_256_SUM="" 158 | FOR /F "usebackq tokens=1,2 delims==" %%A IN ("%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties") DO ( 159 | IF "%%A"=="wrapperSha256Sum" SET WRAPPER_SHA_256_SUM=%%B 160 | ) 161 | IF NOT %WRAPPER_SHA_256_SUM%=="" ( 162 | powershell -Command "&{"^ 163 | "$hash = (Get-FileHash \"%WRAPPER_JAR%\" -Algorithm SHA256).Hash.ToLower();"^ 164 | "If('%WRAPPER_SHA_256_SUM%' -ne $hash){"^ 165 | " Write-Output 'Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised.';"^ 166 | " Write-Output 'Investigate or delete %WRAPPER_JAR% to attempt a clean download.';"^ 167 | " Write-Output 'If you updated your Maven version, you need to update the specified wrapperSha256Sum property.';"^ 168 | " exit 1;"^ 169 | "}"^ 170 | "}" 171 | if ERRORLEVEL 1 goto error 172 | ) 173 | 174 | @REM Provide a "standardized" way to retrieve the CLI args that will 175 | @REM work with both Windows and non-Windows executions. 176 | set MAVEN_CMD_LINE_ARGS=%* 177 | 178 | %MAVEN_JAVA_EXE% ^ 179 | %JVM_CONFIG_MAVEN_PROPS% ^ 180 | %MAVEN_OPTS% ^ 181 | %MAVEN_DEBUG_OPTS% ^ 182 | -classpath %WRAPPER_JAR% ^ 183 | "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" ^ 184 | %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %* 185 | if ERRORLEVEL 1 goto error 186 | goto end 187 | 188 | :error 189 | set ERROR_CODE=1 190 | 191 | :end 192 | @endlocal & set ERROR_CODE=%ERROR_CODE% 193 | 194 | if not "%MAVEN_SKIP_RC%"=="" goto skipRcPost 195 | @REM check for post script, once with legacy .bat ending and once with .cmd ending 196 | if exist "%USERPROFILE%\mavenrc_post.bat" call "%USERPROFILE%\mavenrc_post.bat" 197 | if exist "%USERPROFILE%\mavenrc_post.cmd" call "%USERPROFILE%\mavenrc_post.cmd" 198 | :skipRcPost 199 | 200 | @REM pause the script if MAVEN_BATCH_PAUSE is set to 'on' 201 | if "%MAVEN_BATCH_PAUSE%"=="on" pause 202 | 203 | if "%MAVEN_TERMINATE_CMD%"=="on" exit %ERROR_CODE% 204 | 205 | cmd /C exit /B %ERROR_CODE% 206 | -------------------------------------------------------------------------------- /cqrs/mvnw: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # ---------------------------------------------------------------------------- 3 | # Licensed to the Apache Software Foundation (ASF) under one 4 | # or more contributor license agreements. See the NOTICE file 5 | # distributed with this work for additional information 6 | # regarding copyright ownership. The ASF licenses this file 7 | # to you under the Apache License, Version 2.0 (the 8 | # "License"); you may not use this file except in compliance 9 | # with the License. You may obtain a copy of the License at 10 | # 11 | # https://www.apache.org/licenses/LICENSE-2.0 12 | # 13 | # Unless required by applicable law or agreed to in writing, 14 | # software distributed under the License is distributed on an 15 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 | # KIND, either express or implied. See the License for the 17 | # specific language governing permissions and limitations 18 | # under the License. 19 | # ---------------------------------------------------------------------------- 20 | 21 | # ---------------------------------------------------------------------------- 22 | # Apache Maven Wrapper startup batch script, version 3.2.0 23 | # 24 | # Required ENV vars: 25 | # ------------------ 26 | # JAVA_HOME - location of a JDK home dir 27 | # 28 | # Optional ENV vars 29 | # ----------------- 30 | # MAVEN_OPTS - parameters passed to the Java VM when running Maven 31 | # e.g. to debug Maven itself, use 32 | # set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 33 | # MAVEN_SKIP_RC - flag to disable loading of mavenrc files 34 | # ---------------------------------------------------------------------------- 35 | 36 | if [ -z "$MAVEN_SKIP_RC" ] ; then 37 | 38 | if [ -f /usr/local/etc/mavenrc ] ; then 39 | . /usr/local/etc/mavenrc 40 | fi 41 | 42 | if [ -f /etc/mavenrc ] ; then 43 | . /etc/mavenrc 44 | fi 45 | 46 | if [ -f "$HOME/.mavenrc" ] ; then 47 | . "$HOME/.mavenrc" 48 | fi 49 | 50 | fi 51 | 52 | # OS specific support. $var _must_ be set to either true or false. 53 | cygwin=false; 54 | darwin=false; 55 | mingw=false 56 | case "$(uname)" in 57 | CYGWIN*) cygwin=true ;; 58 | MINGW*) mingw=true;; 59 | Darwin*) darwin=true 60 | # Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home 61 | # See https://developer.apple.com/library/mac/qa/qa1170/_index.html 62 | if [ -z "$JAVA_HOME" ]; then 63 | if [ -x "/usr/libexec/java_home" ]; then 64 | JAVA_HOME="$(/usr/libexec/java_home)"; export JAVA_HOME 65 | else 66 | JAVA_HOME="/Library/Java/Home"; export JAVA_HOME 67 | fi 68 | fi 69 | ;; 70 | esac 71 | 72 | if [ -z "$JAVA_HOME" ] ; then 73 | if [ -r /etc/gentoo-release ] ; then 74 | JAVA_HOME=$(java-config --jre-home) 75 | fi 76 | fi 77 | 78 | # For Cygwin, ensure paths are in UNIX format before anything is touched 79 | if $cygwin ; then 80 | [ -n "$JAVA_HOME" ] && 81 | JAVA_HOME=$(cygpath --unix "$JAVA_HOME") 82 | [ -n "$CLASSPATH" ] && 83 | CLASSPATH=$(cygpath --path --unix "$CLASSPATH") 84 | fi 85 | 86 | # For Mingw, ensure paths are in UNIX format before anything is touched 87 | if $mingw ; then 88 | [ -n "$JAVA_HOME" ] && [ -d "$JAVA_HOME" ] && 89 | JAVA_HOME="$(cd "$JAVA_HOME" || (echo "cannot cd into $JAVA_HOME."; exit 1); pwd)" 90 | fi 91 | 92 | if [ -z "$JAVA_HOME" ]; then 93 | javaExecutable="$(which javac)" 94 | if [ -n "$javaExecutable" ] && ! [ "$(expr "\"$javaExecutable\"" : '\([^ ]*\)')" = "no" ]; then 95 | # readlink(1) is not available as standard on Solaris 10. 96 | readLink=$(which readlink) 97 | if [ ! "$(expr "$readLink" : '\([^ ]*\)')" = "no" ]; then 98 | if $darwin ; then 99 | javaHome="$(dirname "\"$javaExecutable\"")" 100 | javaExecutable="$(cd "\"$javaHome\"" && pwd -P)/javac" 101 | else 102 | javaExecutable="$(readlink -f "\"$javaExecutable\"")" 103 | fi 104 | javaHome="$(dirname "\"$javaExecutable\"")" 105 | javaHome=$(expr "$javaHome" : '\(.*\)/bin') 106 | JAVA_HOME="$javaHome" 107 | export JAVA_HOME 108 | fi 109 | fi 110 | fi 111 | 112 | if [ -z "$JAVACMD" ] ; then 113 | if [ -n "$JAVA_HOME" ] ; then 114 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 115 | # IBM's JDK on AIX uses strange locations for the executables 116 | JAVACMD="$JAVA_HOME/jre/sh/java" 117 | else 118 | JAVACMD="$JAVA_HOME/bin/java" 119 | fi 120 | else 121 | JAVACMD="$(\unset -f command 2>/dev/null; \command -v java)" 122 | fi 123 | fi 124 | 125 | if [ ! -x "$JAVACMD" ] ; then 126 | echo "Error: JAVA_HOME is not defined correctly." >&2 127 | echo " We cannot execute $JAVACMD" >&2 128 | exit 1 129 | fi 130 | 131 | if [ -z "$JAVA_HOME" ] ; then 132 | echo "Warning: JAVA_HOME environment variable is not set." 133 | fi 134 | 135 | # traverses directory structure from process work directory to filesystem root 136 | # first directory with .mvn subdirectory is considered project base directory 137 | find_maven_basedir() { 138 | if [ -z "$1" ] 139 | then 140 | echo "Path not specified to find_maven_basedir" 141 | return 1 142 | fi 143 | 144 | basedir="$1" 145 | wdir="$1" 146 | while [ "$wdir" != '/' ] ; do 147 | if [ -d "$wdir"/.mvn ] ; then 148 | basedir=$wdir 149 | break 150 | fi 151 | # workaround for JBEAP-8937 (on Solaris 10/Sparc) 152 | if [ -d "${wdir}" ]; then 153 | wdir=$(cd "$wdir/.." || exit 1; pwd) 154 | fi 155 | # end of workaround 156 | done 157 | printf '%s' "$(cd "$basedir" || exit 1; pwd)" 158 | } 159 | 160 | # concatenates all lines of a file 161 | concat_lines() { 162 | if [ -f "$1" ]; then 163 | # Remove \r in case we run on Windows within Git Bash 164 | # and check out the repository with auto CRLF management 165 | # enabled. Otherwise, we may read lines that are delimited with 166 | # \r\n and produce $'-Xarg\r' rather than -Xarg due to word 167 | # splitting rules. 168 | tr -s '\r\n' ' ' < "$1" 169 | fi 170 | } 171 | 172 | log() { 173 | if [ "$MVNW_VERBOSE" = true ]; then 174 | printf '%s\n' "$1" 175 | fi 176 | } 177 | 178 | BASE_DIR=$(find_maven_basedir "$(dirname "$0")") 179 | if [ -z "$BASE_DIR" ]; then 180 | exit 1; 181 | fi 182 | 183 | MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}; export MAVEN_PROJECTBASEDIR 184 | log "$MAVEN_PROJECTBASEDIR" 185 | 186 | ########################################################################################## 187 | # Extension to allow automatically downloading the maven-wrapper.jar from Maven-central 188 | # This allows using the maven wrapper in projects that prohibit checking in binary data. 189 | ########################################################################################## 190 | wrapperJarPath="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" 191 | if [ -r "$wrapperJarPath" ]; then 192 | log "Found $wrapperJarPath" 193 | else 194 | log "Couldn't find $wrapperJarPath, downloading it ..." 195 | 196 | if [ -n "$MVNW_REPOURL" ]; then 197 | wrapperUrl="$MVNW_REPOURL/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" 198 | else 199 | wrapperUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" 200 | fi 201 | while IFS="=" read -r key value; do 202 | # Remove '\r' from value to allow usage on windows as IFS does not consider '\r' as a separator ( considers space, tab, new line ('\n'), and custom '=' ) 203 | safeValue=$(echo "$value" | tr -d '\r') 204 | case "$key" in (wrapperUrl) wrapperUrl="$safeValue"; break ;; 205 | esac 206 | done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties" 207 | log "Downloading from: $wrapperUrl" 208 | 209 | if $cygwin; then 210 | wrapperJarPath=$(cygpath --path --windows "$wrapperJarPath") 211 | fi 212 | 213 | if command -v wget > /dev/null; then 214 | log "Found wget ... using wget" 215 | [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--quiet" 216 | if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then 217 | wget $QUIET "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath" 218 | else 219 | wget $QUIET --http-user="$MVNW_USERNAME" --http-password="$MVNW_PASSWORD" "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath" 220 | fi 221 | elif command -v curl > /dev/null; then 222 | log "Found curl ... using curl" 223 | [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--silent" 224 | if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then 225 | curl $QUIET -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath" 226 | else 227 | curl $QUIET --user "$MVNW_USERNAME:$MVNW_PASSWORD" -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath" 228 | fi 229 | else 230 | log "Falling back to using Java to download" 231 | javaSource="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.java" 232 | javaClass="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.class" 233 | # For Cygwin, switch paths to Windows format before running javac 234 | if $cygwin; then 235 | javaSource=$(cygpath --path --windows "$javaSource") 236 | javaClass=$(cygpath --path --windows "$javaClass") 237 | fi 238 | if [ -e "$javaSource" ]; then 239 | if [ ! -e "$javaClass" ]; then 240 | log " - Compiling MavenWrapperDownloader.java ..." 241 | ("$JAVA_HOME/bin/javac" "$javaSource") 242 | fi 243 | if [ -e "$javaClass" ]; then 244 | log " - Running MavenWrapperDownloader.java ..." 245 | ("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$wrapperUrl" "$wrapperJarPath") || rm -f "$wrapperJarPath" 246 | fi 247 | fi 248 | fi 249 | fi 250 | ########################################################################################## 251 | # End of extension 252 | ########################################################################################## 253 | 254 | # If specified, validate the SHA-256 sum of the Maven wrapper jar file 255 | wrapperSha256Sum="" 256 | while IFS="=" read -r key value; do 257 | case "$key" in (wrapperSha256Sum) wrapperSha256Sum=$value; break ;; 258 | esac 259 | done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties" 260 | if [ -n "$wrapperSha256Sum" ]; then 261 | wrapperSha256Result=false 262 | if command -v sha256sum > /dev/null; then 263 | if echo "$wrapperSha256Sum $wrapperJarPath" | sha256sum -c > /dev/null 2>&1; then 264 | wrapperSha256Result=true 265 | fi 266 | elif command -v shasum > /dev/null; then 267 | if echo "$wrapperSha256Sum $wrapperJarPath" | shasum -a 256 -c > /dev/null 2>&1; then 268 | wrapperSha256Result=true 269 | fi 270 | else 271 | echo "Checksum validation was requested but neither 'sha256sum' or 'shasum' are available." 272 | echo "Please install either command, or disable validation by removing 'wrapperSha256Sum' from your maven-wrapper.properties." 273 | exit 1 274 | fi 275 | if [ $wrapperSha256Result = false ]; then 276 | echo "Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised." >&2 277 | echo "Investigate or delete $wrapperJarPath to attempt a clean download." >&2 278 | echo "If you updated your Maven version, you need to update the specified wrapperSha256Sum property." >&2 279 | exit 1 280 | fi 281 | fi 282 | 283 | MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS" 284 | 285 | # For Cygwin, switch paths to Windows format before running java 286 | if $cygwin; then 287 | [ -n "$JAVA_HOME" ] && 288 | JAVA_HOME=$(cygpath --path --windows "$JAVA_HOME") 289 | [ -n "$CLASSPATH" ] && 290 | CLASSPATH=$(cygpath --path --windows "$CLASSPATH") 291 | [ -n "$MAVEN_PROJECTBASEDIR" ] && 292 | MAVEN_PROJECTBASEDIR=$(cygpath --path --windows "$MAVEN_PROJECTBASEDIR") 293 | fi 294 | 295 | # Provide a "standardized" way to retrieve the CLI args that will 296 | # work with both Windows and non-Windows executions. 297 | MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $*" 298 | export MAVEN_CMD_LINE_ARGS 299 | 300 | WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain 301 | 302 | # shellcheck disable=SC2086 # safe args 303 | exec "$JAVACMD" \ 304 | $MAVEN_OPTS \ 305 | $MAVEN_DEBUG_OPTS \ 306 | -classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \ 307 | "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \ 308 | ${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@" 309 | -------------------------------------------------------------------------------- /traditional/mvnw: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # ---------------------------------------------------------------------------- 3 | # Licensed to the Apache Software Foundation (ASF) under one 4 | # or more contributor license agreements. See the NOTICE file 5 | # distributed with this work for additional information 6 | # regarding copyright ownership. The ASF licenses this file 7 | # to you under the Apache License, Version 2.0 (the 8 | # "License"); you may not use this file except in compliance 9 | # with the License. You may obtain a copy of the License at 10 | # 11 | # https://www.apache.org/licenses/LICENSE-2.0 12 | # 13 | # Unless required by applicable law or agreed to in writing, 14 | # software distributed under the License is distributed on an 15 | # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16 | # KIND, either express or implied. See the License for the 17 | # specific language governing permissions and limitations 18 | # under the License. 19 | # ---------------------------------------------------------------------------- 20 | 21 | # ---------------------------------------------------------------------------- 22 | # Apache Maven Wrapper startup batch script, version 3.2.0 23 | # 24 | # Required ENV vars: 25 | # ------------------ 26 | # JAVA_HOME - location of a JDK home dir 27 | # 28 | # Optional ENV vars 29 | # ----------------- 30 | # MAVEN_OPTS - parameters passed to the Java VM when running Maven 31 | # e.g. to debug Maven itself, use 32 | # set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 33 | # MAVEN_SKIP_RC - flag to disable loading of mavenrc files 34 | # ---------------------------------------------------------------------------- 35 | 36 | if [ -z "$MAVEN_SKIP_RC" ] ; then 37 | 38 | if [ -f /usr/local/etc/mavenrc ] ; then 39 | . /usr/local/etc/mavenrc 40 | fi 41 | 42 | if [ -f /etc/mavenrc ] ; then 43 | . /etc/mavenrc 44 | fi 45 | 46 | if [ -f "$HOME/.mavenrc" ] ; then 47 | . "$HOME/.mavenrc" 48 | fi 49 | 50 | fi 51 | 52 | # OS specific support. $var _must_ be set to either true or false. 53 | cygwin=false; 54 | darwin=false; 55 | mingw=false 56 | case "$(uname)" in 57 | CYGWIN*) cygwin=true ;; 58 | MINGW*) mingw=true;; 59 | Darwin*) darwin=true 60 | # Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home 61 | # See https://developer.apple.com/library/mac/qa/qa1170/_index.html 62 | if [ -z "$JAVA_HOME" ]; then 63 | if [ -x "/usr/libexec/java_home" ]; then 64 | JAVA_HOME="$(/usr/libexec/java_home)"; export JAVA_HOME 65 | else 66 | JAVA_HOME="/Library/Java/Home"; export JAVA_HOME 67 | fi 68 | fi 69 | ;; 70 | esac 71 | 72 | if [ -z "$JAVA_HOME" ] ; then 73 | if [ -r /etc/gentoo-release ] ; then 74 | JAVA_HOME=$(java-config --jre-home) 75 | fi 76 | fi 77 | 78 | # For Cygwin, ensure paths are in UNIX format before anything is touched 79 | if $cygwin ; then 80 | [ -n "$JAVA_HOME" ] && 81 | JAVA_HOME=$(cygpath --unix "$JAVA_HOME") 82 | [ -n "$CLASSPATH" ] && 83 | CLASSPATH=$(cygpath --path --unix "$CLASSPATH") 84 | fi 85 | 86 | # For Mingw, ensure paths are in UNIX format before anything is touched 87 | if $mingw ; then 88 | [ -n "$JAVA_HOME" ] && [ -d "$JAVA_HOME" ] && 89 | JAVA_HOME="$(cd "$JAVA_HOME" || (echo "cannot cd into $JAVA_HOME."; exit 1); pwd)" 90 | fi 91 | 92 | if [ -z "$JAVA_HOME" ]; then 93 | javaExecutable="$(which javac)" 94 | if [ -n "$javaExecutable" ] && ! [ "$(expr "\"$javaExecutable\"" : '\([^ ]*\)')" = "no" ]; then 95 | # readlink(1) is not available as standard on Solaris 10. 96 | readLink=$(which readlink) 97 | if [ ! "$(expr "$readLink" : '\([^ ]*\)')" = "no" ]; then 98 | if $darwin ; then 99 | javaHome="$(dirname "\"$javaExecutable\"")" 100 | javaExecutable="$(cd "\"$javaHome\"" && pwd -P)/javac" 101 | else 102 | javaExecutable="$(readlink -f "\"$javaExecutable\"")" 103 | fi 104 | javaHome="$(dirname "\"$javaExecutable\"")" 105 | javaHome=$(expr "$javaHome" : '\(.*\)/bin') 106 | JAVA_HOME="$javaHome" 107 | export JAVA_HOME 108 | fi 109 | fi 110 | fi 111 | 112 | if [ -z "$JAVACMD" ] ; then 113 | if [ -n "$JAVA_HOME" ] ; then 114 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 115 | # IBM's JDK on AIX uses strange locations for the executables 116 | JAVACMD="$JAVA_HOME/jre/sh/java" 117 | else 118 | JAVACMD="$JAVA_HOME/bin/java" 119 | fi 120 | else 121 | JAVACMD="$(\unset -f command 2>/dev/null; \command -v java)" 122 | fi 123 | fi 124 | 125 | if [ ! -x "$JAVACMD" ] ; then 126 | echo "Error: JAVA_HOME is not defined correctly." >&2 127 | echo " We cannot execute $JAVACMD" >&2 128 | exit 1 129 | fi 130 | 131 | if [ -z "$JAVA_HOME" ] ; then 132 | echo "Warning: JAVA_HOME environment variable is not set." 133 | fi 134 | 135 | # traverses directory structure from process work directory to filesystem root 136 | # first directory with .mvn subdirectory is considered project base directory 137 | find_maven_basedir() { 138 | if [ -z "$1" ] 139 | then 140 | echo "Path not specified to find_maven_basedir" 141 | return 1 142 | fi 143 | 144 | basedir="$1" 145 | wdir="$1" 146 | while [ "$wdir" != '/' ] ; do 147 | if [ -d "$wdir"/.mvn ] ; then 148 | basedir=$wdir 149 | break 150 | fi 151 | # workaround for JBEAP-8937 (on Solaris 10/Sparc) 152 | if [ -d "${wdir}" ]; then 153 | wdir=$(cd "$wdir/.." || exit 1; pwd) 154 | fi 155 | # end of workaround 156 | done 157 | printf '%s' "$(cd "$basedir" || exit 1; pwd)" 158 | } 159 | 160 | # concatenates all lines of a file 161 | concat_lines() { 162 | if [ -f "$1" ]; then 163 | # Remove \r in case we run on Windows within Git Bash 164 | # and check out the repository with auto CRLF management 165 | # enabled. Otherwise, we may read lines that are delimited with 166 | # \r\n and produce $'-Xarg\r' rather than -Xarg due to word 167 | # splitting rules. 168 | tr -s '\r\n' ' ' < "$1" 169 | fi 170 | } 171 | 172 | log() { 173 | if [ "$MVNW_VERBOSE" = true ]; then 174 | printf '%s\n' "$1" 175 | fi 176 | } 177 | 178 | BASE_DIR=$(find_maven_basedir "$(dirname "$0")") 179 | if [ -z "$BASE_DIR" ]; then 180 | exit 1; 181 | fi 182 | 183 | MAVEN_PROJECTBASEDIR=${MAVEN_BASEDIR:-"$BASE_DIR"}; export MAVEN_PROJECTBASEDIR 184 | log "$MAVEN_PROJECTBASEDIR" 185 | 186 | ########################################################################################## 187 | # Extension to allow automatically downloading the maven-wrapper.jar from Maven-central 188 | # This allows using the maven wrapper in projects that prohibit checking in binary data. 189 | ########################################################################################## 190 | wrapperJarPath="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" 191 | if [ -r "$wrapperJarPath" ]; then 192 | log "Found $wrapperJarPath" 193 | else 194 | log "Couldn't find $wrapperJarPath, downloading it ..." 195 | 196 | if [ -n "$MVNW_REPOURL" ]; then 197 | wrapperUrl="$MVNW_REPOURL/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" 198 | else 199 | wrapperUrl="https://repo.maven.apache.org/maven2/org/apache/maven/wrapper/maven-wrapper/3.2.0/maven-wrapper-3.2.0.jar" 200 | fi 201 | while IFS="=" read -r key value; do 202 | # Remove '\r' from value to allow usage on windows as IFS does not consider '\r' as a separator ( considers space, tab, new line ('\n'), and custom '=' ) 203 | safeValue=$(echo "$value" | tr -d '\r') 204 | case "$key" in (wrapperUrl) wrapperUrl="$safeValue"; break ;; 205 | esac 206 | done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties" 207 | log "Downloading from: $wrapperUrl" 208 | 209 | if $cygwin; then 210 | wrapperJarPath=$(cygpath --path --windows "$wrapperJarPath") 211 | fi 212 | 213 | if command -v wget > /dev/null; then 214 | log "Found wget ... using wget" 215 | [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--quiet" 216 | if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then 217 | wget $QUIET "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath" 218 | else 219 | wget $QUIET --http-user="$MVNW_USERNAME" --http-password="$MVNW_PASSWORD" "$wrapperUrl" -O "$wrapperJarPath" || rm -f "$wrapperJarPath" 220 | fi 221 | elif command -v curl > /dev/null; then 222 | log "Found curl ... using curl" 223 | [ "$MVNW_VERBOSE" = true ] && QUIET="" || QUIET="--silent" 224 | if [ -z "$MVNW_USERNAME" ] || [ -z "$MVNW_PASSWORD" ]; then 225 | curl $QUIET -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath" 226 | else 227 | curl $QUIET --user "$MVNW_USERNAME:$MVNW_PASSWORD" -o "$wrapperJarPath" "$wrapperUrl" -f -L || rm -f "$wrapperJarPath" 228 | fi 229 | else 230 | log "Falling back to using Java to download" 231 | javaSource="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.java" 232 | javaClass="$MAVEN_PROJECTBASEDIR/.mvn/wrapper/MavenWrapperDownloader.class" 233 | # For Cygwin, switch paths to Windows format before running javac 234 | if $cygwin; then 235 | javaSource=$(cygpath --path --windows "$javaSource") 236 | javaClass=$(cygpath --path --windows "$javaClass") 237 | fi 238 | if [ -e "$javaSource" ]; then 239 | if [ ! -e "$javaClass" ]; then 240 | log " - Compiling MavenWrapperDownloader.java ..." 241 | ("$JAVA_HOME/bin/javac" "$javaSource") 242 | fi 243 | if [ -e "$javaClass" ]; then 244 | log " - Running MavenWrapperDownloader.java ..." 245 | ("$JAVA_HOME/bin/java" -cp .mvn/wrapper MavenWrapperDownloader "$wrapperUrl" "$wrapperJarPath") || rm -f "$wrapperJarPath" 246 | fi 247 | fi 248 | fi 249 | fi 250 | ########################################################################################## 251 | # End of extension 252 | ########################################################################################## 253 | 254 | # If specified, validate the SHA-256 sum of the Maven wrapper jar file 255 | wrapperSha256Sum="" 256 | while IFS="=" read -r key value; do 257 | case "$key" in (wrapperSha256Sum) wrapperSha256Sum=$value; break ;; 258 | esac 259 | done < "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.properties" 260 | if [ -n "$wrapperSha256Sum" ]; then 261 | wrapperSha256Result=false 262 | if command -v sha256sum > /dev/null; then 263 | if echo "$wrapperSha256Sum $wrapperJarPath" | sha256sum -c > /dev/null 2>&1; then 264 | wrapperSha256Result=true 265 | fi 266 | elif command -v shasum > /dev/null; then 267 | if echo "$wrapperSha256Sum $wrapperJarPath" | shasum -a 256 -c > /dev/null 2>&1; then 268 | wrapperSha256Result=true 269 | fi 270 | else 271 | echo "Checksum validation was requested but neither 'sha256sum' or 'shasum' are available." 272 | echo "Please install either command, or disable validation by removing 'wrapperSha256Sum' from your maven-wrapper.properties." 273 | exit 1 274 | fi 275 | if [ $wrapperSha256Result = false ]; then 276 | echo "Error: Failed to validate Maven wrapper SHA-256, your Maven wrapper might be compromised." >&2 277 | echo "Investigate or delete $wrapperJarPath to attempt a clean download." >&2 278 | echo "If you updated your Maven version, you need to update the specified wrapperSha256Sum property." >&2 279 | exit 1 280 | fi 281 | fi 282 | 283 | MAVEN_OPTS="$(concat_lines "$MAVEN_PROJECTBASEDIR/.mvn/jvm.config") $MAVEN_OPTS" 284 | 285 | # For Cygwin, switch paths to Windows format before running java 286 | if $cygwin; then 287 | [ -n "$JAVA_HOME" ] && 288 | JAVA_HOME=$(cygpath --path --windows "$JAVA_HOME") 289 | [ -n "$CLASSPATH" ] && 290 | CLASSPATH=$(cygpath --path --windows "$CLASSPATH") 291 | [ -n "$MAVEN_PROJECTBASEDIR" ] && 292 | MAVEN_PROJECTBASEDIR=$(cygpath --path --windows "$MAVEN_PROJECTBASEDIR") 293 | fi 294 | 295 | # Provide a "standardized" way to retrieve the CLI args that will 296 | # work with both Windows and non-Windows executions. 297 | MAVEN_CMD_LINE_ARGS="$MAVEN_CONFIG $*" 298 | export MAVEN_CMD_LINE_ARGS 299 | 300 | WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain 301 | 302 | # shellcheck disable=SC2086 # safe args 303 | exec "$JAVACMD" \ 304 | $MAVEN_OPTS \ 305 | $MAVEN_DEBUG_OPTS \ 306 | -classpath "$MAVEN_PROJECTBASEDIR/.mvn/wrapper/maven-wrapper.jar" \ 307 | "-Dmaven.multiModuleProjectDirectory=${MAVEN_PROJECTBASEDIR}" \ 308 | ${WRAPPER_LAUNCHER} $MAVEN_CONFIG "$@" 309 | -------------------------------------------------------------------------------- /cqrs/src/test/resources/db/migration/V997__Product_Data.sql: -------------------------------------------------------------------------------- 1 | insert into product (id, name, price) values (1, 'Sobe - Berry Energy', 24.96); 2 | insert into product (id, name, price) values (2, 'Bread - Raisin', 77.13); 3 | insert into product (id, name, price) values (3, 'Lettuce - Romaine, Heart', 87.49); 4 | insert into product (id, name, price) values (4, 'Salt - Seasoned', 61.85); 5 | insert into product (id, name, price) values (5, 'Foil - 4oz Custard Cup', 30.66); 6 | insert into product (id, name, price) values (6, 'Hummus - Spread', 4.15); 7 | insert into product (id, name, price) values (7, 'Salmon - Atlantic, Skin On', 84.18); 8 | insert into product (id, name, price) values (8, 'Gatorade - Orange', 27.59); 9 | insert into product (id, name, price) values (9, 'True - Vue Containers', 57.57); 10 | insert into product (id, name, price) values (10, 'Muffin - Mix - Mango Sour Cherry', 68.27); 11 | insert into product (id, name, price) values (11, 'Fond - Chocolate', 31.96); 12 | insert into product (id, name, price) values (12, 'Cheese - Brie, Triple Creme', 94.21); 13 | insert into product (id, name, price) values (13, 'Ecolab - Medallion', 51.9); 14 | insert into product (id, name, price) values (14, 'Muffin Mix - Corn Harvest', 42.27); 15 | insert into product (id, name, price) values (15, 'Muffin Mix - Lemon Cranberry', 27.73); 16 | insert into product (id, name, price) values (16, 'Seedlings - Clamshell', 92.9); 17 | insert into product (id, name, price) values (17, 'Cocoa Powder - Natural', 81.57); 18 | insert into product (id, name, price) values (18, 'Wiberg Super Cure', 54.74); 19 | insert into product (id, name, price) values (19, 'Bagel - Sesame Seed Presliced', 61.66); 20 | insert into product (id, name, price) values (20, 'Oil - Avocado', 49.85); 21 | insert into product (id, name, price) values (21, 'Milkettes - 2%', 97.12); 22 | insert into product (id, name, price) values (22, 'Muffin - Blueberry Individual', 90.57); 23 | insert into product (id, name, price) values (23, 'Skirt - 24 Foot', 83.99); 24 | insert into product (id, name, price) values (24, 'Rice Paper', 9.94); 25 | insert into product (id, name, price) values (25, 'Chinese Foods - Plain Fried Rice', 48.03); 26 | insert into product (id, name, price) values (26, 'Berry Brulee', 54.77); 27 | insert into product (id, name, price) values (27, 'Soda Water - Club Soda, 355 Ml', 32.36); 28 | insert into product (id, name, price) values (28, 'Peas - Frozen', 22.25); 29 | insert into product (id, name, price) values (29, 'Cauliflower', 36.29); 30 | insert into product (id, name, price) values (30, 'Aspic - Clear', 36.3); 31 | insert into product (id, name, price) values (31, 'Pepper - Cubanelle', 20.87); 32 | insert into product (id, name, price) values (32, 'Isomalt', 94.46); 33 | insert into product (id, name, price) values (33, 'Pork - Bacon, Sliced', 2.95); 34 | insert into product (id, name, price) values (34, 'Coconut - Whole', 23.89); 35 | insert into product (id, name, price) values (35, 'Flavouring - Rum', 15.14); 36 | insert into product (id, name, price) values (36, 'Arctic Char - Fillets', 14.09); 37 | insert into product (id, name, price) values (37, 'Wine - White, Lindemans Bin 95', 97.17); 38 | insert into product (id, name, price) values (38, 'Liquid Aminios Acid - Braggs', 3.61); 39 | insert into product (id, name, price) values (39, 'Yogurt - Strawberry, 175 Gr', 16.06); 40 | insert into product (id, name, price) values (40, 'Yogurt - Strawberry, 175 Gr', 73.94); 41 | insert into product (id, name, price) values (41, 'Mushroom - Morel Frozen', 90.85); 42 | insert into product (id, name, price) values (42, 'Tilapia - Fillets', 86.84); 43 | insert into product (id, name, price) values (43, 'Bread Sour Rolls', 27.37); 44 | insert into product (id, name, price) values (44, 'Ecolab Silver Fusion', 33.33); 45 | insert into product (id, name, price) values (45, 'Pears - Bosc', 43.53); 46 | insert into product (id, name, price) values (46, 'Pie Shells 10', 39.16); 47 | insert into product (id, name, price) values (47, 'Cookies - Oreo, 4 Pack', 42.21); 48 | insert into product (id, name, price) values (48, 'Crab Brie In Phyllo', 58.81); 49 | insert into product (id, name, price) values (49, 'Puree - Guava', 81.74); 50 | insert into product (id, name, price) values (50, 'Cabbage Roll', 59.62); 51 | insert into product (id, name, price) values (51, 'Goulash Seasoning', 62.7); 52 | insert into product (id, name, price) values (52, 'Chocolate Bar - Reese Pieces', 31.18); 53 | insert into product (id, name, price) values (53, 'Garlic - Peeled', 66.13); 54 | insert into product (id, name, price) values (54, 'Onions - Cooking', 92.32); 55 | insert into product (id, name, price) values (55, 'Flavouring Vanilla Artificial', 4.31); 56 | insert into product (id, name, price) values (56, 'Cabbage Roll', 56.91); 57 | insert into product (id, name, price) values (57, 'Pepper - Cayenne', 94.32); 58 | insert into product (id, name, price) values (58, 'Table Cloth 62x120 White', 89.68); 59 | insert into product (id, name, price) values (59, 'Oil - Shortening,liqud, Fry', 3.84); 60 | insert into product (id, name, price) values (60, 'Oil - Pumpkinseed', 71.64); 61 | insert into product (id, name, price) values (61, 'Pastrami', 55.02); 62 | insert into product (id, name, price) values (62, 'Radish - Black, Winter, Organic', 60.43); 63 | insert into product (id, name, price) values (63, 'Beer - Upper Canada Light', 27.21); 64 | insert into product (id, name, price) values (64, 'Soup Campbells - Tomato Bisque', 75.47); 65 | insert into product (id, name, price) values (65, 'Cookie Dough - Peanut Butter', 80.54); 66 | insert into product (id, name, price) values (66, 'Shichimi Togarashi Peppeers', 18.74); 67 | insert into product (id, name, price) values (67, 'Sauce - Caesar Dressing', 23.36); 68 | insert into product (id, name, price) values (68, 'Nantucket - Orange Mango Cktl', 75.86); 69 | insert into product (id, name, price) values (69, 'Cup - Translucent 7 Oz Clear', 87.67); 70 | insert into product (id, name, price) values (70, 'Squash - Sunburst', 30.72); 71 | insert into product (id, name, price) values (71, 'Mountain Dew', 87.96); 72 | insert into product (id, name, price) values (72, 'Bar Mix - Pina Colada, 355 Ml', 52.14); 73 | insert into product (id, name, price) values (73, 'Squash - Sunburst', 2.53); 74 | insert into product (id, name, price) values (74, 'Cheese - Woolwich Goat, Log', 89.44); 75 | insert into product (id, name, price) values (75, 'Pork - Ham Hocks - Smoked', 68.3); 76 | insert into product (id, name, price) values (76, 'Squid Ink', 30.25); 77 | insert into product (id, name, price) values (77, 'Sprouts - Onion', 14.35); 78 | insert into product (id, name, price) values (78, 'Carrots - Purple, Organic', 34.77); 79 | insert into product (id, name, price) values (79, 'Island Oasis - Strawberry', 86.54); 80 | insert into product (id, name, price) values (80, 'Shallots', 54.55); 81 | insert into product (id, name, price) values (81, 'Mix Pina Colada', 90.2); 82 | insert into product (id, name, price) values (82, 'Pie Filling - Pumpkin', 83.42); 83 | insert into product (id, name, price) values (83, 'Milk - Chocolate 250 Ml', 18.83); 84 | insert into product (id, name, price) values (84, 'Beef - Tenderlion, Center Cut', 10.74); 85 | insert into product (id, name, price) values (85, 'Longos - Grilled Salmon With Bbq', 39.61); 86 | insert into product (id, name, price) values (86, 'Beef - Diced', 52.37); 87 | insert into product (id, name, price) values (87, 'Piping Jelly - All Colours', 70.33); 88 | insert into product (id, name, price) values (88, 'Pastry - Key Limepoppy Seed Tea', 52.87); 89 | insert into product (id, name, price) values (89, 'Watercress', 64.43); 90 | insert into product (id, name, price) values (90, 'Soup Knorr Chili With Beans', 60.75); 91 | insert into product (id, name, price) values (91, 'Heavy Duty Dust Pan', 45.98); 92 | insert into product (id, name, price) values (92, 'Snapple Lemon Tea', 40.17); 93 | insert into product (id, name, price) values (93, 'Pepper - Julienne, Frozen', 97.17); 94 | insert into product (id, name, price) values (94, 'Jameson Irish Whiskey', 39.42); 95 | insert into product (id, name, price) values (95, 'Dome Lid Clear P92008h', 24.07); 96 | insert into product (id, name, price) values (96, 'Soup - Knorr, Ministrone', 43.45); 97 | insert into product (id, name, price) values (97, 'Tomato - Plum With Basil', 70.32); 98 | insert into product (id, name, price) values (98, 'Mousse - Banana Chocolate', 67.41); 99 | insert into product (id, name, price) values (99, 'Pasta - Lasagne, Fresh', 17.94); 100 | insert into product (id, name, price) values (100, 'Snapple Lemon Tea', 28.72); 101 | insert into product (id, name, price) values (101, 'Sauce - Gravy, Au Jus, Mix', 3.01); 102 | insert into product (id, name, price) values (102, 'Pastry - Chocolate Chip Muffin', 50.16); 103 | insert into product (id, name, price) values (103, 'Napkin White', 45.07); 104 | insert into product (id, name, price) values (104, 'Tendrils - Baby Pea, Organic', 8.36); 105 | insert into product (id, name, price) values (105, 'Pepper - Red Chili', 24.61); 106 | insert into product (id, name, price) values (106, 'Skirt - 24 Foot', 36.11); 107 | insert into product (id, name, price) values (107, 'Truffle Cups - White Paper', 96.96); 108 | insert into product (id, name, price) values (108, 'Flour - Whole Wheat', 98.81); 109 | insert into product (id, name, price) values (109, 'Pickle - Dill', 63.0); 110 | insert into product (id, name, price) values (110, 'Lettuce - Escarole', 81.92); 111 | insert into product (id, name, price) values (111, 'Cheese - Bakers Cream Cheese', 91.93); 112 | insert into product (id, name, price) values (112, 'Longos - Grilled Veg Sandwiches', 31.23); 113 | insert into product (id, name, price) values (113, 'Stock - Chicken, White', 68.8); 114 | insert into product (id, name, price) values (114, 'Nestea - Iced Tea', 36.01); 115 | insert into product (id, name, price) values (115, 'Cake Sheet Combo Party Pack', 77.1); 116 | insert into product (id, name, price) values (116, 'Milk - Homo', 90.75); 117 | insert into product (id, name, price) values (117, 'Instant Coffee', 63.52); 118 | insert into product (id, name, price) values (118, 'Piping - Bags Quizna', 35.73); 119 | insert into product (id, name, price) values (119, 'Cheese Cheddar Processed', 58.24); 120 | insert into product (id, name, price) values (120, 'Chilli Paste, Hot Sambal Oelek', 41.3); 121 | insert into product (id, name, price) values (121, 'Bar Nature Valley', 9.16); 122 | insert into product (id, name, price) values (122, 'Shrimp, Dried, Small / Lb', 66.08); 123 | insert into product (id, name, price) values (123, 'Soup Campbells - Italian Wedding', 43.47); 124 | insert into product (id, name, price) values (124, 'Sauce - Fish 25 Ozf Bottle', 49.75); 125 | insert into product (id, name, price) values (125, 'Melon - Honey Dew', 70.48); 126 | insert into product (id, name, price) values (126, 'Seedlings - Mix, Organic', 19.25); 127 | insert into product (id, name, price) values (127, 'Lobster - Tail, 3 - 4 Oz', 82.21); 128 | insert into product (id, name, price) values (128, 'Muffin - Mix - Creme Brule 15l', 1.21); 129 | insert into product (id, name, price) values (129, 'Cardamon Seed / Pod', 8.15); 130 | insert into product (id, name, price) values (130, 'Wine - Cousino Macul Antiguas', 1.23); 131 | insert into product (id, name, price) values (131, 'Tea - Camomele', 14.44); 132 | insert into product (id, name, price) values (132, 'Schnappes - Peach, Walkers', 88.77); 133 | insert into product (id, name, price) values (133, 'Kiwi', 98.28); 134 | insert into product (id, name, price) values (134, 'Sugar - Brown, Individual', 46.23); 135 | insert into product (id, name, price) values (135, 'Tea - Herbal Orange Spice', 43.54); 136 | insert into product (id, name, price) values (136, 'Appetizer - Smoked Salmon / Dill', 63.75); 137 | insert into product (id, name, price) values (137, 'Beans - Butter Lrg Lima', 46.0); 138 | insert into product (id, name, price) values (138, 'Wine - Magnotta, Merlot Sr Vqa', 95.77); 139 | insert into product (id, name, price) values (139, 'Lotus Leaves', 54.44); 140 | insert into product (id, name, price) values (140, 'Wine - Chianti Classica Docg', 24.34); 141 | insert into product (id, name, price) values (141, 'Wine - Guy Sage Touraine', 42.03); 142 | insert into product (id, name, price) values (142, 'Venison - Racks Frenched', 34.4); 143 | insert into product (id, name, price) values (143, 'French Kiss Vanilla', 58.56); 144 | insert into product (id, name, price) values (144, 'Soup - Campbells', 34.72); 145 | insert into product (id, name, price) values (145, 'Iced Tea - Lemon, 460 Ml', 28.1); 146 | insert into product (id, name, price) values (146, 'Beer - Fruli', 28.7); 147 | insert into product (id, name, price) values (147, 'Duck - Legs', 33.92); 148 | insert into product (id, name, price) values (148, 'Crush - Grape, 355 Ml', 39.31); 149 | insert into product (id, name, price) values (149, 'Yucca', 65.81); 150 | insert into product (id, name, price) values (150, 'Cheese - Roquefort Pappillon', 47.0); 151 | insert into product (id, name, price) values (151, 'Lid Coffeecup 12oz D9542b', 20.68); 152 | insert into product (id, name, price) values (152, 'Bread - Raisin', 7.3); 153 | insert into product (id, name, price) values (153, 'Juice - Apple, 1.36l', 34.18); 154 | insert into product (id, name, price) values (154, 'Ice Cream - Fudge Bars', 87.55); 155 | insert into product (id, name, price) values (155, 'Beans - Green', 40.9); 156 | insert into product (id, name, price) values (156, 'Bacardi Breezer - Strawberry', 46.22); 157 | insert into product (id, name, price) values (157, 'Marjoram - Dried, Rubbed', 20.35); 158 | insert into product (id, name, price) values (158, 'Bread Base - Goodhearth', 62.42); 159 | insert into product (id, name, price) values (159, 'Wine - Rosso Del Veronese Igt', 19.85); 160 | insert into product (id, name, price) values (160, 'Sauce - Salsa', 33.11); 161 | insert into product (id, name, price) values (161, 'Boogies', 40.19); 162 | insert into product (id, name, price) values (162, 'Jolt Cola - Electric Blue', 70.8); 163 | insert into product (id, name, price) values (163, 'Pasta - Spaghetti, Dry', 98.3); 164 | insert into product (id, name, price) values (164, 'Grapefruit - White', 22.67); 165 | insert into product (id, name, price) values (165, 'Rum - Cream, Amarula', 53.93); 166 | insert into product (id, name, price) values (166, 'Soup - Campbells, Chix Gumbo', 15.26); 167 | insert into product (id, name, price) values (167, 'Salmon Atl.whole 8 - 10 Lb', 55.36); 168 | insert into product (id, name, price) values (168, 'Cheese - Cheddar, Medium', 58.17); 169 | insert into product (id, name, price) values (169, 'Beef Flat Iron Steak', 61.68); 170 | insert into product (id, name, price) values (170, 'Carbonated Water - Strawberry', 60.12); 171 | insert into product (id, name, price) values (171, 'Poppy Seed', 74.47); 172 | insert into product (id, name, price) values (172, 'Chips - Doritos', 69.46); 173 | insert into product (id, name, price) values (173, 'Lamb - Racks, Frenched', 83.93); 174 | insert into product (id, name, price) values (174, 'Sprouts - China Rose', 33.65); 175 | insert into product (id, name, price) values (175, 'Wine - Rubyport', 38.43); 176 | insert into product (id, name, price) values (176, 'Sole - Iqf', 28.71); 177 | insert into product (id, name, price) values (177, 'Okra', 86.29); 178 | insert into product (id, name, price) values (178, 'Tea - Camomele', 48.51); 179 | insert into product (id, name, price) values (179, 'Salmon - Smoked, Sliced', 5.95); 180 | insert into product (id, name, price) values (180, 'Honey - Liquid', 50.21); 181 | insert into product (id, name, price) values (181, 'Bag - Clear 7 Lb', 75.74); 182 | insert into product (id, name, price) values (182, 'Chicken - Whole Fryers', 86.51); 183 | insert into product (id, name, price) values (183, 'Trout - Smoked', 43.41); 184 | insert into product (id, name, price) values (184, 'Puree - Raspberry', 55.34); 185 | insert into product (id, name, price) values (185, 'Fenngreek Seed', 83.62); 186 | insert into product (id, name, price) values (186, 'V8 Splash Strawberry Kiwi', 39.31); 187 | insert into product (id, name, price) values (187, 'Onions - Red Pearl', 42.8); 188 | insert into product (id, name, price) values (188, 'Cheese - Havarti, Roasted Garlic', 91.97); 189 | insert into product (id, name, price) values (189, 'Glass Clear 8 Oz', 73.15); 190 | insert into product (id, name, price) values (190, 'Otomegusa Dashi Konbu', 19.92); 191 | insert into product (id, name, price) values (191, 'Cheese - Cheddar With Claret', 82.34); 192 | insert into product (id, name, price) values (192, 'Ice Cream Bar - Hageen Daz To', 27.17); 193 | insert into product (id, name, price) values (193, 'Wine - Red, Antinori Santa', 44.06); 194 | insert into product (id, name, price) values (194, 'Veal - Leg', 91.21); 195 | insert into product (id, name, price) values (195, 'Veal - Striploin', 4.69); 196 | insert into product (id, name, price) values (196, 'Muffin - Mix - Mango Sour Cherry', 23.62); 197 | insert into product (id, name, price) values (197, 'Chocolate Liqueur - Godet White', 38.42); 198 | insert into product (id, name, price) values (198, 'Turkey - Breast, Bone - In', 82.4); 199 | insert into product (id, name, price) values (199, 'Soup - Campbells, Butternut', 67.17); 200 | insert into product (id, name, price) values (200, 'Nutmeg - Ground', 88.86); 201 | insert into product (id, name, price) values (201, 'Wine - Chianti Classica Docg', 55.58); 202 | insert into product (id, name, price) values (202, 'Wine - Stoneliegh Sauvignon', 74.11); 203 | insert into product (id, name, price) values (203, 'Trout Rainbow Whole', 37.44); 204 | insert into product (id, name, price) values (204, 'Bread - Raisin', 25.56); 205 | insert into product (id, name, price) values (205, 'Pie Shell - 9', 98.57); 206 | insert into product (id, name, price) values (206, 'Beef - Roasted, Cooked', 12.23); 207 | insert into product (id, name, price) values (207, 'Lettuce - Arugula', 50.05); 208 | insert into product (id, name, price) values (208, 'Plate Pie Foil', 69.02); 209 | insert into product (id, name, price) values (209, 'Turkey - Whole, Fresh', 88.36); 210 | insert into product (id, name, price) values (210, 'Juice - Tomato, 48 Oz', 73.93); 211 | insert into product (id, name, price) values (211, 'Soup - Canadian Pea, Dry Mix', 61.35); 212 | insert into product (id, name, price) values (212, 'Squash - Guords', 17.75); 213 | insert into product (id, name, price) values (213, 'Beans - Fava Fresh', 33.27); 214 | insert into product (id, name, price) values (214, 'Apples - Sliced / Wedge', 52.01); 215 | insert into product (id, name, price) values (215, 'Napkin - Dinner, White', 30.15); 216 | insert into product (id, name, price) values (216, 'Mushrooms - Honey', 40.64); 217 | insert into product (id, name, price) values (217, 'Rosemary - Dry', 15.2); 218 | insert into product (id, name, price) values (218, 'Calypso - Pineapple Passion', 52.95); 219 | insert into product (id, name, price) values (219, 'Dip - Tapenade', 93.83); 220 | insert into product (id, name, price) values (220, 'Container - Clear 32 Oz', 67.05); 221 | insert into product (id, name, price) values (221, 'Glucose', 54.22); 222 | insert into product (id, name, price) values (222, 'Cherries - Maraschino,jar', 43.18); 223 | insert into product (id, name, price) values (223, 'Swiss Chard - Red', 27.42); 224 | insert into product (id, name, price) values (224, 'Chilli Paste, Hot Sambal Oelek', 90.29); 225 | insert into product (id, name, price) values (225, 'Lamb - Whole Head Off', 73.7); 226 | insert into product (id, name, price) values (226, 'Radish - Pickled', 17.02); 227 | insert into product (id, name, price) values (227, 'Wine - Mas Chicet Rose, Vintage', 44.93); 228 | insert into product (id, name, price) values (228, 'Shrimp - Prawn', 95.59); 229 | insert into product (id, name, price) values (229, 'Lettuce - Curly Endive', 29.26); 230 | insert into product (id, name, price) values (230, 'Tomato - Green', 41.61); 231 | insert into product (id, name, price) values (231, 'Cod - Fillets', 68.93); 232 | insert into product (id, name, price) values (232, 'Cleaner - Bleach', 39.44); 233 | insert into product (id, name, price) values (233, 'Turnip - Mini', 62.25); 234 | insert into product (id, name, price) values (234, 'Rum - Dark, Bacardi, Black', 51.78); 235 | insert into product (id, name, price) values (235, 'Pork - Tenderloin, Frozen', 66.44); 236 | insert into product (id, name, price) values (236, 'Cheese - Ermite Bleu', 95.44); 237 | insert into product (id, name, price) values (237, 'Salt - Seasoned', 62.52); 238 | insert into product (id, name, price) values (238, 'Nestea - Iced Tea', 23.62); 239 | insert into product (id, name, price) values (239, 'Quiche Assorted', 24.61); 240 | insert into product (id, name, price) values (240, 'Truffle Cups - Brown', 21.15); 241 | insert into product (id, name, price) values (241, 'Sour Puss - Tangerine', 98.27); 242 | insert into product (id, name, price) values (242, 'Cocoa Butter', 75.12); 243 | insert into product (id, name, price) values (243, 'Cheese - Parmesan Grated', 61.6); 244 | insert into product (id, name, price) values (244, 'Wine - Placido Pinot Grigo', 5.15); 245 | insert into product (id, name, price) values (245, 'Lobster - Baby, Boiled', 48.66); 246 | insert into product (id, name, price) values (246, 'Cherries - Bing, Canned', 15.24); 247 | insert into product (id, name, price) values (247, 'Sultanas', 85.28); 248 | insert into product (id, name, price) values (248, 'Wonton Wrappers', 14.33); 249 | insert into product (id, name, price) values (249, 'Pork - Bacon Cooked Slcd', 77.95); 250 | insert into product (id, name, price) values (250, 'Coconut - Whole', 3.14); 251 | insert into product (id, name, price) values (251, 'Fond - Chocolate', 6.14); 252 | insert into product (id, name, price) values (252, 'Tomato Paste', 34.74); 253 | insert into product (id, name, price) values (253, 'Beef - Tongue, Cooked', 38.24); 254 | insert into product (id, name, price) values (254, 'Cattail Hearts', 73.38); 255 | insert into product (id, name, price) values (255, 'Milk - Chocolate 500ml', 22.71); 256 | insert into product (id, name, price) values (256, 'Banana - Leaves', 98.28); 257 | insert into product (id, name, price) values (257, 'Beer - Fruli', 17.23); 258 | insert into product (id, name, price) values (258, 'V8 - Tropical Blend', 82.67); 259 | insert into product (id, name, price) values (259, 'Tea - Orange Pekoe', 80.97); 260 | insert into product (id, name, price) values (260, 'Hot Choc Vending', 21.6); 261 | insert into product (id, name, price) values (261, 'Pastry - Baked Scones - Mini', 87.83); 262 | insert into product (id, name, price) values (262, 'Veal Inside - Provimi', 22.77); 263 | insert into product (id, name, price) values (263, 'Chicken - Thigh, Bone In', 94.67); 264 | insert into product (id, name, price) values (264, 'Pie Box - Cello Window 2.5', 91.47); 265 | insert into product (id, name, price) values (265, 'Chips Potato All Dressed - 43g', 7.24); 266 | insert into product (id, name, price) values (266, 'Oil - Coconut', 21.1); 267 | insert into product (id, name, price) values (267, 'Rabbit - Legs', 91.96); 268 | insert into product (id, name, price) values (268, 'Compound - Passion Fruit', 21.9); 269 | insert into product (id, name, price) values (269, 'Cocoa Powder - Dutched', 50.1); 270 | insert into product (id, name, price) values (270, 'Wine - Saint - Bris 2002, Sauv', 63.69); 271 | insert into product (id, name, price) values (271, 'Pasta - Fettuccine, Egg, Fresh', 25.5); 272 | insert into product (id, name, price) values (272, 'Ecolab - Hand Soap Form Antibac', 46.52); 273 | insert into product (id, name, price) values (273, 'Beer - Camerons Cream Ale', 38.63); 274 | insert into product (id, name, price) values (274, 'Pesto - Primerba, Paste', 5.61); 275 | insert into product (id, name, price) values (275, 'Coffee - Ristretto Coffee Capsule', 96.95); 276 | insert into product (id, name, price) values (276, 'Radish', 24.24); 277 | insert into product (id, name, price) values (277, 'Chocolate - Unsweetened', 94.99); 278 | insert into product (id, name, price) values (278, 'Bread - Triangle White', 22.78); 279 | insert into product (id, name, price) values (279, 'Sausage - Liver', 33.99); 280 | insert into product (id, name, price) values (280, 'Appetizer - Smoked Salmon / Dill', 77.72); 281 | insert into product (id, name, price) values (281, 'Tart Shells - Savory, 4', 4.84); 282 | insert into product (id, name, price) values (282, 'Ginger - Crystalized', 18.62); 283 | insert into product (id, name, price) values (283, 'Sauce Bbq Smokey', 56.95); 284 | insert into product (id, name, price) values (284, 'Hand Towel', 25.66); 285 | insert into product (id, name, price) values (285, 'Sauce - Roasted Red Pepper', 10.02); 286 | insert into product (id, name, price) values (286, 'Fish - Halibut, Cold Smoked', 8.4); 287 | insert into product (id, name, price) values (287, 'Tomatoes Tear Drop Yellow', 41.16); 288 | insert into product (id, name, price) values (288, 'Food Colouring - Orange', 17.08); 289 | insert into product (id, name, price) values (289, 'Cognac - Courvaisier', 81.06); 290 | insert into product (id, name, price) values (290, 'Samosa - Veg', 40.01); 291 | insert into product (id, name, price) values (291, 'Dome Lid Clear P92008h', 19.88); 292 | insert into product (id, name, price) values (292, 'Salt - Celery', 39.79); 293 | insert into product (id, name, price) values (293, 'Onions - Red Pearl', 33.28); 294 | insert into product (id, name, price) values (294, 'Plate Foam Laminated 9in Blk', 96.73); 295 | insert into product (id, name, price) values (295, 'Butter - Salted, Micro', 66.68); 296 | insert into product (id, name, price) values (296, 'Long Island Ice Tea', 55.24); 297 | insert into product (id, name, price) values (297, 'French Kiss Vanilla', 57.89); 298 | insert into product (id, name, price) values (298, 'Cheese - Boursin, Garlic / Herbs', 80.47); 299 | insert into product (id, name, price) values (299, 'Bread - Corn Muffaletta', 88.88); 300 | insert into product (id, name, price) values (300, 'Munchies Honey Sweet Trail Mix', 74.45); 301 | insert into product (id, name, price) values (301, 'Squid Ink', 1.66); 302 | insert into product (id, name, price) values (302, 'Snapple - Mango Maddness', 59.54); 303 | insert into product (id, name, price) values (303, 'Pasta - Fusili, Dry', 86.79); 304 | insert into product (id, name, price) values (304, 'Arctic Char - Fillets', 10.05); 305 | insert into product (id, name, price) values (305, 'Water - Spring 1.5lit', 31.63); 306 | insert into product (id, name, price) values (306, 'French Kiss Vanilla', 94.51); 307 | insert into product (id, name, price) values (307, 'Eggplant Oriental', 13.74); 308 | insert into product (id, name, price) values (308, 'Tuna - Bluefin', 47.48); 309 | insert into product (id, name, price) values (309, 'Tart Shells - Sweet, 2', 82.27); 310 | insert into product (id, name, price) values (310, 'Beef - Baby, Liver', 15.33); 311 | insert into product (id, name, price) values (311, 'Garbage Bags - Clear', 49.6); 312 | insert into product (id, name, price) values (312, 'Carbonated Water - Peach', 76.2); 313 | insert into product (id, name, price) values (313, 'Pepper - Chillies, Crushed', 82.7); 314 | insert into product (id, name, price) values (314, 'Bread - Italian Sesame Poly', 23.21); 315 | insert into product (id, name, price) values (315, 'Allspice - Jamaican', 35.7); 316 | insert into product (id, name, price) values (316, 'Bread - Rosemary Focaccia', 78.29); 317 | insert into product (id, name, price) values (317, 'Wanton Wrap', 33.62); 318 | insert into product (id, name, price) values (318, 'Flour - Chickpea', 50.89); 319 | insert into product (id, name, price) values (319, 'Oil - Coconut', 87.94); 320 | insert into product (id, name, price) values (320, 'Sauce - Ranch Dressing', 21.88); 321 | insert into product (id, name, price) values (321, 'Flour - Masa De Harina Mexican', 1.35); 322 | insert into product (id, name, price) values (322, 'Red Cod Fillets - 225g', 2.89); 323 | insert into product (id, name, price) values (323, 'Vacuum Bags 12x16', 28.58); 324 | insert into product (id, name, price) values (324, 'Capicola - Hot', 30.63); 325 | insert into product (id, name, price) values (325, 'Remy Red', 39.54); 326 | insert into product (id, name, price) values (326, 'Wine - Riesling Alsace Ac 2001', 60.57); 327 | insert into product (id, name, price) values (327, 'Salmon Steak - Cohoe 6 Oz', 74.42); 328 | insert into product (id, name, price) values (328, 'Cornish Hen', 64.19); 329 | insert into product (id, name, price) values (329, 'Raisin - Golden', 77.22); 330 | insert into product (id, name, price) values (330, 'Schnappes Peppermint - Walker', 3.02); 331 | insert into product (id, name, price) values (331, 'Pastry - Mini French Pastries', 44.13); 332 | insert into product (id, name, price) values (332, 'Cape Capensis - Fillet', 79.53); 333 | insert into product (id, name, price) values (333, 'Wine - Chenin Blanc K.w.v.', 25.23); 334 | insert into product (id, name, price) values (334, 'Ice Cream - Life Savers', 92.8); 335 | insert into product (id, name, price) values (335, 'Juice - Propel Sport', 18.41); 336 | insert into product (id, name, price) values (336, 'English Muffin', 86.82); 337 | insert into product (id, name, price) values (337, 'Lemon Grass', 75.19); 338 | insert into product (id, name, price) values (338, 'Coffee - Hazelnut Cream', 51.1); 339 | insert into product (id, name, price) values (339, 'Pastry - Trippleberry Muffin - Mini', 59.13); 340 | insert into product (id, name, price) values (340, 'Rambutan', 54.4); 341 | insert into product (id, name, price) values (341, 'Wine - Zonnebloem Pinotage', 76.89); 342 | insert into product (id, name, price) values (342, 'Soup - Campbells Chili', 20.06); 343 | insert into product (id, name, price) values (343, 'Gooseberry', 70.13); 344 | insert into product (id, name, price) values (344, 'Rum - White, Gg White', 77.61); 345 | insert into product (id, name, price) values (345, 'Veal - Nuckle', 56.17); 346 | insert into product (id, name, price) values (346, 'Glass - Juice Clear 5oz 55005', 25.56); 347 | insert into product (id, name, price) values (347, 'Sole - Fillet', 73.07); 348 | insert into product (id, name, price) values (348, 'Chips - Potato Jalapeno', 2.33); 349 | insert into product (id, name, price) values (349, 'Pasta - Gnocchi, Potato', 4.81); 350 | insert into product (id, name, price) values (350, 'Dill - Primerba, Paste', 71.45); 351 | insert into product (id, name, price) values (351, 'Wine - Harrow Estates, Vidal', 81.82); 352 | insert into product (id, name, price) values (352, 'Cumin - Ground', 40.48); 353 | insert into product (id, name, price) values (353, 'Ecolab - Solid Fusion', 62.16); 354 | insert into product (id, name, price) values (354, 'Tortillas - Flour, 8', 50.54); 355 | insert into product (id, name, price) values (355, 'Beef - Rouladin, Sliced', 76.56); 356 | insert into product (id, name, price) values (356, 'Venison - Striploin', 24.35); 357 | insert into product (id, name, price) values (357, 'Cranberries - Dry', 55.61); 358 | insert into product (id, name, price) values (358, 'Kiwi', 47.29); 359 | insert into product (id, name, price) values (359, 'Doilies - 7, Paper', 43.57); 360 | insert into product (id, name, price) values (360, 'Ecolab - Solid Fusion', 71.6); 361 | insert into product (id, name, price) values (361, 'Ezy Change Mophandle', 46.87); 362 | insert into product (id, name, price) values (362, 'Yoplait - Strawbrasp Peac', 40.78); 363 | insert into product (id, name, price) values (363, 'Nantucket - Kiwi Berry Cktl.', 72.89); 364 | insert into product (id, name, price) values (364, 'Cheese - Fontina', 82.92); 365 | insert into product (id, name, price) values (365, 'Laundry - Bag Cloth', 1.45); 366 | insert into product (id, name, price) values (366, 'Bread - Kimel Stick Poly', 63.41); 367 | insert into product (id, name, price) values (367, 'Waffle Stix', 56.54); 368 | insert into product (id, name, price) values (368, 'Urban Zen Drinks', 37.38); 369 | insert into product (id, name, price) values (369, 'Buffalo - Striploin', 68.63); 370 | insert into product (id, name, price) values (370, 'Spice - Greek 1 Step', 81.25); 371 | insert into product (id, name, price) values (371, 'Cleaner - Bleach', 29.52); 372 | insert into product (id, name, price) values (372, 'Wine - Pinot Noir Mondavi Coastal', 39.07); 373 | insert into product (id, name, price) values (373, 'Fish - Scallops, Cold Smoked', 57.18); 374 | insert into product (id, name, price) values (374, 'Flower - Leather Leaf Fern', 19.62); 375 | insert into product (id, name, price) values (375, 'Beer - Corona', 67.9); 376 | insert into product (id, name, price) values (376, 'Sauce - Soy Low Sodium - 3.87l', 61.92); 377 | insert into product (id, name, price) values (377, 'Gherkin - Sour', 25.62); 378 | insert into product (id, name, price) values (378, 'Muffin - Zero Transfat', 3.63); 379 | insert into product (id, name, price) values (379, 'Cakes Assorted', 28.79); 380 | insert into product (id, name, price) values (380, 'Lobster - Tail 6 Oz', 44.12); 381 | insert into product (id, name, price) values (381, 'Beer - Camerons Auburn', 1.68); 382 | insert into product (id, name, price) values (382, 'Garlic - Peeled', 58.86); 383 | insert into product (id, name, price) values (383, 'Jameson - Irish Whiskey', 97.57); 384 | insert into product (id, name, price) values (384, 'Mix - Cocktail Ice Cream', 20.41); 385 | insert into product (id, name, price) values (385, 'Wine - Red, Metus Rose', 85.48); 386 | insert into product (id, name, price) values (386, 'Wine - Rosso Del Veronese Igt', 93.45); 387 | insert into product (id, name, price) values (387, 'Oxtail - Cut', 99.12); 388 | insert into product (id, name, price) values (388, 'Table Cloth 62x120 Colour', 13.76); 389 | insert into product (id, name, price) values (389, 'Parsnip', 94.15); 390 | insert into product (id, name, price) values (390, 'Wine - Prem Select Charddonany', 80.43); 391 | insert into product (id, name, price) values (391, 'Wine - Alicanca Vinho Verde', 7.57); 392 | insert into product (id, name, price) values (392, 'Sloe Gin - Mcguinness', 75.94); 393 | insert into product (id, name, price) values (393, 'Star Anise, Whole', 88.75); 394 | insert into product (id, name, price) values (394, 'Lamb - Loin, Trimmed, Boneless', 33.68); 395 | insert into product (id, name, price) values (395, 'Red Cod Fillets - 225g', 77.08); 396 | insert into product (id, name, price) values (396, 'Coffee - Dark Roast', 97.01); 397 | insert into product (id, name, price) values (397, 'Silicone Paper 16.5x24', 22.74); 398 | insert into product (id, name, price) values (398, 'Pasta - Penne Primavera, Single', 89.57); 399 | insert into product (id, name, price) values (399, 'Chilli Paste, Hot Sambal Oelek', 35.0); 400 | insert into product (id, name, price) values (400, 'Foam Cup 6 Oz', 44.52); 401 | insert into product (id, name, price) values (401, 'Bread - Kimel Stick Poly', 34.58); 402 | insert into product (id, name, price) values (402, 'Table Cloth 81x81 White', 60.63); 403 | insert into product (id, name, price) values (403, 'Rice Pilaf, Dry,package', 52.48); 404 | insert into product (id, name, price) values (404, 'Cauliflower', 51.9); 405 | insert into product (id, name, price) values (405, 'Daikon Radish', 18.59); 406 | insert into product (id, name, price) values (406, 'Tea - Green', 62.55); 407 | insert into product (id, name, price) values (407, 'Chicken - Bones', 39.49); 408 | insert into product (id, name, price) values (408, 'Gatorade - Fruit Punch', 52.28); 409 | insert into product (id, name, price) values (409, 'Snails - Large Canned', 75.01); 410 | insert into product (id, name, price) values (410, 'Fish - Atlantic Salmon, Cold', 48.9); 411 | insert into product (id, name, price) values (411, 'Green Scrubbie Pad H.duty', 30.12); 412 | insert into product (id, name, price) values (412, 'Pop Shoppe Cream Soda', 11.99); 413 | insert into product (id, name, price) values (413, 'Clementine', 81.14); 414 | insert into product (id, name, price) values (414, 'Wine - Chenin Blanc K.w.v.', 3.57); 415 | insert into product (id, name, price) values (415, 'Sobe - Cranberry Grapefruit', 78.64); 416 | insert into product (id, name, price) values (416, 'Chinese Foods - Cantonese', 74.8); 417 | insert into product (id, name, price) values (417, 'Beef - Eye Of Round', 13.52); 418 | insert into product (id, name, price) values (418, 'Bowl 12 Oz - Showcase 92012', 29.95); 419 | insert into product (id, name, price) values (419, 'Pasta - Lasagna Noodle, Frozen', 49.58); 420 | insert into product (id, name, price) values (420, 'Chips - Doritos', 13.85); 421 | insert into product (id, name, price) values (421, 'Peppercorns - Green', 7.44); 422 | insert into product (id, name, price) values (422, 'Wine - Touraine Azay - Le - Rideau', 48.16); 423 | insert into product (id, name, price) values (423, 'Veal - Insides, Grains', 7.07); 424 | insert into product (id, name, price) values (424, 'Fish - Halibut, Cold Smoked', 23.85); 425 | insert into product (id, name, price) values (425, 'Olives - Stuffed', 95.54); 426 | insert into product (id, name, price) values (426, 'Nantucket Cranberry Juice', 35.77); 427 | insert into product (id, name, price) values (427, 'Arctic Char - Fresh, Whole', 14.05); 428 | insert into product (id, name, price) values (428, 'Beer - Fruli', 85.57); 429 | insert into product (id, name, price) values (429, 'Pie Shell - 9', 31.7); 430 | insert into product (id, name, price) values (430, 'Shrimp - Tiger 21/25', 99.96); 431 | insert into product (id, name, price) values (431, 'Samosa - Veg', 57.61); 432 | insert into product (id, name, price) values (432, 'Wine - Port Late Bottled Vintage', 62.33); 433 | insert into product (id, name, price) values (433, 'Nutmeg - Ground', 41.79); 434 | insert into product (id, name, price) values (434, 'Oil - Shortening,liqud, Fry', 8.62); 435 | insert into product (id, name, price) values (435, 'Ostrich - Fan Fillet', 71.2); 436 | insert into product (id, name, price) values (436, 'Bread - Mini Hamburger Bun', 20.08); 437 | insert into product (id, name, price) values (437, 'Oil - Macadamia', 78.85); 438 | insert into product (id, name, price) values (438, 'Plaintain', 36.62); 439 | insert into product (id, name, price) values (439, 'Remy Red Berry Infusion', 34.16); 440 | insert into product (id, name, price) values (440, 'Bread - Rolls, Rye', 48.43); 441 | insert into product (id, name, price) values (441, 'Tart Shells - Savory, 4', 69.5); 442 | insert into product (id, name, price) values (442, 'Croissants Thaw And Serve', 34.55); 443 | insert into product (id, name, price) values (443, 'Oil - Peanut', 85.32); 444 | insert into product (id, name, price) values (444, 'Garbage Bags - Clear', 73.83); 445 | insert into product (id, name, price) values (445, 'Beer - Mcauslan Apricot', 18.52); 446 | insert into product (id, name, price) values (446, 'Easy Off Oven Cleaner', 7.86); 447 | insert into product (id, name, price) values (447, 'Pastry - Cherry Danish - Mini', 41.2); 448 | insert into product (id, name, price) values (448, 'Pears - Fiorelle', 45.44); 449 | insert into product (id, name, price) values (449, 'Sauce Bbq Smokey', 76.71); 450 | insert into product (id, name, price) values (450, 'Lamb - Rack', 13.82); 451 | insert into product (id, name, price) values (451, 'Tea - Jasmin Green', 44.21); 452 | insert into product (id, name, price) values (452, 'Black Currants', 75.46); 453 | insert into product (id, name, price) values (453, 'Chick Peas - Canned', 29.41); 454 | insert into product (id, name, price) values (454, 'Fenngreek Seed', 90.57); 455 | insert into product (id, name, price) values (455, 'Foam Dinner Plate', 33.34); 456 | insert into product (id, name, price) values (456, 'Flower - Commercial Bronze', 57.19); 457 | insert into product (id, name, price) values (457, 'Cookie Dough - Double', 75.38); 458 | insert into product (id, name, price) values (458, 'Yogurt - Banana, 175 Gr', 48.0); 459 | insert into product (id, name, price) values (459, 'Pasta - Lasagne, Fresh', 35.23); 460 | insert into product (id, name, price) values (460, 'Ham Black Forest', 94.4); 461 | insert into product (id, name, price) values (461, 'Wine - Kwv Chenin Blanc South', 84.04); 462 | insert into product (id, name, price) values (462, 'Bread - Crusty Italian Poly', 86.78); 463 | insert into product (id, name, price) values (463, 'Bread - Bagels, Plain', 57.42); 464 | insert into product (id, name, price) values (464, 'Cups 10oz Trans', 91.51); 465 | insert into product (id, name, price) values (465, 'Fuji Apples', 5.64); 466 | insert into product (id, name, price) values (466, 'The Pop Shoppe Pinapple', 98.54); 467 | insert into product (id, name, price) values (467, 'Compound - Strawberry', 35.96); 468 | insert into product (id, name, price) values (468, 'Turkey - Breast, Bone - In', 55.9); 469 | insert into product (id, name, price) values (469, 'Creamers - 10%', 78.83); 470 | insert into product (id, name, price) values (470, 'Ice Cream - Super Sandwich', 23.05); 471 | insert into product (id, name, price) values (471, 'Tomatoes - Roma', 44.91); 472 | insert into product (id, name, price) values (472, 'Pastry - Apple Large', 94.25); 473 | insert into product (id, name, price) values (473, 'Dehydrated Kelp Kombo', 83.29); 474 | insert into product (id, name, price) values (474, 'Straw - Regular', 56.4); 475 | insert into product (id, name, price) values (475, 'Wine - Savigny - Les - Beaune', 66.52); 476 | insert into product (id, name, price) values (476, 'Turnip - Wax', 66.61); 477 | insert into product (id, name, price) values (477, 'Turkey - Breast, Boneless Sk On', 54.89); 478 | insert into product (id, name, price) values (478, 'Cheese - Pont Couvert', 6.57); 479 | insert into product (id, name, price) values (479, 'Walkers Special Old Whiskey', 65.27); 480 | insert into product (id, name, price) values (480, 'Crab Brie In Phyllo', 25.2); 481 | insert into product (id, name, price) values (481, 'Flour Dark Rye', 3.39); 482 | insert into product (id, name, price) values (482, 'Milk - Chocolate 250 Ml', 70.17); 483 | insert into product (id, name, price) values (483, 'Soup - Campbells Pasta Fagioli', 20.93); 484 | insert into product (id, name, price) values (484, 'Split Peas - Green, Dry', 99.35); 485 | insert into product (id, name, price) values (485, 'Vanilla Beans', 50.93); 486 | insert into product (id, name, price) values (486, 'Lettuce - Iceberg', 57.76); 487 | insert into product (id, name, price) values (487, 'Carbonated Water - Orange', 37.77); 488 | insert into product (id, name, price) values (488, 'Wine - Cabernet Sauvignon', 43.12); 489 | insert into product (id, name, price) values (489, 'Carbonated Water - White Grape', 89.81); 490 | insert into product (id, name, price) values (490, 'Passion Fruit', 30.38); 491 | insert into product (id, name, price) values (491, 'Filo Dough', 1.65); 492 | insert into product (id, name, price) values (492, 'Placemat - Scallop, White', 34.56); 493 | insert into product (id, name, price) values (493, 'Veal - Nuckle', 79.91); 494 | insert into product (id, name, price) values (494, 'Duck - Fat', 97.97); 495 | insert into product (id, name, price) values (495, 'Ham - Cooked', 31.1); 496 | insert into product (id, name, price) values (496, 'Vol Au Vents', 33.92); 497 | insert into product (id, name, price) values (497, 'Cup - 3.5oz, Foam', 38.53); 498 | insert into product (id, name, price) values (498, 'Radish', 42.51); 499 | insert into product (id, name, price) values (499, 'Oregano - Fresh', 42.84); 500 | insert into product (id, name, price) values (500, 'Cookie Dough - Oatmeal Rasin', 26.08); 501 | insert into product (id, name, price) values (501, 'Mayonnaise', 41.81); 502 | insert into product (id, name, price) values (502, 'Sherbet - Raspberry', 19.26); 503 | insert into product (id, name, price) values (503, 'Ecolab - Mikroklene 4/4 L', 90.3); 504 | insert into product (id, name, price) values (504, 'Lid Coffeecup 12oz D9542b', 73.51); 505 | insert into product (id, name, price) values (505, 'Stock - Veal, Brown', 25.81); 506 | insert into product (id, name, price) values (506, 'Tea - Camomele', 56.19); 507 | insert into product (id, name, price) values (507, 'Tomatoes - Vine Ripe, Red', 48.65); 508 | insert into product (id, name, price) values (508, 'Cup - 6oz, Foam', 62.35); 509 | insert into product (id, name, price) values (509, 'Vaccum Bag 10x13', 6.63); 510 | insert into product (id, name, price) values (510, 'Wine - Montecillo Rioja Crianza', 33.97); 511 | insert into product (id, name, price) values (511, 'Cheese - Grana Padano', 83.47); 512 | insert into product (id, name, price) values (512, 'Tray - 16in Rnd Blk', 91.49); 513 | insert into product (id, name, price) values (513, 'Napkin - Dinner, White', 3.06); 514 | insert into product (id, name, price) values (514, 'Ice Cream Bar - Hagen Daz', 36.44); 515 | insert into product (id, name, price) values (515, 'Radish - Pickled', 41.51); 516 | insert into product (id, name, price) values (516, 'Squash - Pattypan, Yellow', 15.15); 517 | insert into product (id, name, price) values (517, 'Star Anise, Whole', 33.38); 518 | insert into product (id, name, price) values (518, 'Soup - Campbells, Classic Chix', 48.33); 519 | insert into product (id, name, price) values (519, 'Wine - Gato Negro Cabernet', 16.79); 520 | insert into product (id, name, price) values (520, 'Pasta - Fettuccine, Dry', 4.56); 521 | insert into product (id, name, price) values (521, 'Tea - Orange Pekoe', 31.91); 522 | insert into product (id, name, price) values (522, 'Dooleys Toffee', 37.42); 523 | insert into product (id, name, price) values (523, 'Veal - Sweetbread', 69.12); 524 | insert into product (id, name, price) values (524, 'Initation Crab Meat', 40.75); 525 | insert into product (id, name, price) values (525, 'Veal - Striploin', 82.02); 526 | insert into product (id, name, price) values (526, 'Wine - Tribal Sauvignon', 13.74); 527 | insert into product (id, name, price) values (527, 'Pepper - White, Whole', 88.75); 528 | insert into product (id, name, price) values (528, 'Truffle Cups - Brown', 62.83); 529 | insert into product (id, name, price) values (529, 'Roe - White Fish', 68.02); 530 | insert into product (id, name, price) values (530, 'Apples - Sliced / Wedge', 33.04); 531 | insert into product (id, name, price) values (531, 'Tea - Herbal I Love Lemon', 2.18); 532 | insert into product (id, name, price) values (532, 'Ginger - Fresh', 52.88); 533 | insert into product (id, name, price) values (533, 'Wine - Sicilia Igt Nero Avola', 35.25); 534 | insert into product (id, name, price) values (534, 'Kirsch - Schloss', 61.3); 535 | insert into product (id, name, price) values (535, 'Pants Custom Dry Clean', 20.44); 536 | insert into product (id, name, price) values (536, 'Icecream Cone - Areo Chocolate', 31.4); 537 | insert into product (id, name, price) values (537, 'Wine - Rosso Del Veronese Igt', 76.36); 538 | insert into product (id, name, price) values (538, 'Bread - White, Sliced', 2.66); 539 | insert into product (id, name, price) values (539, 'Soup - French Can Pea', 47.98); 540 | insert into product (id, name, price) values (540, 'Wasabi Paste', 9.79); 541 | insert into product (id, name, price) values (541, 'Plasticspoonblack', 18.25); 542 | insert into product (id, name, price) values (542, 'Chocolate - Liqueur Cups With Foil', 20.89); 543 | insert into product (id, name, price) values (543, 'Green Tea Refresher', 91.08); 544 | insert into product (id, name, price) values (544, 'Coffee Guatemala Dark', 44.97); 545 | insert into product (id, name, price) values (545, 'Pail - 4l White, With Handle', 27.71); 546 | insert into product (id, name, price) values (546, 'Cheese - Brie', 64.44); 547 | insert into product (id, name, price) values (547, 'Cookie Dough - Peanut Butter', 29.43); 548 | insert into product (id, name, price) values (548, 'Bread - Italian Corn Meal Poly', 34.22); 549 | insert into product (id, name, price) values (549, 'Coconut - Shredded, Sweet', 31.92); 550 | insert into product (id, name, price) values (550, 'Steampan - Foil', 40.87); 551 | insert into product (id, name, price) values (551, 'Sauce - Hoisin', 71.64); 552 | insert into product (id, name, price) values (552, 'Momiji Oroshi Chili Sauce', 34.47); 553 | insert into product (id, name, price) values (553, 'Taro Leaves', 68.16); 554 | insert into product (id, name, price) values (554, 'Soup V8 Roasted Red Pepper', 26.56); 555 | insert into product (id, name, price) values (555, 'Soap - Hand Soap', 79.43); 556 | insert into product (id, name, price) values (556, 'Clams - Littleneck, Whole', 22.05); 557 | insert into product (id, name, price) values (557, 'Melon - Watermelon Yellow', 1.14); 558 | insert into product (id, name, price) values (558, 'Squash - Butternut', 46.44); 559 | insert into product (id, name, price) values (559, 'Soup - Knorr, Chicken Gumbo', 28.48); 560 | insert into product (id, name, price) values (560, 'Mcguinness - Blue Curacao', 59.09); 561 | insert into product (id, name, price) values (561, 'Mushroom - Morel Frozen', 33.84); 562 | insert into product (id, name, price) values (562, 'Chicken - White Meat With Tender', 26.77); 563 | insert into product (id, name, price) values (563, 'Muffin Hinge - 211n', 51.69); 564 | insert into product (id, name, price) values (564, 'Mix - Cappucino Cocktail', 8.8); 565 | insert into product (id, name, price) values (565, 'Bag - Clear 7 Lb', 34.05); 566 | insert into product (id, name, price) values (566, 'Salmon Steak - Cohoe 8 Oz', 79.24); 567 | insert into product (id, name, price) values (567, 'Spinach - Baby', 51.62); 568 | insert into product (id, name, price) values (568, 'Chocolate - Dark', 80.51); 569 | insert into product (id, name, price) values (569, 'Carbonated Water - Blackberry', 33.45); 570 | insert into product (id, name, price) values (570, 'Beans - Soya Bean', 95.51); 571 | insert into product (id, name, price) values (571, 'Juice - Lemon', 81.63); 572 | insert into product (id, name, price) values (572, 'Pork - Suckling Pig', 63.38); 573 | insert into product (id, name, price) values (573, 'Mustard - Pommery', 74.73); 574 | insert into product (id, name, price) values (574, 'Appetizer - Mushroom Tart', 76.5); 575 | insert into product (id, name, price) values (575, 'Bread - Italian Corn Meal Poly', 1.2); 576 | insert into product (id, name, price) values (576, 'Grapes - Red', 13.6); 577 | insert into product (id, name, price) values (577, 'Beef - Tender Tips', 68.97); 578 | insert into product (id, name, price) values (578, 'Yams', 2.39); 579 | insert into product (id, name, price) values (579, 'Peas - Frozen', 99.97); 580 | insert into product (id, name, price) values (580, 'Yokaline', 8.36); 581 | insert into product (id, name, price) values (581, 'Island Oasis - Wildberry', 16.32); 582 | insert into product (id, name, price) values (582, 'Pasta - Linguini, Dry', 74.76); 583 | insert into product (id, name, price) values (583, 'Oil - Pumpkinseed', 82.36); 584 | insert into product (id, name, price) values (584, 'Kale - Red', 67.88); 585 | insert into product (id, name, price) values (585, 'Olives - Stuffed', 2.2); 586 | insert into product (id, name, price) values (586, 'Salmon - Smoked, Sliced', 11.8); 587 | insert into product (id, name, price) values (587, 'Garam Marsala', 44.01); 588 | insert into product (id, name, price) values (588, 'Crab - Back Fin Meat, Canned', 23.59); 589 | insert into product (id, name, price) values (589, 'Sausage - Chorizo', 35.01); 590 | insert into product (id, name, price) values (590, 'Cookie Dough - Chunky', 74.35); 591 | insert into product (id, name, price) values (591, 'Chips Potato Swt Chilli Sour', 88.22); 592 | insert into product (id, name, price) values (592, 'Pasta - Penne, Lisce, Dry', 13.12); 593 | insert into product (id, name, price) values (593, 'Mcguinness - Blue Curacao', 39.01); 594 | insert into product (id, name, price) values (594, 'Turkey Tenderloin Frozen', 11.95); 595 | insert into product (id, name, price) values (595, 'Beer - Camerons Cream Ale', 26.17); 596 | insert into product (id, name, price) values (596, 'Trueblue - Blueberry Cranberry', 34.88); 597 | insert into product (id, name, price) values (597, 'Wine - Soave Folonari', 22.62); 598 | insert into product (id, name, price) values (598, 'Beef - Bresaola', 44.49); 599 | insert into product (id, name, price) values (599, 'Cheese - Provolone', 36.25); 600 | insert into product (id, name, price) values (600, 'Sugar - Monocystal / Rock', 1.07); 601 | insert into product (id, name, price) values (601, 'Sole - Iqf', 46.79); 602 | insert into product (id, name, price) values (602, 'Shrimp - Black Tiger 8 - 12', 69.11); 603 | insert into product (id, name, price) values (603, 'Pasta - Cannelloni, Sheets, Fresh', 74.39); 604 | insert into product (id, name, price) values (604, 'Pepper - Black, Ground', 34.46); 605 | insert into product (id, name, price) values (605, 'Huck Towels White', 62.66); 606 | insert into product (id, name, price) values (606, 'Mustard - Dijon', 84.4); 607 | insert into product (id, name, price) values (607, 'Cheese - Shred Cheddar / Mozza', 90.63); 608 | insert into product (id, name, price) values (608, 'Smoked Tongue', 67.11); 609 | insert into product (id, name, price) values (609, 'Guinea Fowl', 8.19); 610 | insert into product (id, name, price) values (610, 'Bulgar', 57.6); 611 | insert into product (id, name, price) values (611, 'Bread - Rosemary Focaccia', 6.16); 612 | insert into product (id, name, price) values (612, 'Plastic Wrap', 62.93); 613 | insert into product (id, name, price) values (613, 'Vodka - Lemon, Absolut', 11.54); 614 | insert into product (id, name, price) values (614, 'Oil - Cooking Spray', 62.15); 615 | insert into product (id, name, price) values (615, 'Foil Wrap', 32.34); 616 | insert into product (id, name, price) values (616, 'Island Oasis - Raspberry', 78.11); 617 | insert into product (id, name, price) values (617, 'Wine - Sauvignon Blanc Oyster', 41.87); 618 | insert into product (id, name, price) values (618, 'Black Currants', 3.86); 619 | insert into product (id, name, price) values (619, 'Beef Cheek Fresh', 31.45); 620 | insert into product (id, name, price) values (620, 'Tart - Butter Plain Squares', 42.5); 621 | insert into product (id, name, price) values (621, 'Cake - French Pear Tart', 65.55); 622 | insert into product (id, name, price) values (622, 'Trout - Rainbow, Frozen', 29.72); 623 | insert into product (id, name, price) values (623, 'Beer - Sleeman Fine Porter', 70.1); 624 | insert into product (id, name, price) values (624, 'Broom - Corn', 23.22); 625 | insert into product (id, name, price) values (625, 'Table Cloth 72x144 White', 30.05); 626 | insert into product (id, name, price) values (626, 'Island Oasis - Mango Daiquiri', 37.55); 627 | insert into product (id, name, price) values (627, 'Juice - Propel Sport', 80.75); 628 | insert into product (id, name, price) values (628, 'Blueberries - Frozen', 53.41); 629 | insert into product (id, name, price) values (629, 'Coffee - Dark Roast', 80.66); 630 | insert into product (id, name, price) values (630, 'Mix - Cappucino Cocktail', 32.51); 631 | insert into product (id, name, price) values (631, 'Doilies - 5, Paper', 81.47); 632 | insert into product (id, name, price) values (632, 'Petit Baguette', 25.42); 633 | insert into product (id, name, price) values (633, 'Cheese - Brie, Triple Creme', 28.62); 634 | insert into product (id, name, price) values (634, 'Tea - Grapefruit Green Tea', 92.26); 635 | insert into product (id, name, price) values (635, 'Yeast Dry - Fermipan', 26.07); 636 | insert into product (id, name, price) values (636, 'Wine - Sawmill Creek Autumn', 40.48); 637 | insert into product (id, name, price) values (637, 'Bok Choy - Baby', 82.81); 638 | insert into product (id, name, price) values (638, 'Pasta - Penne, Rigate, Dry', 52.7); 639 | insert into product (id, name, price) values (639, 'Apricots - Dried', 41.74); 640 | insert into product (id, name, price) values (640, 'Basil - Fresh', 59.26); 641 | insert into product (id, name, price) values (641, 'Soup - Knorr, Chicken Noodle', 31.11); 642 | insert into product (id, name, price) values (642, 'Ice Cream - Super Sandwich', 21.15); 643 | insert into product (id, name, price) values (643, 'Olives - Black, Pitted', 28.64); 644 | insert into product (id, name, price) values (644, 'Hickory Smoke, Liquid', 24.85); 645 | insert into product (id, name, price) values (645, 'Beef - Ground, Extra Lean, Fresh', 18.6); 646 | insert into product (id, name, price) values (646, 'Melon - Watermelon Yellow', 92.57); 647 | insert into product (id, name, price) values (647, 'Coffee - Dark Roast', 62.0); 648 | insert into product (id, name, price) values (648, 'Beans - Kidney, Canned', 71.89); 649 | insert into product (id, name, price) values (649, 'Soup - Campbells Mac N Cheese', 96.35); 650 | insert into product (id, name, price) values (650, 'Plate - Foam, Bread And Butter', 83.09); 651 | insert into product (id, name, price) values (651, 'Nut - Macadamia', 64.05); 652 | insert into product (id, name, price) values (652, 'Curry Paste - Green Masala', 90.97); 653 | insert into product (id, name, price) values (653, 'Nestea - Ice Tea, Diet', 33.61); 654 | insert into product (id, name, price) values (654, 'Wine - White, Concha Y Toro', 24.73); 655 | insert into product (id, name, price) values (655, 'Cookies Oatmeal Raisin', 75.23); 656 | insert into product (id, name, price) values (656, 'Chick Peas - Dried', 99.95); 657 | insert into product (id, name, price) values (657, 'Dr. Pepper - 355ml', 55.32); 658 | insert into product (id, name, price) values (658, 'Beef - Sushi Flat Iron Steak', 44.66); 659 | insert into product (id, name, price) values (659, 'Celery Root', 8.37); 660 | insert into product (id, name, price) values (660, 'Cup - 4oz Translucent', 76.42); 661 | insert into product (id, name, price) values (661, 'Dill Weed - Fresh', 47.64); 662 | insert into product (id, name, price) values (662, 'Oil - Shortening,liqud, Fry', 49.42); 663 | insert into product (id, name, price) values (663, 'Greens Mustard', 2.57); 664 | insert into product (id, name, price) values (664, 'Wine - Harrow Estates, Vidal', 89.7); 665 | insert into product (id, name, price) values (665, 'Foam Tray S2', 34.76); 666 | insert into product (id, name, price) values (666, 'Jam - Marmalade, Orange', 87.29); 667 | insert into product (id, name, price) values (667, 'Sauce - Salsa', 57.71); 668 | insert into product (id, name, price) values (668, 'Squid Ink', 40.04); 669 | insert into product (id, name, price) values (669, 'Wine - Periguita Fonseca', 78.95); 670 | insert into product (id, name, price) values (670, 'Cake - Dulce De Leche', 48.06); 671 | insert into product (id, name, price) values (671, 'Flour - Semolina', 57.83); 672 | insert into product (id, name, price) values (672, 'Pasta - Lasagna Noodle, Frozen', 52.42); 673 | insert into product (id, name, price) values (673, 'Wine - Zonnebloem Pinotage', 3.01); 674 | insert into product (id, name, price) values (674, 'Petit Baguette', 12.12); 675 | insert into product (id, name, price) values (675, 'Chocolate Bar - Coffee Crisp', 99.0); 676 | insert into product (id, name, price) values (676, 'Mcguinness - Blue Curacao', 9.11); 677 | insert into product (id, name, price) values (677, 'Otomegusa Dashi Konbu', 15.78); 678 | insert into product (id, name, price) values (678, 'Bonito Flakes - Toku Katsuo', 44.28); 679 | insert into product (id, name, price) values (679, 'Sherry - Dry', 9.16); 680 | insert into product (id, name, price) values (680, 'Wine - Niagara Peninsula Vqa', 74.97); 681 | insert into product (id, name, price) values (681, 'Bar Energy Chocchip', 65.92); 682 | insert into product (id, name, price) values (682, 'Water - Tonic', 29.95); 683 | insert into product (id, name, price) values (683, 'Soap - Mr.clean Floor Soap', 14.36); 684 | insert into product (id, name, price) values (684, 'Water - Tonic', 72.81); 685 | insert into product (id, name, price) values (685, 'Cheese - Havarti, Salsa', 69.21); 686 | insert into product (id, name, price) values (686, 'Roe - White Fish', 69.29); 687 | insert into product (id, name, price) values (687, 'Lobster - Baby, Boiled', 19.18); 688 | insert into product (id, name, price) values (688, 'Wine - Red, Pelee Island Merlot', 59.29); 689 | insert into product (id, name, price) values (689, 'Roe - Flying Fish', 39.6); 690 | insert into product (id, name, price) values (690, 'Chef Hat 25cm', 89.3); 691 | insert into product (id, name, price) values (691, 'Swiss Chard - Red', 71.63); 692 | insert into product (id, name, price) values (692, 'Milk - 2%', 71.69); 693 | insert into product (id, name, price) values (693, 'Cheese - Ricotta', 87.68); 694 | insert into product (id, name, price) values (694, 'Beer - Tetleys', 36.89); 695 | insert into product (id, name, price) values (695, 'Chicken - Wings, Tip Off', 89.46); 696 | insert into product (id, name, price) values (696, 'Beef - Bones, Cut - Up', 15.96); 697 | insert into product (id, name, price) values (697, 'Table Cloth 81x81 Colour', 10.08); 698 | insert into product (id, name, price) values (698, 'Duck - Legs', 25.99); 699 | insert into product (id, name, price) values (699, 'Soup Knorr Chili With Beans', 16.7); 700 | insert into product (id, name, price) values (700, 'Wine - Rosso Toscano Igt', 40.64); 701 | insert into product (id, name, price) values (701, 'Pasta - Rotini, Colour, Dry', 56.59); 702 | insert into product (id, name, price) values (702, 'Table Cloth 72x144 White', 22.92); 703 | insert into product (id, name, price) values (703, 'Bread - Multigrain, Loaf', 8.83); 704 | insert into product (id, name, price) values (704, 'Nut - Pistachio, Shelled', 40.71); 705 | insert into product (id, name, price) values (705, 'Lemonade - Island Tea, 591 Ml', 46.36); 706 | insert into product (id, name, price) values (706, 'Mushroom - Oyster, Fresh', 90.18); 707 | insert into product (id, name, price) values (707, 'Couscous', 65.17); 708 | insert into product (id, name, price) values (708, 'Chilli Paste, Sambal Oelek', 6.16); 709 | insert into product (id, name, price) values (709, 'Cake - Mini Potato Pancake', 99.2); 710 | insert into product (id, name, price) values (710, 'Drambuie', 50.11); 711 | insert into product (id, name, price) values (711, 'Pepperoni Slices', 57.03); 712 | insert into product (id, name, price) values (712, 'Rice Paper', 41.8); 713 | insert into product (id, name, price) values (713, 'Zucchini - Yellow', 60.08); 714 | insert into product (id, name, price) values (714, 'Instant Coffee', 93.74); 715 | insert into product (id, name, price) values (715, 'Pastry - Cherry Danish - Mini', 54.78); 716 | insert into product (id, name, price) values (716, 'Kellogs All Bran Bars', 71.96); 717 | insert into product (id, name, price) values (717, 'Cheese - Camembert', 33.54); 718 | insert into product (id, name, price) values (718, 'Baking Soda', 86.41); 719 | insert into product (id, name, price) values (719, 'Sauce - Soy Low Sodium - 3.87l', 46.49); 720 | insert into product (id, name, price) values (720, 'Lamb - Loin, Trimmed, Boneless', 94.9); 721 | insert into product (id, name, price) values (721, 'Wine - Domaine Boyar Royal', 7.26); 722 | insert into product (id, name, price) values (722, 'Wine - White Cab Sauv.on', 29.14); 723 | insert into product (id, name, price) values (723, 'Pickerel - Fillets', 77.62); 724 | insert into product (id, name, price) values (724, 'Tomato - Green', 95.49); 725 | insert into product (id, name, price) values (725, 'The Pop Shoppe - Root Beer', 75.65); 726 | insert into product (id, name, price) values (726, 'Urban Zen Drinks', 37.12); 727 | insert into product (id, name, price) values (727, 'Oil - Truffle, Black', 80.45); 728 | insert into product (id, name, price) values (728, 'Calaloo', 67.65); 729 | insert into product (id, name, price) values (729, 'Samosa - Veg', 1.43); 730 | insert into product (id, name, price) values (730, 'Salmon Steak - Cohoe 6 Oz', 80.71); 731 | insert into product (id, name, price) values (731, 'Bread - Roll, Italian', 80.08); 732 | insert into product (id, name, price) values (732, 'Cheese - Brie,danish', 17.26); 733 | insert into product (id, name, price) values (733, 'Shopper Bag - S - 4', 65.01); 734 | insert into product (id, name, price) values (734, 'Wine - Magnotta - Belpaese', 8.06); 735 | insert into product (id, name, price) values (735, 'Sponge Cake Mix - Chocolate', 59.53); 736 | insert into product (id, name, price) values (736, 'Coffee Cup 12oz 5342cd', 63.03); 737 | insert into product (id, name, price) values (737, 'Vinegar - Red Wine', 91.67); 738 | insert into product (id, name, price) values (738, 'Coffee Guatemala Dark', 41.35); 739 | insert into product (id, name, price) values (739, 'Bread Base - Goodhearth', 26.17); 740 | insert into product (id, name, price) values (740, 'Corn - Mini', 13.91); 741 | insert into product (id, name, price) values (741, 'Cheese - Pont Couvert', 34.07); 742 | insert into product (id, name, price) values (742, 'Tart Shells - Sweet, 3', 12.76); 743 | insert into product (id, name, price) values (743, 'Turkey - Whole, Fresh', 56.07); 744 | insert into product (id, name, price) values (744, 'Soup - Campbells Mushroom', 17.6); 745 | insert into product (id, name, price) values (745, 'Soup Knorr Chili With Beans', 54.23); 746 | insert into product (id, name, price) values (746, 'Energy - Boo - Koo', 49.26); 747 | insert into product (id, name, price) values (747, 'Extract - Almond', 1.52); 748 | insert into product (id, name, price) values (748, 'Water - Evian 355 Ml', 30.08); 749 | insert into product (id, name, price) values (749, 'Pastry - Carrot Muffin - Mini', 71.22); 750 | insert into product (id, name, price) values (750, 'Stock - Fish', 61.48); 751 | insert into product (id, name, price) values (751, 'Water - Green Tea Refresher', 58.43); 752 | insert into product (id, name, price) values (752, 'Banana - Green', 43.96); 753 | insert into product (id, name, price) values (753, 'Bagel - Everything', 4.17); 754 | insert into product (id, name, price) values (754, 'Carbonated Water - Raspberry', 42.94); 755 | insert into product (id, name, price) values (755, 'Zucchini - Green', 91.82); 756 | insert into product (id, name, price) values (756, 'Grapes - Green', 49.18); 757 | insert into product (id, name, price) values (757, 'Sugar - Brown, Individual', 26.53); 758 | insert into product (id, name, price) values (758, 'Eel Fresh', 55.31); 759 | insert into product (id, name, price) values (759, 'Chips - Doritos', 7.87); 760 | insert into product (id, name, price) values (760, 'Mustard - Pommery', 74.73); 761 | insert into product (id, name, price) values (761, 'Container - Clear 32 Oz', 74.76); 762 | insert into product (id, name, price) values (762, 'Tea - Apple Green Tea', 80.81); 763 | insert into product (id, name, price) values (763, 'Soup - Campbells, Spinach Crm', 10.74); 764 | insert into product (id, name, price) values (764, 'Soup - French Onion', 53.58); 765 | insert into product (id, name, price) values (765, 'Tuna - Sushi Grade', 21.4); 766 | insert into product (id, name, price) values (766, 'Sour Puss - Tangerine', 92.12); 767 | insert into product (id, name, price) values (767, 'Liquid Aminios Acid - Braggs', 43.56); 768 | insert into product (id, name, price) values (768, 'Pork Loin Cutlets', 19.07); 769 | insert into product (id, name, price) values (769, 'Asparagus - Green, Fresh', 45.09); 770 | insert into product (id, name, price) values (770, 'Fish - Base, Bouillion', 15.99); 771 | insert into product (id, name, price) values (771, 'Radish - Pickled', 42.01); 772 | insert into product (id, name, price) values (772, 'Sprouts - Brussel', 98.56); 773 | insert into product (id, name, price) values (773, 'Lamb - Whole, Fresh', 45.59); 774 | insert into product (id, name, price) values (774, 'Beans - Navy, Dry', 4.65); 775 | insert into product (id, name, price) values (775, 'Tuna - Salad Premix', 54.6); 776 | insert into product (id, name, price) values (776, 'Beer - Sleemans Cream Ale', 27.77); 777 | insert into product (id, name, price) values (777, 'Pants Custom Dry Clean', 43.19); 778 | insert into product (id, name, price) values (778, 'Beets - Mini Golden', 89.63); 779 | insert into product (id, name, price) values (779, 'Chicken - Ground', 14.37); 780 | insert into product (id, name, price) values (780, 'Ecolab - Hand Soap Form Antibac', 68.06); 781 | insert into product (id, name, price) values (781, 'Chicken - Soup Base', 94.78); 782 | insert into product (id, name, price) values (782, 'Appetizer - Southwestern', 3.18); 783 | insert into product (id, name, price) values (783, 'Muffin Batt - Carrot Spice', 59.07); 784 | insert into product (id, name, price) values (784, 'Tea - Herbal Sweet Dreams', 93.1); 785 | insert into product (id, name, price) values (785, 'Wine - Fat Bastard Merlot', 24.87); 786 | insert into product (id, name, price) values (786, 'Cookies - Oreo, 4 Pack', 56.85); 787 | insert into product (id, name, price) values (787, 'Cake - French Pear Tart', 31.2); 788 | insert into product (id, name, price) values (788, 'Fish - Bones', 46.15); 789 | insert into product (id, name, price) values (789, 'Curry Paste - Madras', 30.16); 790 | insert into product (id, name, price) values (790, 'Ice - Clear, 300 Lb For Carving', 40.62); 791 | insert into product (id, name, price) values (791, 'Wine - Saint Emilion Calvet', 81.98); 792 | insert into product (id, name, price) values (792, 'Lamb - Ground', 26.65); 793 | insert into product (id, name, price) values (793, 'Wine - Ruffino Chianti', 63.64); 794 | insert into product (id, name, price) values (794, 'Ginger - Crystalized', 91.43); 795 | insert into product (id, name, price) values (795, 'Beans - French', 75.08); 796 | insert into product (id, name, price) values (796, 'Beer - Moosehead', 19.86); 797 | insert into product (id, name, price) values (797, 'Table Cloth 54x54 White', 26.39); 798 | insert into product (id, name, price) values (798, 'Tabasco Sauce, 2 Oz', 81.16); 799 | insert into product (id, name, price) values (799, 'Muffin - Mix - Creme Brule 15l', 15.52); 800 | insert into product (id, name, price) values (800, 'Sausage - Liver', 27.33); 801 | insert into product (id, name, price) values (801, 'Squash - Pepper', 78.29); 802 | insert into product (id, name, price) values (802, 'Muffin - Mix - Strawberry Rhubarb', 32.02); 803 | insert into product (id, name, price) values (803, 'Wine - Savigny - Les - Beaune', 19.49); 804 | insert into product (id, name, price) values (804, 'Lettuce - Lambs Mash', 5.85); 805 | insert into product (id, name, price) values (805, 'Carbonated Water - Blackcherry', 88.46); 806 | insert into product (id, name, price) values (806, 'Beets - Pickled', 24.72); 807 | insert into product (id, name, price) values (807, 'Wheat - Soft Kernal Of Wheat', 42.23); 808 | insert into product (id, name, price) values (808, 'Rice - Wild', 86.33); 809 | insert into product (id, name, price) values (809, 'Wine - Jaboulet Cotes Du Rhone', 56.8); 810 | insert into product (id, name, price) values (810, 'Versatainer Nc - 8288', 84.31); 811 | insert into product (id, name, price) values (811, 'Pasta - Lasagne, Fresh', 54.98); 812 | insert into product (id, name, price) values (812, 'Buffalo - Short Rib Fresh', 44.3); 813 | insert into product (id, name, price) values (813, 'Oranges', 95.76); 814 | insert into product (id, name, price) values (814, 'Tomatoes - Cherry, Yellow', 1.91); 815 | insert into product (id, name, price) values (815, 'Flavouring Vanilla Artificial', 19.81); 816 | insert into product (id, name, price) values (816, 'Sage - Fresh', 14.42); 817 | insert into product (id, name, price) values (817, 'Wine - Sherry Dry Sack, William', 36.99); 818 | insert into product (id, name, price) values (818, 'Rosemary - Fresh', 13.22); 819 | insert into product (id, name, price) values (819, 'Marzipan 50/50', 52.24); 820 | insert into product (id, name, price) values (820, 'Wine - Sawmill Creek Autumn', 58.39); 821 | insert into product (id, name, price) values (821, 'Chick Peas - Canned', 51.08); 822 | insert into product (id, name, price) values (822, 'Pasta - Fusili, Dry', 46.89); 823 | insert into product (id, name, price) values (823, 'Nutmeg - Ground', 69.49); 824 | insert into product (id, name, price) values (824, 'Garbage Bags - Black', 3.08); 825 | insert into product (id, name, price) values (825, 'Toothpick Frilled', 48.72); 826 | insert into product (id, name, price) values (826, 'Apple - Custard', 46.38); 827 | insert into product (id, name, price) values (827, 'Cookie Dough - Peanut Butter', 67.97); 828 | insert into product (id, name, price) values (828, 'Water - Green Tea Refresher', 45.95); 829 | insert into product (id, name, price) values (829, 'Tarts Assorted', 73.33); 830 | insert into product (id, name, price) values (830, 'Beer - Creemore', 96.87); 831 | insert into product (id, name, price) values (831, 'Myers Planters Punch', 16.27); 832 | insert into product (id, name, price) values (832, 'Coffee Beans - Chocolate', 48.65); 833 | insert into product (id, name, price) values (833, 'Cake Slab', 13.54); 834 | insert into product (id, name, price) values (834, 'Garlic Powder', 39.87); 835 | insert into product (id, name, price) values (835, 'Foam Cup 6 Oz', 49.52); 836 | insert into product (id, name, price) values (836, 'Beans - Black Bean, Preserved', 98.1); 837 | insert into product (id, name, price) values (837, 'Turkey - Whole, Fresh', 72.42); 838 | insert into product (id, name, price) values (838, 'Cake Sheet Combo Party Pack', 29.52); 839 | insert into product (id, name, price) values (839, 'Absolut Citron', 87.6); 840 | insert into product (id, name, price) values (840, 'Sugar - Invert', 48.02); 841 | insert into product (id, name, price) values (841, 'Vol Au Vents', 94.57); 842 | insert into product (id, name, price) values (842, 'Pur Source', 96.09); 843 | insert into product (id, name, price) values (843, 'Soap - Mr.clean Floor Soap', 35.09); 844 | insert into product (id, name, price) values (844, 'Breakfast Quesadillas', 62.4); 845 | insert into product (id, name, price) values (845, 'Water - Aquafina Vitamin', 28.01); 846 | insert into product (id, name, price) values (846, 'Foil Wrap', 34.62); 847 | insert into product (id, name, price) values (847, 'Beef - Ox Tongue', 67.34); 848 | insert into product (id, name, price) values (848, 'Langers - Ruby Red Grapfruit', 91.69); 849 | insert into product (id, name, price) values (849, 'Muffin Hinge Container 6', 19.95); 850 | insert into product (id, name, price) values (850, 'Pie Shell - 5', 89.25); 851 | insert into product (id, name, price) values (851, 'Lamb - Racks, Frenched', 52.23); 852 | insert into product (id, name, price) values (852, 'Chips - Miss Vickies', 91.56); 853 | insert into product (id, name, price) values (853, 'Container Clear 8 Oz', 87.94); 854 | insert into product (id, name, price) values (854, 'Iced Tea Concentrate', 71.26); 855 | insert into product (id, name, price) values (855, 'Nori Sea Weed', 39.5); 856 | insert into product (id, name, price) values (856, 'V8 - Berry Blend', 96.57); 857 | insert into product (id, name, price) values (857, 'Pork Ham Prager', 78.51); 858 | insert into product (id, name, price) values (858, 'Pears - Anjou', 18.42); 859 | insert into product (id, name, price) values (859, 'Arctic Char - Fillets', 24.32); 860 | insert into product (id, name, price) values (860, 'Chinese Foods - Chicken Wing', 37.6); 861 | insert into product (id, name, price) values (861, 'Wine - Chablis 2003 Champs', 27.64); 862 | insert into product (id, name, price) values (862, 'Filter - Coffee', 11.28); 863 | insert into product (id, name, price) values (863, 'Bread - Roll, Whole Wheat', 49.87); 864 | insert into product (id, name, price) values (864, 'Salmon - Smoked, Sliced', 81.99); 865 | insert into product (id, name, price) values (865, 'Apple - Granny Smith', 16.3); 866 | insert into product (id, name, price) values (866, 'Soup - Knorr, Veg / Beef', 2.16); 867 | insert into product (id, name, price) values (867, 'Juice - V8, Tomato', 3.07); 868 | insert into product (id, name, price) values (868, 'Rappini - Andy Boy', 49.9); 869 | insert into product (id, name, price) values (869, 'Cake - Mini Cheesecake', 47.98); 870 | insert into product (id, name, price) values (870, 'Wine - Champagne Brut Veuve', 3.71); 871 | insert into product (id, name, price) values (871, 'Truffle Cups - White Paper', 46.15); 872 | insert into product (id, name, price) values (872, 'Mushroom - Enoki, Fresh', 31.67); 873 | insert into product (id, name, price) values (873, 'Bag - Regular Kraft 20 Lb', 2.48); 874 | insert into product (id, name, price) values (874, 'Potatoes - Parissienne', 54.16); 875 | insert into product (id, name, price) values (875, 'Soup - Campbells Beef Strogonoff', 96.13); 876 | insert into product (id, name, price) values (876, 'Cleaner - Bleach', 84.87); 877 | insert into product (id, name, price) values (877, 'Garam Marsala', 41.35); 878 | insert into product (id, name, price) values (878, 'Wine - Ej Gallo Sonoma', 64.45); 879 | insert into product (id, name, price) values (879, 'Beef - Cooked, Corned', 65.58); 880 | insert into product (id, name, price) values (880, 'Kiwi', 12.05); 881 | insert into product (id, name, price) values (881, 'Beef - Tongue, Fresh', 97.97); 882 | insert into product (id, name, price) values (882, 'Muffins - Assorted', 37.67); 883 | insert into product (id, name, price) values (883, 'Rabbit - Whole', 54.81); 884 | insert into product (id, name, price) values (884, 'Wine - Ruffino Chianti Classico', 94.39); 885 | insert into product (id, name, price) values (885, 'Rootbeer', 81.75); 886 | insert into product (id, name, price) values (886, 'Veal - Inside', 72.84); 887 | insert into product (id, name, price) values (887, 'Cabbage - Red', 6.02); 888 | insert into product (id, name, price) values (888, 'Baking Soda', 98.5); 889 | insert into product (id, name, price) values (889, 'Pepper - Cubanelle', 19.86); 890 | insert into product (id, name, price) values (890, 'Cardamon Seed / Pod', 89.4); 891 | insert into product (id, name, price) values (891, 'Blueberries', 20.28); 892 | insert into product (id, name, price) values (892, 'Tomatoes - Cherry', 40.79); 893 | insert into product (id, name, price) values (893, 'Coffee - Decafenated', 74.79); 894 | insert into product (id, name, price) values (894, 'Spice - Onion Powder Granulated', 65.86); 895 | insert into product (id, name, price) values (895, 'Lemonade - Natural, 591 Ml', 90.53); 896 | insert into product (id, name, price) values (896, 'Pasta - Shells, Medium, Dry', 67.46); 897 | insert into product (id, name, price) values (897, 'Cheese - Parmigiano Reggiano', 6.75); 898 | insert into product (id, name, price) values (898, 'Pasta - Fett Alfredo, Single Serve', 10.81); 899 | insert into product (id, name, price) values (899, 'Chips - Assorted', 44.52); 900 | insert into product (id, name, price) values (900, 'Container - Hngd Cll Blk 7x7x3', 19.1); 901 | insert into product (id, name, price) values (901, 'Fib N9 - Prague Powder', 9.87); 902 | insert into product (id, name, price) values (902, 'Sprouts - China Rose', 27.89); 903 | insert into product (id, name, price) values (903, 'Wine - Wyndham Estate Bin 777', 68.44); 904 | insert into product (id, name, price) values (904, 'Pork Casing', 77.96); 905 | insert into product (id, name, price) values (905, 'Spinach - Frozen', 88.04); 906 | insert into product (id, name, price) values (906, 'Veal - Insides Provini', 75.79); 907 | insert into product (id, name, price) values (907, 'V8 - Tropical Blend', 11.63); 908 | insert into product (id, name, price) values (908, 'Sloe Gin - Mcguinness', 58.03); 909 | insert into product (id, name, price) values (909, 'Chocolate Bar - Oh Henry', 74.6); 910 | insert into product (id, name, price) values (910, 'Icecream - Dstk Super Cone', 31.34); 911 | insert into product (id, name, price) values (911, 'Cheese - Woolwich Goat, Log', 43.37); 912 | insert into product (id, name, price) values (912, 'Kellogs All Bran Bars', 66.31); 913 | insert into product (id, name, price) values (913, 'Sugar - White Packet', 78.96); 914 | insert into product (id, name, price) values (914, 'Momiji Oroshi Chili Sauce', 45.78); 915 | insert into product (id, name, price) values (915, 'Nantucket - Orange Mango Cktl', 33.28); 916 | insert into product (id, name, price) values (916, 'Sugar - Monocystal / Rock', 83.83); 917 | insert into product (id, name, price) values (917, 'V8 Splash Strawberry Banana', 3.47); 918 | insert into product (id, name, price) values (918, 'Sauce - Salsa', 64.7); 919 | insert into product (id, name, price) values (919, 'Steampan Lid', 7.87); 920 | insert into product (id, name, price) values (920, 'Nut - Peanut, Roasted', 66.4); 921 | insert into product (id, name, price) values (921, 'Wine - Valpolicella Masi', 49.41); 922 | insert into product (id, name, price) values (922, 'Wine - Valpolicella Masi', 90.42); 923 | insert into product (id, name, price) values (923, 'Wine - Bouchard La Vignee Pinot', 40.49); 924 | insert into product (id, name, price) values (924, 'Chocolate Liqueur - Godet White', 9.78); 925 | insert into product (id, name, price) values (925, 'Wine - Red, Black Opal Shiraz', 31.11); 926 | insert into product (id, name, price) values (926, 'Garam Masala Powder', 67.95); 927 | insert into product (id, name, price) values (927, 'Thyme - Dried', 94.13); 928 | insert into product (id, name, price) values (928, 'Turkey Tenderloin Frozen', 64.62); 929 | insert into product (id, name, price) values (929, 'Cake - French Pear Tart', 88.18); 930 | insert into product (id, name, price) values (930, 'Icecream - Dstk Strw Chseck', 58.45); 931 | insert into product (id, name, price) values (931, 'Soho Lychee Liqueur', 6.46); 932 | insert into product (id, name, price) values (932, 'Potatoes - Peeled', 69.28); 933 | insert into product (id, name, price) values (933, 'Chinese Foods - Thick Noodles', 22.46); 934 | insert into product (id, name, price) values (934, 'Towel - Roll White', 11.88); 935 | insert into product (id, name, price) values (935, 'Savory', 95.23); 936 | insert into product (id, name, price) values (936, 'Wine - Puligny Montrachet A.', 47.44); 937 | insert into product (id, name, price) values (937, 'Duck - Whole', 39.86); 938 | insert into product (id, name, price) values (938, 'Potatoes - Mini White 3 Oz', 33.41); 939 | insert into product (id, name, price) values (939, 'Tuna - Salad Premix', 33.29); 940 | insert into product (id, name, price) values (940, 'Pork - Loin, Center Cut', 60.69); 941 | insert into product (id, name, price) values (941, 'Chocolate - Milk, Callets', 76.43); 942 | insert into product (id, name, price) values (942, 'Sun - Dried Tomatoes', 17.01); 943 | insert into product (id, name, price) values (943, 'Carbonated Water - Blackberry', 44.05); 944 | insert into product (id, name, price) values (944, 'Muffin Mix - Lemon Cranberry', 9.23); 945 | insert into product (id, name, price) values (945, 'Tomatoes - Hot House', 4.12); 946 | insert into product (id, name, price) values (946, 'Paper Towel Touchless', 18.1); 947 | insert into product (id, name, price) values (947, 'Flour - Bran, Red', 74.73); 948 | insert into product (id, name, price) values (948, 'Pork - Back, Long Cut, Boneless', 43.64); 949 | insert into product (id, name, price) values (949, 'Cheese - Stilton', 5.39); 950 | insert into product (id, name, price) values (950, 'Puree - Pear', 8.53); 951 | insert into product (id, name, price) values (951, 'Cheese - Shred Cheddar / Mozza', 48.55); 952 | insert into product (id, name, price) values (952, 'Blouse / Shirt / Sweater', 87.35); 953 | insert into product (id, name, price) values (953, 'Wine - Lou Black Shiraz', 41.49); 954 | insert into product (id, name, price) values (954, 'Sprite, Diet - 355ml', 6.04); 955 | insert into product (id, name, price) values (955, 'Nantucket - Pomegranate Pear', 62.45); 956 | insert into product (id, name, price) values (956, 'Beer - Moosehead', 63.52); 957 | insert into product (id, name, price) values (957, 'Cheese - Goat With Herbs', 26.19); 958 | insert into product (id, name, price) values (958, 'Soup - Campbells Pasta Fagioli', 2.59); 959 | insert into product (id, name, price) values (959, 'Bag - Clear 7 Lb', 55.8); 960 | insert into product (id, name, price) values (960, 'Chicken - Wings, Tip Off', 78.29); 961 | insert into product (id, name, price) values (961, 'Wine - Saint Emilion Calvet', 33.72); 962 | insert into product (id, name, price) values (962, 'Appetiser - Bought', 13.45); 963 | insert into product (id, name, price) values (963, 'Creamers - 10%', 43.86); 964 | insert into product (id, name, price) values (964, 'Wine - Shiraz South Eastern', 58.15); 965 | insert into product (id, name, price) values (965, 'Canada Dry', 9.45); 966 | insert into product (id, name, price) values (966, 'Bread - Crusty Italian Poly', 39.79); 967 | insert into product (id, name, price) values (967, 'Oranges - Navel, 72', 91.25); 968 | insert into product (id, name, price) values (968, 'Coffee - Decafenated', 54.22); 969 | insert into product (id, name, price) values (969, 'Duck - Fat', 30.8); 970 | insert into product (id, name, price) values (970, 'Lettuce - Escarole', 64.25); 971 | insert into product (id, name, price) values (971, 'Milk - Buttermilk', 93.85); 972 | insert into product (id, name, price) values (972, 'Smoked Tongue', 21.61); 973 | insert into product (id, name, price) values (973, 'Versatainer Nc - 9388', 14.81); 974 | insert into product (id, name, price) values (974, 'Cake - Mini Potato Pancake', 61.81); 975 | insert into product (id, name, price) values (975, 'Cheese - St. Paulin', 49.49); 976 | insert into product (id, name, price) values (976, 'Pumpkin', 54.93); 977 | insert into product (id, name, price) values (977, 'Edible Flower - Mixed', 70.78); 978 | insert into product (id, name, price) values (978, 'Ocean Spray - Kiwi Strawberry', 26.38); 979 | insert into product (id, name, price) values (979, 'Wine - Two Oceans Cabernet', 46.78); 980 | insert into product (id, name, price) values (980, 'Beef - Rib Roast, Capless', 27.4); 981 | insert into product (id, name, price) values (981, 'Sesame Seed', 27.79); 982 | insert into product (id, name, price) values (982, 'Lobster - Live', 63.27); 983 | insert into product (id, name, price) values (983, 'Eggwhite Frozen', 21.84); 984 | insert into product (id, name, price) values (984, 'Tomatoes - Diced, Canned', 33.18); 985 | insert into product (id, name, price) values (985, 'Beef - Tongue, Fresh', 96.02); 986 | insert into product (id, name, price) values (986, 'Wine - Mas Chicet Rose, Vintage', 33.68); 987 | insert into product (id, name, price) values (987, 'Muffin Mix - Blueberry', 72.58); 988 | insert into product (id, name, price) values (988, 'Cookie - Dough Variety', 4.23); 989 | insert into product (id, name, price) values (989, 'Easy Off Oven Cleaner', 51.56); 990 | insert into product (id, name, price) values (990, 'Veal - Loin', 15.47); 991 | insert into product (id, name, price) values (991, 'Chicken - Base', 79.98); 992 | insert into product (id, name, price) values (992, 'Steampan - Lid For Half Size', 63.62); 993 | insert into product (id, name, price) values (993, 'Juice - Grapefruit, 341 Ml', 7.05); 994 | insert into product (id, name, price) values (994, 'Sage - Fresh', 79.74); 995 | insert into product (id, name, price) values (995, 'Juice - Lagoon Mango', 93.66); 996 | insert into product (id, name, price) values (996, 'Brownies - Two Bite, Chocolate', 56.22); 997 | insert into product (id, name, price) values (997, 'Cake - Mini Potato Pancake', 29.8); 998 | insert into product (id, name, price) values (998, 'Shichimi Togarashi Peppeers', 94.45); 999 | insert into product (id, name, price) values (999, 'Tomatoes - Grape', 20.17); 1000 | insert into product (id, name, price) values (1000, 'Longos - Penne With Pesto', 72.79); 1001 | --------------------------------------------------------------------------------