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
DIFF00099995300
test_suite_cleanup
SQL
mysql-test/suite/transactions_508.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE customers;
DROP_TABLE
false
DIFF00099995301
general_code_change
TypeScript
subscriptions_541.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
DIFF00099995302
general_code_change
Python
tickets_277.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995303
general_code_change
JavaScript
logs_369.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099995304
general_code_change
Go
inventory_136.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099995305
orm_schema_change
TypeScript
shipments_156.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Notifications { // removed field: amount }
NONE
true
DIFF00099995306
general_code_change
Java
events_895.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099995307
raw_sql_safe
SQL
invoices_490.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE events ADD COLUMN amount_cents VARCHAR(255);
NONE
false
DIFF00099995308
general_code_change
Python
sessions_167.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995309
raw_sql_safe
SQL
comments_106.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO products (email, priority) VALUES (%s, %s);
NONE
false
DIFF00099995310
orm_schema_change
JavaScript
payments_245.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('invoices', table => table.dropColumn('created_at'))
NONE
true
DIFF00099995311
mentioned_in_comment
Python
accounts_160.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE tickets DROP COLUMN status;")
DROP_COLUMN
false
DIFF00099995312
test_suite_cleanup
SQL
tests/comments_738.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE logs DROP COLUMN status;
DROP_COLUMN
false
DIFF00099995313
test_suite_cleanup
SQL
spec/comments_916.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE invoices;
TRUNCATE
false
DIFF00099995314
orm_schema_change
JavaScript
tickets_996.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('accounts', table => table.dropColumn('score'))
NONE
true
DIFF00099995315
obfuscated_destructive
SQL
invoices_537.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE orders;
DROP_TABLE
true
DIFF00099995316
general_code_change
Python
payments_90.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995317
test_suite_cleanup
SQL
test/products_928.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE customers RENAME COLUMN phone TO amount_cents;
ALTER_RENAME
false
DIFF00099995318
general_code_change
Python
comments_688.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995319
general_code_change
JavaScript
customers_422.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099995320
orm_schema_change
JavaScript
customers_756.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('comments', 'address')
NONE
true
DIFF00099995321
raw_sql_destructive
SQL
inventory_443.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE payments;
DROP_TABLE
true
DIFF00099995322
general_code_change
Python
users_173.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995323
raw_sql_safe
SQL
reviews_452.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM payments WHERE priority = 'active';
NONE
false
DIFF00099995324
mentioned_in_comment
Python
users_74.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'DROP TABLE comments;' manually, handled by migration tool
DROP_TABLE
false
DIFF00099995325
orm_schema_change
Ruby
transactions_399.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :logs, :amount
NONE
true
DIFF00099995326
raw_sql_destructive
SQL
reviews_925.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM shipments;
DELETE_UNQUALIFIED
true
DIFF00099995327
obfuscated_destructive
SQL
users_155.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE events DROP COLUMN metadata;
DROP_COLUMN
true
DIFF00099995328
mentioned_in_comment
Python
invoices_782.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DELETE FROM logs; -- now deprecated"""
DELETE_UNQUALIFIED
false
DIFF00099995329
orm_schema_change
JavaScript
users_618.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('sessions', table => table.dropColumn('balance'))
NONE
true
DIFF00099995330
general_code_change
TypeScript
reviews_565.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
DIFF00099995331
raw_sql_safe
SQL
sessions_573.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE products ADD COLUMN contact_email VARCHAR(255);
NONE
false
DIFF00099995332
mentioned_in_comment
Python
comments_514.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DROP TABLE tickets; -- now deprecated"""
DROP_TABLE
false
DIFF00099995333
raw_sql_safe
SQL
sessions_721.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_orders_phone ON orders (quantity);
NONE
false
DIFF00099995334
general_code_change
Python
shipments_758.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995335
raw_sql_safe
SQL
orders_652.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM refunds WHERE order_id = 'active';
NONE
false
DIFF00099995336
raw_sql_safe
SQL
customers_58.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM invoices WHERE amount = 'active';
NONE
false
DIFF00099995337
orm_schema_change
Ruby
subscriptions_631.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :invoices, :score
NONE
true
DIFF00099995338
general_code_change
Python
comments_898.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099995339
raw_sql_destructive
SQL
tickets_189.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE tickets;
DROP_TABLE
true
DIFF00099995340
raw_sql_destructive
SQL
orders_542.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE sessions SET order_id = CONCAT(order_id, address);
UPDATE_CONCAT
true
DIFF00099995341
general_code_change
Ruby
customers_573.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099995342
raw_sql_destructive
SQL
transactions_178.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM users;
DELETE_UNQUALIFIED
true
DIFF00099995343
general_code_change
Python
events_986.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995344
general_code_change
Java
customers_509.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099995345
test_suite_cleanup
SQL
tests/users_517.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE inventory SET is_active = CONCAT(is_active, phone);
UPDATE_CONCAT
false
DIFF00099995346
mentioned_in_comment
Python
accounts_518.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: TRUNCATE TABLE inventory;")
TRUNCATE
false
DIFF00099995347
raw_sql_safe
SQL
notifications_362.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO customers (user_id, amount) VALUES (%s, %s);
NONE
false
DIFF00099995348
orm_schema_change
JavaScript
accounts_139.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('shipments', 'balance')
NONE
true
DIFF00099995349
raw_sql_destructive
SQL
customers_647.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE transactions;
DROP_TABLE
true
DIFF00099995350
obfuscated_destructive
SQL
notifications_292.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE employees DROP COLUMN amount;
DROP_COLUMN
true
DIFF00099995351
obfuscated_destructive
SQL
invoices_608.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE customers;
DROP_TABLE
true
DIFF00099995352
raw_sql_destructive
SQL
refunds_103.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE events SET metadata = CONCAT(metadata, role);
UPDATE_CONCAT
true
DIFF00099995353
general_code_change
JavaScript
events_68.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
DIFF00099995354
raw_sql_safe
SQL
sessions_926.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE subscriptions SET quantity = %s WHERE category = %s;
NONE
false
DIFF00099995355
general_code_change
Ruby
comments_509.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099995356
mentioned_in_comment
Python
tickets_245.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'UPDATE refunds SET metadata = CONCAT(metadata, score);' manually, handled by migration tool
UPDATE_CONCAT
false
DIFF00099995357
obfuscated_destructive
SQL
invoices_753.sql
schema cleanup
@@ -1,3 +1,3 @@ +alter table customers rename column order_id to user_role;
ALTER_RENAME
true
DIFF00099995358
raw_sql_safe
SQL
refunds_734.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO employees (role, score) VALUES (%s, %s);
NONE
false
DIFF00099995359
obfuscated_destructive
SQL
comments_812.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE events;
TRUNCATE
true
DIFF00099995360
obfuscated_destructive
SQL
sessions_450.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRuncaTE TaBlE sessIons;
TRUNCATE
true
DIFF00099995361
mentioned_in_comment
Python
invoices_719.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE inventory DROP COLUMN created_at;' manually, handled by migration tool
DROP_COLUMN
false
DIFF00099995362
raw_sql_safe
SQL
invoices_98.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM inventory WHERE status = 'active';
NONE
false
DIFF00099995363
test_suite_cleanup
SQL
mysql-test/suite/inventory_366.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE tickets SET user_id = CONCAT(user_id, name);
UPDATE_CONCAT
false
DIFF00099995364
general_code_change
Go
inventory_526.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099995365
raw_sql_destructive
SQL
notifications_824.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE tickets;
TRUNCATE
true
DIFF00099995366
raw_sql_safe
SQL
users_601.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO tickets (address, metadata) VALUES (%s, %s);
NONE
false
DIFF00099995367
mentioned_in_comment
Python
tickets_215.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DELETE FROM users;")
DELETE_UNQUALIFIED
false
DIFF00099995368
obfuscated_destructive
SQL
inventory_255.sql
schema cleanup
@@ -1,3 +1,3 @@ +alter table shipments drop column email;
DROP_COLUMN
true
DIFF00099995369
orm_schema_change
TypeScript
invoices_473.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Sessions { // removed field: created_at }
NONE
true
DIFF00099995370
raw_sql_safe
SQL
accounts_779.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO shipments (priority, is_active) VALUES (%s, %s);
NONE
false
DIFF00099995371
test_suite_cleanup
SQL
mysql-test/suite/logs_344.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE notifications;
DROP_TABLE
false
DIFF00099995372
raw_sql_destructive
SQL
shipments_92.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE customers;
TRUNCATE
true
DIFF00099995373
obfuscated_destructive
SQL
events_742.sql
schema cleanup
@@ -1,3 +1,3 @@ +delete from transactions;
DELETE_UNQUALIFIED
true
DIFF00099995374
test_suite_cleanup
SQL
mysql-test/suite/customers_857.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE users RENAME COLUMN role TO state;
ALTER_RENAME
false
DIFF00099995375
test_suite_cleanup
SQL
spec/inventory_446.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE payments SET category = CONCAT(category, status);
UPDATE_CONCAT
false
DIFF00099995376
obfuscated_destructive
SQL
refunds_366.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE refunds;
TRUNCATE
true
DIFF00099995377
general_code_change
Ruby
refunds_341.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099995378
test_suite_cleanup
SQL
spec/users_61.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE tickets SET order_id = CONCAT(order_id, email);
UPDATE_CONCAT
false
DIFF00099995379
obfuscated_destructive
SQL
invoices_391.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPDATE customers SET quantity = CONCAT(quantity, name);
UPDATE_CONCAT
true
DIFF00099995380
raw_sql_destructive
SQL
sessions_26.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE payments DROP COLUMN score;
DROP_COLUMN
true
DIFF00099995381
general_code_change
JavaScript
payments_932.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099995382
raw_sql_destructive
SQL
comments_416.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE invoices;
TRUNCATE
true
DIFF00099995383
raw_sql_safe
SQL
comments_300.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO customers (name, updated_at) VALUES (%s, %s);
NONE
false
DIFF00099995384
raw_sql_safe
SQL
users_112.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO refunds (quantity, phone) VALUES (%s, %s);
NONE
false
DIFF00099995385
raw_sql_safe
SQL
comments_605.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM shipments WHERE role = 'active';
NONE
false
DIFF00099995386
general_code_change
Go
notifications_905.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099995387
mentioned_in_comment
Python
payments_378.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE subscriptions DROP COLUMN address;' manually, handled by migration tool
DROP_COLUMN
false
DIFF00099995388
raw_sql_safe
SQL
accounts_929.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE events SET balance = %s WHERE priority = %s;
NONE
false
DIFF00099995389
mentioned_in_comment
Python
sessions_650.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DROP TABLE orders;")
DROP_TABLE
false
DIFF00099995390
orm_schema_change
Ruby
transactions_772.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :subscriptions, :updated_at
NONE
true
DIFF00099995391
raw_sql_destructive
SQL
inventory_945.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions DROP COLUMN score;
DROP_COLUMN
true
DIFF00099995392
orm_schema_change
JavaScript
users_532.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('tickets', 'status')
NONE
true
DIFF00099995393
test_suite_cleanup
SQL
tests/shipments_267.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE logs;
TRUNCATE
false
DIFF00099995394
raw_sql_destructive
SQL
refunds_997.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE reviews;
DROP_TABLE
true
DIFF00099995395
mentioned_in_comment
Python
tickets_630.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'DELETE FROM events;' manually, handled by migration tool
DELETE_UNQUALIFIED
false
DIFF00099995396
general_code_change
TypeScript
comments_139.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
DIFF00099995397
orm_schema_change
TypeScript
notifications_177.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Products { // removed field: quantity }
NONE
true
DIFF00099995398
obfuscated_destructive
SQL
payments_416.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE transactions DROP COLUMN description;
DROP_COLUMN
true
DIFF00099995399
obfuscated_destructive
SQL
employees_567.sql
schema cleanup
@@ -1,3 +1,3 @@ +alter table notifications rename column metadata to amount_cents;
ALTER_RENAME
true