diff_id
stringlengths
15
35
change_category
stringclasses
7 values
language
stringclasses
7 values
file_path
stringlengths
9
38
commit_message
stringclasses
11 values
diff_text
stringlengths
33
146
sql_pattern
stringclasses
7 values
is_destructive_ground_truth
bool
2 classes
DIFF00099993400
raw_sql_safe
SQL
transactions_263.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO reviews (email, name) VALUES (%s, %s);
NONE
false
DIFF00099993401
general_code_change
Ruby
payments_447.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099993402
test_suite_cleanup
SQL
mysql-test/suite/reviews_23.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE shipments RENAME COLUMN category TO contact_email;
ALTER_RENAME
false
DIFF00099993403
obfuscated_destructive
SQL
subscriptions_158.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE products RENAME COLUMN score TO full_name;
ALTER_RENAME
true
DIFF00099993404
obfuscated_destructive
SQL
users_972.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALtER TAblE sUbSCRiPTiOnS RENaMe coluMN orDer_ID tO cONtact_eMaiL;
ALTER_RENAME
true
DIFF00099993405
general_code_change
Java
accounts_374.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099993406
obfuscated_destructive
SQL
subscriptions_852.sql
schema cleanup
@@ -1,3 +1,3 @@ +dELETe FrOm paYMeNts;
DELETE_UNQUALIFIED
true
DIFF00099993407
orm_schema_change
TypeScript
employees_229.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Employees { // removed field: priority }
NONE
true
DIFF00099993408
mentioned_in_comment
Python
products_624.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'DELETE FROM products;' manually, handled by migration tool
DELETE_UNQUALIFIED
false
DIFF00099993409
orm_schema_change
Ruby
accounts_691.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :logs, :role
NONE
true
DIFF00099993410
mentioned_in_comment
Python
customers_913.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE invoices RENAME COLUMN priority TO state;")
ALTER_RENAME
false
DIFF00099993411
raw_sql_safe
SQL
accounts_637.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO events (description, name) VALUES (%s, %s);
NONE
false
DIFF00099993412
general_code_change
JavaScript
shipments_913.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099993413
general_code_change
JavaScript
logs_616.js
refactor / feature work
@@ -1,3 +1,3 @@ +const debounce = (fn, ms) => { let t; return (...a) => { clearTimeout(t); t = setTimeout(() => fn(...a), ms); }; };
NONE
false
DIFF00099993414
mentioned_in_comment
Python
orders_929.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DROP TABLE employees; -- now deprecated"""
DROP_TABLE
false
DIFF00099993415
mentioned_in_comment
Python
subscriptions_390.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE shipments DROP COLUMN order_id;")
DROP_COLUMN
false
DIFF00099993416
obfuscated_destructive
SQL
accounts_857.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPDATE events SET order_id = CONCAT(order_id, amount);
UPDATE_CONCAT
true
DIFF00099993417
raw_sql_destructive
SQL
transactions_301.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM invoices;
DELETE_UNQUALIFIED
true
DIFF00099993418
orm_schema_change
Ruby
reviews_282.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :accounts, :status
NONE
true
DIFF00099993419
general_code_change
JavaScript
accounts_943.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099993420
orm_schema_change
TypeScript
invoices_291.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Subscriptions { // removed field: order_id }
NONE
true
DIFF00099993421
raw_sql_safe
SQL
inventory_862.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE sessions SET is_active = %s WHERE description = %s;
NONE
false
DIFF00099993422
raw_sql_safe
SQL
orders_809.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_comments_created_at ON comments (name);
NONE
false
DIFF00099993423
test_suite_cleanup
SQL
spec/users_433.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM orders;
DELETE_UNQUALIFIED
false
DIFF00099993424
raw_sql_destructive
SQL
comments_733.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE invoices;
TRUNCATE
true
DIFF00099993425
obfuscated_destructive
SQL
transactions_279.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALtEr tablE SESsIoNs dROP coLUMn uPDateD_AT;
DROP_COLUMN
true
DIFF00099993426
general_code_change
Java
logs_653.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099993427
general_code_change
TypeScript
tickets_542.ts
refactor / feature work
@@ -1,3 +1,3 @@ +export function toTitleCase(s: string): string { return s.replace(/\w\S*/g, t => t[0].toUpperCase() + t.slice(1)); }
NONE
false
DIFF00099993428
raw_sql_safe
SQL
employees_256.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM logs WHERE order_id = 'active';
NONE
false
DIFF00099993429
orm_schema_change
TypeScript
refunds_310.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Accounts { // removed field: order_id }
NONE
true
DIFF00099993430
raw_sql_safe
SQL
users_440.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_refunds_balance ON refunds (phone);
NONE
false
DIFF00099993431
general_code_change
Python
sessions_493.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099993432
general_code_change
Ruby
customers_118.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099993433
raw_sql_safe
SQL
customers_678.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE sessions SET description = %s WHERE phone = %s;
NONE
false
DIFF00099993434
general_code_change
JavaScript
events_269.js
refactor / feature work
@@ -1,3 +1,3 @@ +const debounce = (fn, ms) => { let t; return (...a) => { clearTimeout(t); t = setTimeout(() => fn(...a), ms); }; };
NONE
false
DIFF00099993435
raw_sql_destructive
SQL
transactions_472.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE accounts SET status = CONCAT(status, role);
UPDATE_CONCAT
true
DIFF00099993436
general_code_change
Python
logs_68.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099993437
test_suite_cleanup
SQL
spec/tickets_499.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE logs;
DROP_TABLE
false
DIFF00099993438
general_code_change
Python
inventory_350.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993439
orm_schema_change
JavaScript
payments_724.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('orders', 'email')
NONE
true
DIFF00099993440
mentioned_in_comment
Python
tickets_355.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DROP TABLE sessions; -- now deprecated"""
DROP_TABLE
false
DIFF00099993441
raw_sql_safe
SQL
customers_341.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE customers ADD COLUMN state VARCHAR(255);
NONE
false
DIFF00099993442
raw_sql_safe
SQL
employees_179.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM reviews WHERE quantity = 'active';
NONE
false
DIFF00099993443
general_code_change
JavaScript
logs_488.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099993444
orm_schema_change
JavaScript
sessions_515.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('refunds', table => table.dropColumn('address'))
NONE
true
DIFF00099993445
general_code_change
JavaScript
logs_382.js
refactor / feature work
@@ -1,3 +1,3 @@ +const debounce = (fn, ms) => { let t; return (...a) => { clearTimeout(t); t = setTimeout(() => fn(...a), ms); }; };
NONE
false
DIFF00099993446
general_code_change
JavaScript
transactions_522.js
refactor / feature work
@@ -1,3 +1,3 @@ +const debounce = (fn, ms) => { let t; return (...a) => { clearTimeout(t); t = setTimeout(() => fn(...a), ms); }; };
NONE
false
DIFF00099993447
obfuscated_destructive
SQL
events_571.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPDATE comments SET role = CONCAT(role, role);
UPDATE_CONCAT
true
DIFF00099993448
obfuscated_destructive
SQL
reviews_418.sql
schema cleanup
@@ -1,3 +1,3 @@ +upDAte ShIPmeNtS Set qUANTity = cOnCAt(qUantitY, ScOre);
UPDATE_CONCAT
true
DIFF00099993449
general_code_change
Python
reviews_471.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993450
raw_sql_destructive
SQL
events_366.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE orders;
DROP_TABLE
true
DIFF00099993451
general_code_change
Python
sessions_747.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993452
obfuscated_destructive
SQL
employees_564.sql
schema cleanup
@@ -1,3 +1,3 @@ +DelETE FROM nOtIfiCatiONS;
DELETE_UNQUALIFIED
true
DIFF00099993453
raw_sql_destructive
SQL
shipments_889.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions DROP COLUMN updated_at;
DROP_COLUMN
true
DIFF00099993454
mentioned_in_comment
Python
shipments_576.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DROP TABLE notifications; -- now deprecated"""
DROP_TABLE
false
DIFF00099993455
raw_sql_safe
SQL
invoices_353.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM customers WHERE quantity = 'active';
NONE
false
DIFF00099993456
orm_schema_change
JavaScript
orders_671.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('subscriptions', 'price')
NONE
true
DIFF00099993457
test_suite_cleanup
SQL
spec/comments_3.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE accounts SET is_active = CONCAT(is_active, email);
UPDATE_CONCAT
false
DIFF00099993458
raw_sql_destructive
SQL
orders_199.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE reviews RENAME COLUMN description TO amount_cents;
ALTER_RENAME
true
DIFF00099993459
test_suite_cleanup
SQL
spec/customers_592.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE orders SET metadata = CONCAT(metadata, category);
UPDATE_CONCAT
false
DIFF00099993460
raw_sql_destructive
SQL
sessions_926.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE reviews;
TRUNCATE
true
DIFF00099993461
general_code_change
Python
events_824.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993462
raw_sql_safe
SQL
subscriptions_97.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO subscriptions (description, category) VALUES (%s, %s);
NONE
false
DIFF00099993463
raw_sql_destructive
SQL
inventory_915.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE payments;
DROP_TABLE
true
DIFF00099993464
test_suite_cleanup
SQL
spec/users_230.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM orders;
DELETE_UNQUALIFIED
false
DIFF00099993465
raw_sql_destructive
SQL
events_331.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE invoices;
TRUNCATE
true
DIFF00099993466
raw_sql_safe
SQL
sessions_285.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM orders WHERE score = 'active';
NONE
false
DIFF00099993467
test_suite_cleanup
SQL
tests/refunds_698.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE inventory;
DROP_TABLE
false
DIFF00099993468
obfuscated_destructive
SQL
inventory_894.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE products DROP COLUMN email;
DROP_COLUMN
true
DIFF00099993469
test_suite_cleanup
SQL
test/customers_335.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE reviews;
DROP_TABLE
false
DIFF00099993470
raw_sql_destructive
SQL
logs_603.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions DROP COLUMN address;
DROP_COLUMN
true
DIFF00099993471
test_suite_cleanup
SQL
test/products_478.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE comments;
TRUNCATE
false
DIFF00099993472
raw_sql_destructive
SQL
reviews_603.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE shipments;
TRUNCATE
true
DIFF00099993473
general_code_change
Python
notifications_894.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993474
orm_schema_change
Ruby
inventory_127.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :events, :amount
NONE
true
DIFF00099993475
mentioned_in_comment
Python
orders_557.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DELETE FROM shipments;")
DELETE_UNQUALIFIED
false
DIFF00099993476
general_code_change
JavaScript
orders_209.js
refactor / feature work
@@ -1,3 +1,3 @@ +const debounce = (fn, ms) => { let t; return (...a) => { clearTimeout(t); t = setTimeout(() => fn(...a), ms); }; };
NONE
false
DIFF00099993477
raw_sql_destructive
SQL
products_63.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE customers DROP COLUMN address;
DROP_COLUMN
true
DIFF00099993478
obfuscated_destructive
SQL
transactions_211.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE products;
TRUNCATE
true
DIFF00099993479
raw_sql_destructive
SQL
accounts_297.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE accounts;
DROP_TABLE
true
DIFF00099993480
orm_schema_change
Python
shipments_864.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='employees', name='price')
NONE
true
DIFF00099993481
raw_sql_destructive
SQL
users_512.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM invoices;
DELETE_UNQUALIFIED
true
DIFF00099993482
general_code_change
Python
employees_162.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099993483
raw_sql_safe
SQL
notifications_292.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO orders (order_id, price) VALUES (%s, %s);
NONE
false
DIFF00099993484
raw_sql_safe
SQL
transactions_968.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO comments (score, score) VALUES (%s, %s);
NONE
false
DIFF00099993485
raw_sql_safe
SQL
employees_99.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO reviews (balance, updated_at) VALUES (%s, %s);
NONE
false
DIFF00099993486
orm_schema_change
JavaScript
tickets_739.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('shipments', 'is_active')
NONE
true
DIFF00099993487
raw_sql_destructive
SQL
reviews_679.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE users;
DROP_TABLE
true
DIFF00099993488
obfuscated_destructive
SQL
notifications_116.sql
schema cleanup
@@ -1,3 +1,3 @@ +dElete FROm cOmMeNts;
DELETE_UNQUALIFIED
true
DIFF00099993489
general_code_change
Java
invoices_45.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099993490
test_suite_cleanup
SQL
tests/employees_733.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE shipments RENAME COLUMN priority TO full_name;
ALTER_RENAME
false
DIFF00099993491
obfuscated_destructive
SQL
refunds_958.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTeR tabLE PayMEnTS DRop COLuMN StaTus;
DROP_COLUMN
true
DIFF00099993492
orm_schema_change
TypeScript
tickets_882.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Invoices { // removed field: metadata }
NONE
true
DIFF00099993493
raw_sql_safe
SQL
employees_325.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE accounts SET metadata = %s WHERE description = %s;
NONE
false
DIFF00099993494
raw_sql_destructive
SQL
subscriptions_456.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE payments SET priority = CONCAT(priority, priority);
UPDATE_CONCAT
true
DIFF00099993495
raw_sql_destructive
SQL
events_975.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE payments RENAME COLUMN score TO state;
ALTER_RENAME
true
DIFF00099993496
raw_sql_safe
SQL
notifications_444.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE employees ADD COLUMN user_role VARCHAR(255);
NONE
false
DIFF00099993497
orm_schema_change
JavaScript
users_350.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('reviews', table => table.dropColumn('order_id'))
NONE
true
DIFF00099993498
raw_sql_destructive
SQL
accounts_570.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE reviews SET created_at = CONCAT(created_at, score);
UPDATE_CONCAT
true
DIFF00099993499
obfuscated_destructive
SQL
customers_60.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPDATE users SET balance = CONCAT(balance, balance);
UPDATE_CONCAT
true