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
DIFF00099994500
mentioned_in_comment
Python
orders_125.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE notifications DROP COLUMN amount;' manually, handled by migration tool
DROP_COLUMN
false
DIFF00099994501
general_code_change
Go
accounts_405.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099994502
obfuscated_destructive
SQL
comments_919.sql
schema cleanup
@@ -1,3 +1,3 @@ +truncate table comments;
TRUNCATE
true
DIFF00099994503
raw_sql_destructive
SQL
transactions_578.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE users DROP COLUMN amount;
DROP_COLUMN
true
DIFF00099994504
raw_sql_safe
SQL
customers_602.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM orders WHERE is_active = 'active';
NONE
false
DIFF00099994505
raw_sql_destructive
SQL
orders_336.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE invoices;
TRUNCATE
true
DIFF00099994506
general_code_change
TypeScript
employees_940.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
DIFF00099994507
test_suite_cleanup
SQL
spec/reviews_314.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM comments;
DELETE_UNQUALIFIED
false
DIFF00099994508
obfuscated_destructive
SQL
products_499.sql
schema cleanup
@@ -1,3 +1,3 @@ +alter table inventory rename column address to full_name;
ALTER_RENAME
true
DIFF00099994509
orm_schema_change
JavaScript
products_90.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('accounts', table => table.dropColumn('created_at'))
NONE
true
DIFF00099994510
raw_sql_destructive
SQL
accounts_14.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE accounts DROP COLUMN order_id;
DROP_COLUMN
true
DIFF00099994511
orm_schema_change
TypeScript
subscriptions_596.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Transactions { // removed field: description }
NONE
true
DIFF00099994512
test_suite_cleanup
SQL
spec/notifications_967.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE products RENAME COLUMN category TO state;
ALTER_RENAME
false
DIFF00099994513
orm_schema_change
JavaScript
comments_256.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('sessions', table => table.dropColumn('quantity'))
NONE
true
DIFF00099994514
general_code_change
Go
employees_711.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099994515
orm_schema_change
JavaScript
sessions_111.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('products', 'description')
NONE
true
DIFF00099994516
raw_sql_destructive
SQL
payments_977.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM tickets;
DELETE_UNQUALIFIED
true
DIFF00099994517
test_suite_cleanup
SQL
mysql-test/suite/invoices_272.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE refunds;
TRUNCATE
false
DIFF00099994518
orm_schema_change
TypeScript
reviews_74.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Payments { // removed field: category }
NONE
true
DIFF00099994519
raw_sql_destructive
SQL
products_781.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE shipments;
DROP_TABLE
true
DIFF00099994520
obfuscated_destructive
SQL
comments_703.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM events;
DELETE_UNQUALIFIED
true
DIFF00099994521
raw_sql_safe
SQL
refunds_340.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM refunds WHERE score = 'active';
NONE
false
DIFF00099994522
orm_schema_change
JavaScript
shipments_53.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('subscriptions', table => table.dropColumn('is_active'))
NONE
true
DIFF00099994523
general_code_change
JavaScript
tickets_858.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
DIFF00099994524
orm_schema_change
Ruby
employees_921.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :refunds, :email
NONE
true
DIFF00099994525
obfuscated_destructive
SQL
tickets_178.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPDATE shipments SET address = CONCAT(address, amount);
UPDATE_CONCAT
true
DIFF00099994526
general_code_change
TypeScript
users_782.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
DIFF00099994527
orm_schema_change
Python
payments_783.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='notifications', name='order_id')
NONE
true
DIFF00099994528
test_suite_cleanup
SQL
test/comments_732.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM payments;
DELETE_UNQUALIFIED
false
DIFF00099994529
mentioned_in_comment
Python
orders_499.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE subscriptions DROP COLUMN score;")
DROP_COLUMN
false
DIFF00099994530
general_code_change
JavaScript
products_69.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
DIFF00099994531
raw_sql_destructive
SQL
accounts_885.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE sessions RENAME COLUMN metadata TO state;
ALTER_RENAME
true
DIFF00099994532
raw_sql_destructive
SQL
transactions_901.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE customers DROP COLUMN status;
DROP_COLUMN
true
DIFF00099994533
orm_schema_change
TypeScript
orders_224.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Refunds { // removed field: created_at }
NONE
true
DIFF00099994534
general_code_change
Python
inventory_455.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099994535
orm_schema_change
JavaScript
employees_178.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('inventory', 'description')
NONE
true
DIFF00099994536
obfuscated_destructive
SQL
invoices_408.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE logs RENAME COLUMN role TO full_name;
ALTER_RENAME
true
DIFF00099994537
obfuscated_destructive
SQL
orders_692.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE customers DROP COLUMN price;
DROP_COLUMN
true
DIFF00099994538
general_code_change
JavaScript
logs_31.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
DIFF00099994539
orm_schema_change
Ruby
comments_362.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :notifications, :category
NONE
true
DIFF00099994540
general_code_change
Python
payments_718.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099994541
test_suite_cleanup
SQL
mysql-test/suite/employees_925.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE invoices SET description = CONCAT(description, priority);
UPDATE_CONCAT
false
DIFF00099994542
raw_sql_destructive
SQL
transactions_753.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM notifications;
DELETE_UNQUALIFIED
true
DIFF00099994543
mentioned_in_comment
Python
users_1.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DELETE FROM users;")
DELETE_UNQUALIFIED
false
DIFF00099994544
raw_sql_destructive
SQL
sessions_96.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE payments RENAME COLUMN category TO contact_email;
ALTER_RENAME
true
DIFF00099994545
general_code_change
Go
employees_900.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099994546
raw_sql_safe
SQL
logs_106.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO subscriptions (quantity, email) VALUES (%s, %s);
NONE
false
DIFF00099994547
obfuscated_destructive
SQL
invoices_287.sql
schema cleanup
@@ -1,3 +1,3 @@ +alter table users drop column email;
DROP_COLUMN
true
DIFF00099994548
orm_schema_change
JavaScript
employees_463.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('products', table => table.dropColumn('status'))
NONE
true
DIFF00099994549
raw_sql_safe
SQL
transactions_261.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_accounts_address ON accounts (is_active);
NONE
false
DIFF00099994550
general_code_change
Python
events_982.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099994551
orm_schema_change
JavaScript
events_838.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('reviews', 'updated_at')
NONE
true
DIFF00099994552
general_code_change
Java
customers_129.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099994553
mentioned_in_comment
Python
inventory_747.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'DELETE FROM sessions;' manually, handled by migration tool
DELETE_UNQUALIFIED
false
DIFF00099994554
raw_sql_safe
SQL
events_268.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO inventory (email, priority) VALUES (%s, %s);
NONE
false
DIFF00099994555
test_suite_cleanup
SQL
tests/products_51.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE employees RENAME COLUMN category TO user_role;
ALTER_RENAME
false
DIFF00099994556
mentioned_in_comment
Python
transactions_473.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE reviews RENAME COLUMN order_id TO amount_cents;' manually, handled by migration tool
ALTER_RENAME
false
DIFF00099994557
raw_sql_safe
SQL
logs_647.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO reviews (is_active, role) VALUES (%s, %s);
NONE
false
DIFF00099994558
general_code_change
JavaScript
orders_248.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
DIFF00099994559
orm_schema_change
Python
sessions_353.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='logs', name='score')
NONE
true
DIFF00099994560
raw_sql_safe
SQL
subscriptions_498.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM subscriptions WHERE priority = 'active';
NONE
false
DIFF00099994561
general_code_change
Python
accounts_628.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099994562
obfuscated_destructive
SQL
tickets_160.sql
schema cleanup
@@ -1,3 +1,3 @@ +update comments set email = concat(email, is_active);
UPDATE_CONCAT
true
DIFF00099994563
raw_sql_safe
SQL
sessions_356.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE shipments ADD COLUMN full_name VARCHAR(255);
NONE
false
DIFF00099994564
test_suite_cleanup
SQL
mysql-test/suite/transactions_721.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE transactions SET is_active = CONCAT(is_active, email);
UPDATE_CONCAT
false
DIFF00099994565
obfuscated_destructive
SQL
comments_503.sql
schema cleanup
@@ -1,3 +1,3 @@ +TruNCAtE TAblE TRAnSAcTIons;
TRUNCATE
true
DIFF00099994566
orm_schema_change
Ruby
notifications_826.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :notifications, :price
NONE
true
DIFF00099994567
orm_schema_change
JavaScript
logs_453.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('inventory', table => table.dropColumn('address'))
NONE
true
DIFF00099994568
test_suite_cleanup
SQL
tests/logs_229.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE notifications RENAME COLUMN updated_at TO state;
ALTER_RENAME
false
DIFF00099994569
raw_sql_destructive
SQL
tickets_585.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE transactions;
DROP_TABLE
true
DIFF00099994570
test_suite_cleanup
SQL
mysql-test/suite/transactions_743.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM payments;
DELETE_UNQUALIFIED
false
DIFF00099994571
general_code_change
Python
subscriptions_603.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099994572
test_suite_cleanup
SQL
mysql-test/suite/payments_736.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE tickets RENAME COLUMN metadata TO full_name;
ALTER_RENAME
false
DIFF00099994573
orm_schema_change
JavaScript
logs_773.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('inventory', 'metadata')
NONE
true
DIFF00099994574
raw_sql_destructive
SQL
reviews_33.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE customers;
TRUNCATE
true
DIFF00099994575
test_suite_cleanup
SQL
test/events_330.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE refunds DROP COLUMN order_id;
DROP_COLUMN
false
DIFF00099994576
mentioned_in_comment
Python
subscriptions_253.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'DELETE FROM inventory;' manually, handled by migration tool
DELETE_UNQUALIFIED
false
DIFF00099994577
raw_sql_destructive
SQL
products_52.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE sessions SET description = CONCAT(description, phone);
UPDATE_CONCAT
true
DIFF00099994578
raw_sql_destructive
SQL
tickets_871.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE subscriptions SET role = CONCAT(role, user_id);
UPDATE_CONCAT
true
DIFF00099994579
raw_sql_destructive
SQL
accounts_838.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE invoices DROP COLUMN score;
DROP_COLUMN
true
DIFF00099994580
raw_sql_safe
SQL
employees_779.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO payments (name, user_id) VALUES (%s, %s);
NONE
false
DIFF00099994581
obfuscated_destructive
SQL
logs_128.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE transactions;
TRUNCATE
true
DIFF00099994582
orm_schema_change
TypeScript
customers_406.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Orders { // removed field: phone }
NONE
true
DIFF00099994583
general_code_change
Ruby
customers_363.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099994584
raw_sql_safe
SQL
logs_725.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO subscriptions (price, created_at) VALUES (%s, %s);
NONE
false
DIFF00099994585
test_suite_cleanup
SQL
test/sessions_877.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE customers DROP COLUMN balance;
DROP_COLUMN
false
DIFF00099994586
obfuscated_destructive
SQL
refunds_534.sql
schema cleanup
@@ -1,3 +1,3 @@ +delete from users;
DELETE_UNQUALIFIED
true
DIFF00099994587
test_suite_cleanup
SQL
spec/employees_566.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE invoices;
DROP_TABLE
false
DIFF00099994588
raw_sql_safe
SQL
notifications_555.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_payments_name ON payments (priority);
NONE
false
DIFF00099994589
general_code_change
Python
tickets_505.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099994590
obfuscated_destructive
SQL
payments_340.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE tickets;
TRUNCATE
true
DIFF00099994591
orm_schema_change
Python
orders_55.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='transactions', name='metadata')
NONE
true
DIFF00099994592
raw_sql_destructive
SQL
invoices_68.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE subscriptions;
DROP_TABLE
true
DIFF00099994593
raw_sql_safe
SQL
orders_808.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO invoices (metadata, balance) VALUES (%s, %s);
NONE
false
DIFF00099994594
raw_sql_safe
SQL
customers_661.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE products SET price = %s WHERE updated_at = %s;
NONE
false
DIFF00099994595
orm_schema_change
TypeScript
tickets_594.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Sessions { // removed field: role }
NONE
true
DIFF00099994596
general_code_change
JavaScript
payments_629.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099994597
general_code_change
Python
accounts_589.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099994598
raw_sql_safe
SQL
inventory_940.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_events_status ON events (amount);
NONE
false
DIFF00099994599
orm_schema_change
JavaScript
customers_712.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('customers', table => table.dropColumn('category'))
NONE
true