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
DIFF00099995700
orm_schema_change
JavaScript
tickets_996.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('products', 'created_at')
NONE
true
DIFF00099995701
orm_schema_change
Ruby
invoices_14.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :orders, :description
NONE
true
DIFF00099995702
test_suite_cleanup
SQL
spec/payments_677.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM orders;
DELETE_UNQUALIFIED
false
DIFF00099995703
raw_sql_safe
SQL
invoices_285.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM notifications WHERE address = 'active';
NONE
false
DIFF00099995704
mentioned_in_comment
Python
users_513.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE subscriptions RENAME COLUMN role TO amount_cents; -- now deprecated"""
ALTER_RENAME
false
DIFF00099995705
orm_schema_change
JavaScript
invoices_220.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('comments', table => table.dropColumn('name'))
NONE
true
DIFF00099995706
raw_sql_safe
SQL
reviews_130.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM payments WHERE updated_at = 'active';
NONE
false
DIFF00099995707
orm_schema_change
Ruby
transactions_349.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :refunds, :created_at
NONE
true
DIFF00099995708
orm_schema_change
Ruby
notifications_244.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :notifications, :balance
NONE
true
DIFF00099995709
general_code_change
Ruby
invoices_700.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099995710
orm_schema_change
Ruby
comments_422.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :logs, :score
NONE
true
DIFF00099995711
raw_sql_safe
SQL
subscriptions_454.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM employees WHERE price = 'active';
NONE
false
DIFF00099995712
general_code_change
Java
products_395.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099995713
raw_sql_destructive
SQL
inventory_919.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM orders;
DELETE_UNQUALIFIED
true
DIFF00099995714
obfuscated_destructive
SQL
payments_349.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPdatE tICKeTS set PRICE = COncat(prIce, PHoNE);
UPDATE_CONCAT
true
DIFF00099995715
general_code_change
JavaScript
users_213.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
DIFF00099995716
test_suite_cleanup
SQL
spec/users_591.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM orders;
DELETE_UNQUALIFIED
false
DIFF00099995717
raw_sql_safe
SQL
employees_121.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE comments ADD COLUMN state VARCHAR(255);
NONE
false
DIFF00099995718
obfuscated_destructive
SQL
comments_803.sql
schema cleanup
@@ -1,3 +1,3 @@ +drop table invoices;
DROP_TABLE
true
DIFF00099995719
test_suite_cleanup
SQL
tests/accounts_411.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE shipments SET phone = CONCAT(phone, user_id);
UPDATE_CONCAT
false
DIFF00099995720
raw_sql_destructive
SQL
inventory_956.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE customers;
DROP_TABLE
true
DIFF00099995721
general_code_change
JavaScript
employees_973.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
DIFF00099995722
mentioned_in_comment
Python
logs_195.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE products RENAME COLUMN role TO amount_cents;' manually, handled by migration tool
ALTER_RENAME
false
DIFF00099995723
raw_sql_destructive
SQL
transactions_362.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE logs;
TRUNCATE
true
DIFF00099995724
obfuscated_destructive
SQL
shipments_530.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE accounts DROP COLUMN role;
DROP_COLUMN
true
DIFF00099995725
mentioned_in_comment
Python
inventory_100.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: UPDATE inventory SET email = CONCAT(email, quantity); -- now deprecated"""
UPDATE_CONCAT
false
DIFF00099995726
general_code_change
Go
subscriptions_142.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099995727
mentioned_in_comment
Python
customers_799.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'UPDATE sessions SET email = CONCAT(email, category);' manually, handled by migration tool
UPDATE_CONCAT
false
DIFF00099995728
general_code_change
Ruby
events_423.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099995729
raw_sql_safe
SQL
invoices_773.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO tickets (balance, status) VALUES (%s, %s);
NONE
false
DIFF00099995730
test_suite_cleanup
SQL
tests/users_622.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE shipments;
DROP_TABLE
false
DIFF00099995731
raw_sql_safe
SQL
orders_259.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE tickets SET quantity = %s WHERE email = %s;
NONE
false
DIFF00099995732
general_code_change
Python
sessions_545.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995733
raw_sql_safe
SQL
invoices_20.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM subscriptions WHERE order_id = 'active';
NONE
false
DIFF00099995734
orm_schema_change
TypeScript
shipments_857.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Payments { // removed field: description }
NONE
true
DIFF00099995735
test_suite_cleanup
SQL
mysql-test/suite/refunds_790.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE comments DROP COLUMN email;
DROP_COLUMN
false
DIFF00099995736
orm_schema_change
Ruby
refunds_943.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :employees, :description
NONE
true
DIFF00099995737
orm_schema_change
Python
subscriptions_877.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='subscriptions', name='is_active')
NONE
true
DIFF00099995738
test_suite_cleanup
SQL
test/reviews_348.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE notifications RENAME COLUMN created_at TO state;
ALTER_RENAME
false
DIFF00099995739
orm_schema_change
JavaScript
sessions_358.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('tickets', 'is_active')
NONE
true
DIFF00099995740
general_code_change
Ruby
notifications_959.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099995741
raw_sql_safe
SQL
sessions_9.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE tickets ADD COLUMN user_role VARCHAR(255);
NONE
false
DIFF00099995742
obfuscated_destructive
SQL
users_642.sql
schema cleanup
@@ -1,3 +1,3 @@ +drop table users;
DROP_TABLE
true
DIFF00099995743
general_code_change
JavaScript
subscriptions_482.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099995744
general_code_change
Java
shipments_118.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099995745
test_suite_cleanup
SQL
mysql-test/suite/comments_719.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE employees DROP COLUMN status;
DROP_COLUMN
false
DIFF00099995746
obfuscated_destructive
SQL
reviews_653.sql
schema cleanup
@@ -1,3 +1,3 @@ +truncate table transactions;
TRUNCATE
true
DIFF00099995747
general_code_change
Python
inventory_686.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099995748
raw_sql_safe
SQL
refunds_268.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE shipments SET phone = %s WHERE updated_at = %s;
NONE
false
DIFF00099995749
raw_sql_safe
SQL
users_391.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM shipments WHERE score = 'active';
NONE
false
DIFF00099995750
test_suite_cleanup
SQL
mysql-test/suite/sessions_167.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE logs SET price = CONCAT(price, role);
UPDATE_CONCAT
false
DIFF00099995751
raw_sql_safe
SQL
orders_83.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE transactions ADD COLUMN user_role VARCHAR(255);
NONE
false
DIFF00099995752
general_code_change
Python
reviews_315.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099995753
test_suite_cleanup
SQL
tests/employees_628.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE logs;
TRUNCATE
false
DIFF00099995754
general_code_change
Java
invoices_400.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099995755
raw_sql_destructive
SQL
subscriptions_464.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE tickets DROP COLUMN metadata;
DROP_COLUMN
true
DIFF00099995756
orm_schema_change
Ruby
invoices_525.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :refunds, :is_active
NONE
true
DIFF00099995757
raw_sql_safe
SQL
notifications_814.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE transactions SET amount = %s WHERE quantity = %s;
NONE
false
DIFF00099995758
raw_sql_safe
SQL
refunds_203.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_customers_price ON customers (order_id);
NONE
false
DIFF00099995759
general_code_change
JavaScript
inventory_668.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099995760
obfuscated_destructive
SQL
products_849.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE inventory DROP COLUMN score;
DROP_COLUMN
true
DIFF00099995761
raw_sql_safe
SQL
comments_418.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO sessions (created_at, user_id) VALUES (%s, %s);
NONE
false
DIFF00099995762
raw_sql_safe
SQL
sessions_800.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM subscriptions WHERE phone = 'active';
NONE
false
DIFF00099995763
orm_schema_change
TypeScript
transactions_627.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Subscriptions { // removed field: order_id }
NONE
true
DIFF00099995764
test_suite_cleanup
SQL
spec/transactions_444.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE accounts;
TRUNCATE
false
DIFF00099995765
general_code_change
Go
notifications_46.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099995766
mentioned_in_comment
Python
customers_334.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE reviews DROP COLUMN amount;' manually, handled by migration tool
DROP_COLUMN
false
DIFF00099995767
test_suite_cleanup
SQL
tests/inventory_750.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE accounts SET quantity = CONCAT(quantity, role);
UPDATE_CONCAT
false
DIFF00099995768
obfuscated_destructive
SQL
events_164.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE payments RENAME COLUMN balance TO full_name;
ALTER_RENAME
true
DIFF00099995769
raw_sql_safe
SQL
refunds_3.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE payments ADD COLUMN amount_cents VARCHAR(255);
NONE
false
DIFF00099995770
orm_schema_change
Python
events_400.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='inventory', name='metadata')
NONE
true
DIFF00099995771
obfuscated_destructive
SQL
employees_964.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE employees;
DROP_TABLE
true
DIFF00099995772
general_code_change
TypeScript
tickets_249.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
DIFF00099995773
test_suite_cleanup
SQL
test/customers_185.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE sessions;
TRUNCATE
false
DIFF00099995774
orm_schema_change
Ruby
products_98.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :shipments, :quantity
NONE
true
DIFF00099995775
general_code_change
Go
refunds_674.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099995776
mentioned_in_comment
Python
orders_53.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DROP TABLE reviews;")
DROP_TABLE
false
DIFF00099995777
test_suite_cleanup
SQL
tests/reviews_125.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE shipments;
DROP_TABLE
false
DIFF00099995778
raw_sql_safe
SQL
products_250.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_comments_order_id ON comments (metadata);
NONE
false
DIFF00099995779
orm_schema_change
TypeScript
reviews_436.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Inventory { // removed field: user_id }
NONE
true
DIFF00099995780
mentioned_in_comment
Python
events_793.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DROP TABLE notifications;")
DROP_TABLE
false
DIFF00099995781
general_code_change
Ruby
tickets_427.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099995782
raw_sql_destructive
SQL
accounts_88.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE logs;
TRUNCATE
true
DIFF00099995783
raw_sql_destructive
SQL
shipments_960.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM events;
DELETE_UNQUALIFIED
true
DIFF00099995784
raw_sql_destructive
SQL
orders_705.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE products RENAME COLUMN status TO full_name;
ALTER_RENAME
true
DIFF00099995785
raw_sql_safe
SQL
tickets_328.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE notifications ADD COLUMN state VARCHAR(255);
NONE
false
DIFF00099995786
raw_sql_safe
SQL
customers_126.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM logs WHERE updated_at = 'active';
NONE
false
DIFF00099995787
raw_sql_destructive
SQL
products_730.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE customers SET role = CONCAT(role, user_id);
UPDATE_CONCAT
true
DIFF00099995788
mentioned_in_comment
Python
payments_533.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE events RENAME COLUMN updated_at TO contact_email;' manually, handled by migration tool
ALTER_RENAME
false
DIFF00099995789
raw_sql_safe
SQL
transactions_470.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE logs SET category = %s WHERE priority = %s;
NONE
false
DIFF00099995790
general_code_change
Python
logs_267.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099995791
general_code_change
TypeScript
orders_964.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
DIFF00099995792
general_code_change
Python
orders_460.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099995793
test_suite_cleanup
SQL
tests/payments_166.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE shipments;
DROP_TABLE
false
DIFF00099995794
orm_schema_change
JavaScript
employees_709.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('employees', 'role')
NONE
true
DIFF00099995795
general_code_change
JavaScript
products_908.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099995796
general_code_change
Python
reviews_200.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099995797
obfuscated_destructive
SQL
events_824.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE transactions RENAME COLUMN created_at TO amount_cents;
ALTER_RENAME
true
DIFF00099995798
raw_sql_destructive
SQL
users_846.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE users SET phone = CONCAT(phone, quantity);
UPDATE_CONCAT
true
DIFF00099995799
raw_sql_safe
SQL
subscriptions_173.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE shipments SET description = %s WHERE updated_at = %s;
NONE
false