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
DIFF00000004300
mentioned_in_comment
Python
transactions_735.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE tickets RENAME COLUMN score TO amount_cents; -- now deprecated"""
ALTER_RENAME
false
DIFF00000004301
general_code_change
JavaScript
customers_457.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004302
obfuscated_destructive
SQL
payments_543.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE refunds DROP COLUMN user_id;
DROP_COLUMN
true
DIFF00000004303
test_suite_cleanup
SQL
test/payments_770.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE events;
TRUNCATE
false
DIFF00000004304
raw_sql_destructive
SQL
shipments_213.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM users;
DELETE_UNQUALIFIED
true
DIFF00000004305
test_suite_cleanup
SQL
mysql-test/suite/comments_361.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM shipments;
DELETE_UNQUALIFIED
false
DIFF00000004306
raw_sql_safe
SQL
tickets_136.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_notifications_category ON notifications (priority);
NONE
false
DIFF00000004307
obfuscated_destructive
SQL
customers_93.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE comments RENAME COLUMN is_active TO amount_cents;
ALTER_RENAME
true
DIFF00000004308
obfuscated_destructive
SQL
tickets_169.sql
schema cleanup
@@ -1,3 +1,3 @@ +delete from accounts;
DELETE_UNQUALIFIED
true
DIFF00000004309
raw_sql_safe
SQL
employees_250.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO customers (metadata, name) VALUES (%s, %s);
NONE
false
DIFF00000004310
test_suite_cleanup
SQL
spec/logs_36.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE refunds;
TRUNCATE
false
DIFF00000004311
mentioned_in_comment
Python
payments_531.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DROP TABLE reviews;")
DROP_TABLE
false
DIFF00000004312
orm_schema_change
Python
accounts_710.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='refunds', name='name')
NONE
true
DIFF00000004313
general_code_change
JavaScript
reviews_760.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
DIFF00000004314
general_code_change
JavaScript
reviews_619.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004315
obfuscated_destructive
SQL
accounts_426.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM sessions;
DELETE_UNQUALIFIED
true
DIFF00000004316
general_code_change
Java
orders_629.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000004317
mentioned_in_comment
Python
transactions_173.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DROP TABLE notifications; -- now deprecated"""
DROP_TABLE
false
DIFF00000004318
raw_sql_destructive
SQL
events_85.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE users SET user_id = CONCAT(user_id, email);
UPDATE_CONCAT
true
DIFF00000004319
mentioned_in_comment
Python
products_27.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE inventory RENAME COLUMN metadata TO contact_email; -- now deprecated"""
ALTER_RENAME
false
DIFF00000004320
orm_schema_change
Ruby
orders_709.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :subscriptions, :address
NONE
true
DIFF00000004321
raw_sql_destructive
SQL
shipments_504.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE logs;
TRUNCATE
true
DIFF00000004322
orm_schema_change
JavaScript
payments_565.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('orders', table => table.dropColumn('amount'))
NONE
true
DIFF00000004323
general_code_change
Python
notifications_147.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004324
obfuscated_destructive
SQL
refunds_576.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE reviews;
TRUNCATE
true
DIFF00000004325
raw_sql_safe
SQL
employees_435.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_events_order_id ON events (phone);
NONE
false
DIFF00000004326
orm_schema_change
Ruby
accounts_97.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :users, :address
NONE
true
DIFF00000004327
orm_schema_change
JavaScript
inventory_534.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('events', 'status')
NONE
true
DIFF00000004328
test_suite_cleanup
SQL
spec/inventory_545.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE shipments DROP COLUMN score;
DROP_COLUMN
false
DIFF00000004329
general_code_change
JavaScript
payments_76.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
DIFF00000004330
obfuscated_destructive
SQL
refunds_522.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP tablE reViewS;
DROP_TABLE
true
DIFF00000004331
raw_sql_destructive
SQL
inventory_85.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE reviews;
TRUNCATE
true
DIFF00000004332
mentioned_in_comment
Python
logs_297.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'UPDATE users SET order_id = CONCAT(order_id, is_active);' manually, handled by migration tool
UPDATE_CONCAT
false
DIFF00000004333
raw_sql_safe
SQL
subscriptions_132.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM events WHERE phone = 'active';
NONE
false
DIFF00000004334
test_suite_cleanup
SQL
test/comments_705.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE employees DROP COLUMN order_id;
DROP_COLUMN
false
DIFF00000004335
obfuscated_destructive
SQL
transactions_312.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE reviews RENAME COLUMN status TO contact_email;
ALTER_RENAME
true
DIFF00000004336
raw_sql_safe
SQL
shipments_557.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO subscriptions (status, category) VALUES (%s, %s);
NONE
false
DIFF00000004337
orm_schema_change
Ruby
events_219.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :transactions, :category
NONE
true
DIFF00000004338
orm_schema_change
JavaScript
shipments_23.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('tickets', 'address')
NONE
true
DIFF00000004339
raw_sql_safe
SQL
products_27.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_invoices_metadata ON invoices (metadata);
NONE
false
DIFF00000004340
mentioned_in_comment
Python
events_612.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: UPDATE shipments SET user_id = CONCAT(user_id, phone);")
UPDATE_CONCAT
false
DIFF00000004341
raw_sql_safe
SQL
tickets_184.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE orders ADD COLUMN contact_email VARCHAR(255);
NONE
false
DIFF00000004342
mentioned_in_comment
Python
tickets_215.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'TRUNCATE TABLE transactions;' manually, handled by migration tool
TRUNCATE
false
DIFF00000004343
mentioned_in_comment
Python
sessions_169.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE accounts DROP COLUMN priority;")
DROP_COLUMN
false
DIFF00000004344
raw_sql_destructive
SQL
employees_704.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM tickets;
DELETE_UNQUALIFIED
true
DIFF00000004345
orm_schema_change
Ruby
comments_62.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :shipments, :is_active
NONE
true
DIFF00000004346
mentioned_in_comment
Python
sessions_811.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DELETE FROM comments; -- now deprecated"""
DELETE_UNQUALIFIED
false
DIFF00000004347
raw_sql_safe
SQL
accounts_525.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE events SET price = %s WHERE email = %s;
NONE
false
DIFF00000004348
general_code_change
Python
products_75.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004349
raw_sql_destructive
SQL
invoices_626.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE users SET created_at = CONCAT(created_at, category);
UPDATE_CONCAT
true
DIFF00000004350
general_code_change
JavaScript
subscriptions_787.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
DIFF00000004351
raw_sql_destructive
SQL
orders_81.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE logs;
TRUNCATE
true
DIFF00000004352
raw_sql_destructive
SQL
products_156.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE transactions SET phone = CONCAT(phone, quantity);
UPDATE_CONCAT
true
DIFF00000004353
general_code_change
Python
products_702.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004354
general_code_change
JavaScript
customers_195.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004355
general_code_change
TypeScript
users_850.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
DIFF00000004356
test_suite_cleanup
SQL
spec/customers_319.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions RENAME COLUMN price TO amount_cents;
ALTER_RENAME
false
DIFF00000004357
general_code_change
Java
reviews_52.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000004358
orm_schema_change
Python
logs_94.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='comments', name='created_at')
NONE
true
DIFF00000004359
orm_schema_change
JavaScript
invoices_909.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('invoices', table => table.dropColumn('address'))
NONE
true
DIFF00000004360
orm_schema_change
TypeScript
orders_196.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Orders { // removed field: role }
NONE
true
DIFF00000004361
raw_sql_destructive
SQL
invoices_335.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE reviews DROP COLUMN order_id;
DROP_COLUMN
true
DIFF00000004362
general_code_change
Python
comments_929.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004363
general_code_change
Ruby
orders_107.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004364
orm_schema_change
JavaScript
sessions_550.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('transactions', 'address')
NONE
true
DIFF00000004365
test_suite_cleanup
SQL
tests/logs_536.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE reviews DROP COLUMN quantity;
DROP_COLUMN
false
DIFF00000004366
general_code_change
Python
shipments_844.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004367
raw_sql_destructive
SQL
sessions_224.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM events;
DELETE_UNQUALIFIED
true
DIFF00000004368
orm_schema_change
JavaScript
inventory_46.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('refunds', 'description')
NONE
true
DIFF00000004369
general_code_change
JavaScript
employees_226.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004370
general_code_change
Python
notifications_868.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004371
general_code_change
JavaScript
orders_11.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004372
raw_sql_destructive
SQL
logs_516.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE logs DROP COLUMN role;
DROP_COLUMN
true
DIFF00000004373
obfuscated_destructive
SQL
invoices_3.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE accounts DROP COLUMN order_id;
DROP_COLUMN
true
DIFF00000004374
obfuscated_destructive
SQL
sessions_559.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM tickets;
DELETE_UNQUALIFIED
true
DIFF00000004375
raw_sql_destructive
SQL
tickets_257.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM subscriptions;
DELETE_UNQUALIFIED
true
DIFF00000004376
test_suite_cleanup
SQL
tests/reviews_879.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE payments RENAME COLUMN email TO amount_cents;
ALTER_RENAME
false
DIFF00000004377
orm_schema_change
JavaScript
orders_703.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('notifications', 'description')
NONE
true
DIFF00000004378
general_code_change
Python
employees_806.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004379
general_code_change
TypeScript
accounts_634.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
DIFF00000004380
general_code_change
TypeScript
payments_268.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
DIFF00000004381
orm_schema_change
TypeScript
invoices_886.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Users { // removed field: user_id }
NONE
true
DIFF00000004382
mentioned_in_comment
Python
users_739.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE transactions RENAME COLUMN address TO state;")
ALTER_RENAME
false
DIFF00000004383
test_suite_cleanup
SQL
mysql-test/suite/transactions_641.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE logs SET is_active = CONCAT(is_active, name);
UPDATE_CONCAT
false
DIFF00000004384
raw_sql_destructive
SQL
products_744.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE shipments RENAME COLUMN order_id TO state;
ALTER_RENAME
true
DIFF00000004385
raw_sql_destructive
SQL
payments_202.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE orders;
DROP_TABLE
true
DIFF00000004386
mentioned_in_comment
Python
events_216.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE customers DROP COLUMN created_at;' manually, handled by migration tool
DROP_COLUMN
false
DIFF00000004387
general_code_change
JavaScript
inventory_301.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004388
general_code_change
JavaScript
subscriptions_508.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
DIFF00000004389
orm_schema_change
Ruby
employees_945.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :users, :email
NONE
true
DIFF00000004390
test_suite_cleanup
SQL
tests/orders_683.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE users RENAME COLUMN balance TO contact_email;
ALTER_RENAME
false
DIFF00000004391
raw_sql_safe
SQL
reviews_168.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO payments (order_id, address) VALUES (%s, %s);
NONE
false
DIFF00000004392
raw_sql_safe
SQL
orders_472.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_payments_name ON payments (updated_at);
NONE
false
DIFF00000004393
raw_sql_safe
SQL
accounts_463.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO customers (name, status) VALUES (%s, %s);
NONE
false
DIFF00000004394
general_code_change
JavaScript
users_433.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
DIFF00000004395
raw_sql_destructive
SQL
comments_656.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM tickets;
DELETE_UNQUALIFIED
true
DIFF00000004396
raw_sql_destructive
SQL
refunds_932.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE refunds RENAME COLUMN name TO state;
ALTER_RENAME
true
DIFF00000004397
raw_sql_safe
SQL
sessions_615.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM refunds WHERE quantity = 'active';
NONE
false
DIFF00000004398
general_code_change
Java
products_78.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000004399
raw_sql_destructive
SQL
invoices_436.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE reviews DROP COLUMN created_at;
DROP_COLUMN
true