I have a entity, which include product id, price type, as well as id etc. Id is created by autogeration, but product id and price type are different but, you can see them again more time next elemen of list. For insatnce
final productPrices = [
ProductPriceEntity(id: null, priceTypeId: "1", productId: "A", price: 10.0),
ProductPriceEntity(id: null, priceTypeId: "1", productId: "A", price: 12.0),
ProductPriceEntity(id: null, priceTypeId: "2", productId: "A", price: 15.0),
ProductPriceEntity(id: null, priceTypeId: "2", productId: "B", price: 20.0),
];
I can only see one time in floor databse by app inspection in android studion. For example :
final productPrices = [
ProductPriceEntity(id: null, priceTypeId: "1", productId: "A", price: 10.0),
ProductPriceEntity(id: null, priceTypeId: "2", productId: "A", price: 15.0),
];
How can i insert all elements to table . Can you help me?
I have a entity, which include product id, price type, as well as id etc. Id is created by autogeration, but product id and price type are different but, you can see them again more time next elemen of list. For insatnce final productPrices = [ ProductPriceEntity(id: null, priceTypeId: "1", productId: "A", price: 10.0), ProductPriceEntity(id: null, priceTypeId: "1", productId: "A", price: 12.0), ProductPriceEntity(id: null, priceTypeId: "2", productId: "A", price: 15.0), ProductPriceEntity(id: null, priceTypeId: "2", productId: "B", price: 20.0), ]; I can only see one time in floor databse by app inspection in android studion. For example : final productPrices = [ ProductPriceEntity(id: null, priceTypeId: "1", productId: "A", price: 10.0), ProductPriceEntity(id: null, priceTypeId: "2", productId: "A", price: 15.0), ]; How can i insert all elements to table . Can you help me?