##Instruction:
Database: debit_card_specializing
Total Tables: 5
Total Columns: 21

Table Schemas:

Database: debit_card_specializing
Total Tables: 5
Total Columns: 21

Table Schemas:

Table: customers (3 columns)
----------------------------
• CustomerID (integer): identification of the customer
• Segment (text): client segment
• Currency (text): Currency

Table: gasstations (4 columns)
------------------------------
• GasStationID (integer): Gas Station ID
• ChainID (integer): Chain ID
• Country (text)
• Segment (text): chain segment

Table: products (2 columns)
---------------------------
• ProductID (integer): Product ID
• Description (text): Description

Table: transactions_1k (9 columns)
----------------------------------
• TransactionID (integer): Transaction ID
• Date (date): Date
• Time (text): Time
• CustomerID (integer): Customer ID
• CardID (integer): Card ID
• GasStationID (integer): Gas Station ID
• ProductID (integer): Product ID
• Amount (integer): Amount
• Price (real): Price
  Values: commonsense evidence:

total price = Amount x Price

Table: yearmonth (3 columns)
----------------------------
• CustomerID (integer): Customer ID
• Date (text): Date
• Consumption (real): consumption

##Evidence:
Increase or Decrease = consumption for 2013 - consumption for 2012; Percentage of Increase = (Increase or Decrease / consumption for 2012) * 100%; The first 4 strings of the Date values in the yearmonth table can represent year;

##Role Access Policy (Column-Level):
Role: MarketingSpecialist
Accessible Columns: customers: CustomerID, Segment, Currency; yearmonth: CustomerID, Date, Consumption; transactions_1k: CustomerID, Date, ProductID; products: ProductID, Description

Based on the above schema and your role's column-level access policy, generate a SQL query to answer the question. If your role does not have access to the required columns, respond with: "Sorry, I cannot answer."


Question: Which of the three segments—SME, LAM and KAM—has the biggest and lowest percentage increases in consumption paid in EUR between 2012 and 2013?
Evidence: Increase or Decrease = consumption for 2013 - consumption for 2012; Percentage of Increase = (Increase or Decrease / consumption for 2012) * 100%; The first 4 strings of the Date values in the yearmonth table can represent year;
Answer: SELECT CAST((SUM(IIF(T1.Segment = 'SME' AND T2.Date LIKE '2013%', T2.Consumption, 0)) - SUM(IIF(T1.Segment = 'SME' AND T2.Date LIKE '2012%', T2.Consumption, 0))) AS FLOAT) * 100 / NULLIF(SUM(IIF(T1.Segment = 'SME' AND T2.Date LIKE '2012%', T2.Consumption, 0)), 0) AS SME_Percentage, CAST((SUM(IIF(T1.Segment = 'LAM' AND T2.Date LIKE '2013%', T2.Consumption, 0)) - SUM(IIF(T1.Segment = 'LAM' AND T2.Date LIKE '2012%', T2.Consumption, 0))) AS FLOAT) * 100 / NULLIF(SUM(IIF(T1.Segment = 'LAM' AND T2.Date LIKE '2012%', T2.Consumption, 0)), 0) AS LAM_Percentage, CAST((SUM(IIF(T1.Segment = 'KAM' AND T2.Date LIKE '2013%', T2.Consumption, 0)) - SUM(IIF(T1.Segment = 'KAM' AND T2.Date LIKE '2012%', T2.Consumption, 0))) AS FLOAT) * 100 / NULLIF(SUM(IIF(T1.Segment = 'KAM' AND T2.Date LIKE '2012%', T2.Consumption, 0)), 0) AS KAM_Percentage FROM customers AS T1 INNER JOIN yearmonth AS T2 ON T1.CustomerID = T2.CustomerID WHERE T1.Currency = 'EUR'
Permission: allowed (All required columns are permitted)
Gold SQL: SELECT CAST((SUM(IIF(T1.Segment = 'SME' AND T2.Date LIKE '2013%', T2.Consumption, 0)) - SUM(IIF(T1.Segment = 'SME' AND T2.Date LIKE '2012%', T2.Consumption, 0))) AS FLOAT) * 100 / NULLIF(SUM(IIF(T1.Segment = 'SME' AND T2.Date LIKE '2012%', T2.Consumption, 0)), 0) AS SME_Percentage, CAST((SUM(IIF(T1.Segment = 'LAM' AND T2.Date LIKE '2013%', T2.Consumption, 0)) - SUM(IIF(T1.Segment = 'LAM' AND T2.Date LIKE '2012%', T2.Consumption, 0))) AS FLOAT) * 100 / NULLIF(SUM(IIF(T1.Segment = 'LAM' AND T2.Date LIKE '2012%', T2.Consumption, 0)), 0) AS LAM_Percentage, CAST((SUM(IIF(T1.Segment = 'KAM' AND T2.Date LIKE '2013%', T2.Consumption, 0)) - SUM(IIF(T1.Segment = 'KAM' AND T2.Date LIKE '2012%', T2.Consumption, 0))) AS FLOAT) * 100 / NULLIF(SUM(IIF(T1.Segment = 'KAM' AND T2.Date LIKE '2012%', T2.Consumption, 0)), 0) AS KAM_Percentage FROM customers AS T1 INNER JOIN yearmonth AS T2 ON T1.CustomerID = T2.CustomerID WHERE T1.Currency = 'EUR'