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
DIFF00000004700
test_suite_cleanup
SQL
test/accounts_283.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE refunds DROP COLUMN amount;
DROP_COLUMN
false
DIFF00000004701
orm_schema_change
JavaScript
employees_108.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('events', table => table.dropColumn('role'))
NONE
true
DIFF00000004702
raw_sql_safe
SQL
invoices_799.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE reviews ADD COLUMN full_name VARCHAR(255);
NONE
false
DIFF00000004703
orm_schema_change
JavaScript
users_481.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('subscriptions', 'score')
NONE
true
DIFF00000004704
raw_sql_destructive
SQL
comments_168.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE customers;
TRUNCATE
true
DIFF00000004705
obfuscated_destructive
SQL
accounts_673.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM reviews;
DELETE_UNQUALIFIED
true
DIFF00000004706
orm_schema_change
JavaScript
subscriptions_513.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('invoices', table => table.dropColumn('amount'))
NONE
true
DIFF00000004707
general_code_change
JavaScript
inventory_872.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
DIFF00000004708
general_code_change
Python
transactions_927.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004709
general_code_change
Python
transactions_301.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004710
general_code_change
TypeScript
comments_482.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
DIFF00000004711
raw_sql_safe
SQL
products_36.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM customers WHERE order_id = 'active';
NONE
false
DIFF00000004712
obfuscated_destructive
SQL
notifications_82.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE invoices;
DROP_TABLE
true
DIFF00000004713
obfuscated_destructive
SQL
logs_488.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELetE fROm reFunds;
DELETE_UNQUALIFIED
true
DIFF00000004714
general_code_change
Ruby
notifications_678.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004715
raw_sql_safe
SQL
reviews_908.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO customers (order_id, updated_at) VALUES (%s, %s);
NONE
false
DIFF00000004716
raw_sql_destructive
SQL
shipments_470.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE shipments;
DROP_TABLE
true
DIFF00000004717
general_code_change
TypeScript
reviews_339.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
DIFF00000004718
orm_schema_change
JavaScript
reviews_505.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('inventory', table => table.dropColumn('status'))
NONE
true
DIFF00000004719
raw_sql_safe
SQL
shipments_943.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE transactions ADD COLUMN full_name VARCHAR(255);
NONE
false
DIFF00000004720
raw_sql_safe
SQL
invoices_631.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE inventory SET address = %s WHERE role = %s;
NONE
false
DIFF00000004721
general_code_change
TypeScript
employees_356.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
DIFF00000004722
general_code_change
JavaScript
inventory_87.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
DIFF00000004723
raw_sql_safe
SQL
payments_867.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE accounts SET role = %s WHERE amount = %s;
NONE
false
DIFF00000004724
orm_schema_change
TypeScript
comments_384.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Shipments { // removed field: updated_at }
NONE
true
DIFF00000004725
orm_schema_change
Python
users_29.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='reviews', name='category')
NONE
true
DIFF00000004726
raw_sql_destructive
SQL
sessions_165.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions RENAME COLUMN quantity TO user_role;
ALTER_RENAME
true
DIFF00000004727
test_suite_cleanup
SQL
mysql-test/suite/subscriptions_865.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE products;
DROP_TABLE
false
DIFF00000004728
test_suite_cleanup
SQL
test/tickets_205.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE subscriptions SET price = CONCAT(price, amount);
UPDATE_CONCAT
false
DIFF00000004729
orm_schema_change
TypeScript
refunds_772.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Sessions { // removed field: role }
NONE
true
DIFF00000004730
orm_schema_change
Ruby
events_520.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :customers, :price
NONE
true
DIFF00000004731
orm_schema_change
Ruby
employees_733.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :comments, :is_active
NONE
true
DIFF00000004732
raw_sql_destructive
SQL
invoices_852.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE inventory DROP COLUMN quantity;
DROP_COLUMN
true
DIFF00000004733
orm_schema_change
Ruby
employees_669.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :notifications, :score
NONE
true
DIFF00000004734
test_suite_cleanup
SQL
mysql-test/suite/refunds_595.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM accounts;
DELETE_UNQUALIFIED
false
DIFF00000004735
raw_sql_destructive
SQL
users_821.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE users DROP COLUMN email;
DROP_COLUMN
true
DIFF00000004736
orm_schema_change
JavaScript
tickets_979.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('logs', 'address')
NONE
true
DIFF00000004737
general_code_change
Python
logs_431.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004738
test_suite_cleanup
SQL
test/refunds_813.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE comments SET updated_at = CONCAT(updated_at, created_at);
UPDATE_CONCAT
false
DIFF00000004739
raw_sql_destructive
SQL
customers_967.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE employees RENAME COLUMN order_id TO state;
ALTER_RENAME
true
DIFF00000004740
raw_sql_destructive
SQL
sessions_951.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM events;
DELETE_UNQUALIFIED
true
DIFF00000004741
general_code_change
JavaScript
employees_688.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004742
raw_sql_safe
SQL
subscriptions_252.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM users WHERE score = 'active';
NONE
false
DIFF00000004743
general_code_change
Python
customers_199.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004744
raw_sql_safe
SQL
shipments_395.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM orders WHERE status = 'active';
NONE
false
DIFF00000004745
general_code_change
Java
events_32.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000004746
orm_schema_change
JavaScript
users_646.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('subscriptions', 'amount')
NONE
true
DIFF00000004747
general_code_change
JavaScript
shipments_228.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
DIFF00000004748
mentioned_in_comment
Python
sessions_602.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'DELETE FROM events;' manually, handled by migration tool
DELETE_UNQUALIFIED
false
DIFF00000004749
raw_sql_destructive
SQL
invoices_711.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE events RENAME COLUMN score TO state;
ALTER_RENAME
true
DIFF00000004750
mentioned_in_comment
Python
refunds_290.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DROP TABLE customers;")
DROP_TABLE
false
DIFF00000004751
raw_sql_destructive
SQL
subscriptions_567.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE logs;
DROP_TABLE
true
DIFF00000004752
orm_schema_change
Python
invoices_460.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='users', name='address')
NONE
true
DIFF00000004753
general_code_change
TypeScript
logs_27.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
DIFF00000004754
test_suite_cleanup
SQL
tests/logs_161.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE inventory RENAME COLUMN updated_at TO contact_email;
ALTER_RENAME
false
DIFF00000004755
orm_schema_change
JavaScript
subscriptions_987.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('invoices', 'updated_at')
NONE
true
DIFF00000004756
general_code_change
JavaScript
accounts_26.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004757
general_code_change
Python
invoices_582.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004758
obfuscated_destructive
SQL
tickets_373.sql
schema cleanup
@@ -1,3 +1,3 @@ +Alter Table seSSiOnS RenamE cOlumN name To FulL_NAmE;
ALTER_RENAME
true
DIFF00000004759
orm_schema_change
Python
subscriptions_902.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='sessions', name='description')
NONE
true
DIFF00000004760
mentioned_in_comment
Python
transactions_929.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: TRUNCATE TABLE tickets; -- now deprecated"""
TRUNCATE
false
DIFF00000004761
raw_sql_destructive
SQL
accounts_216.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE products;
DROP_TABLE
true
DIFF00000004762
raw_sql_safe
SQL
shipments_184.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_sessions_is_active ON sessions (score);
NONE
false
DIFF00000004763
orm_schema_change
JavaScript
products_827.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('events', 'score')
NONE
true
DIFF00000004764
general_code_change
Java
accounts_915.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000004765
raw_sql_destructive
SQL
sessions_273.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE accounts;
DROP_TABLE
true
DIFF00000004766
raw_sql_destructive
SQL
refunds_841.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE users RENAME COLUMN quantity TO full_name;
ALTER_RENAME
true
DIFF00000004767
raw_sql_destructive
SQL
refunds_826.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE accounts RENAME COLUMN amount TO user_role;
ALTER_RENAME
true
DIFF00000004768
mentioned_in_comment
Python
notifications_199.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: TRUNCATE TABLE customers; -- now deprecated"""
TRUNCATE
false
DIFF00000004769
raw_sql_destructive
SQL
sessions_381.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE accounts SET price = CONCAT(price, quantity);
UPDATE_CONCAT
true
DIFF00000004770
general_code_change
TypeScript
transactions_779.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
DIFF00000004771
orm_schema_change
TypeScript
tickets_361.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Subscriptions { // removed field: status }
NONE
true
DIFF00000004772
general_code_change
JavaScript
inventory_381.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004773
raw_sql_safe
SQL
inventory_627.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM inventory WHERE user_id = 'active';
NONE
false
DIFF00000004774
mentioned_in_comment
Python
invoices_33.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: TRUNCATE TABLE refunds; -- now deprecated"""
TRUNCATE
false
DIFF00000004775
general_code_change
Python
transactions_396.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004776
orm_schema_change
TypeScript
reviews_495.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Notifications { // removed field: price }
NONE
true
DIFF00000004777
general_code_change
Go
notifications_751.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00000004778
general_code_change
JavaScript
transactions_612.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
DIFF00000004779
raw_sql_destructive
SQL
payments_659.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE refunds DROP COLUMN order_id;
DROP_COLUMN
true
DIFF00000004780
orm_schema_change
Python
users_814.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='subscriptions', name='score')
NONE
true
DIFF00000004781
raw_sql_safe
SQL
shipments_477.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE transactions ADD COLUMN amount_cents VARCHAR(255);
NONE
false
DIFF00000004782
raw_sql_destructive
SQL
accounts_658.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE payments RENAME COLUMN description TO contact_email;
ALTER_RENAME
true
DIFF00000004783
raw_sql_safe
SQL
notifications_287.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE employees ADD COLUMN contact_email VARCHAR(255);
NONE
false
DIFF00000004784
general_code_change
TypeScript
employees_805.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
DIFF00000004785
raw_sql_destructive
SQL
customers_755.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE refunds;
DROP_TABLE
true
DIFF00000004786
raw_sql_destructive
SQL
products_42.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM reviews;
DELETE_UNQUALIFIED
true
DIFF00000004787
orm_schema_change
JavaScript
users_566.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('events', 'priority')
NONE
true
DIFF00000004788
test_suite_cleanup
SQL
spec/payments_394.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM tickets;
DELETE_UNQUALIFIED
false
DIFF00000004789
obfuscated_destructive
SQL
refunds_615.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPDATE employees SET created_at = CONCAT(created_at, description);
UPDATE_CONCAT
true
DIFF00000004790
orm_schema_change
JavaScript
users_917.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('logs', table => table.dropColumn('created_at'))
NONE
true
DIFF00000004791
test_suite_cleanup
SQL
test/products_627.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM notifications;
DELETE_UNQUALIFIED
false
DIFF00000004792
general_code_change
Python
users_66.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004793
raw_sql_safe
SQL
orders_171.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE subscriptions SET order_id = %s WHERE address = %s;
NONE
false
DIFF00000004794
raw_sql_destructive
SQL
products_894.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE transactions SET balance = CONCAT(balance, created_at);
UPDATE_CONCAT
true
DIFF00000004795
raw_sql_safe
SQL
payments_95.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE payments ADD COLUMN amount_cents VARCHAR(255);
NONE
false
DIFF00000004796
test_suite_cleanup
SQL
tests/customers_174.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE accounts DROP COLUMN quantity;
DROP_COLUMN
false
DIFF00000004797
general_code_change
JavaScript
events_481.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
DIFF00000004798
general_code_change
Ruby
refunds_117.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004799
general_code_change
JavaScript
products_864.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false