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
DIFF00000007100
raw_sql_destructive
SQL
refunds_850.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE reviews DROP COLUMN role;
DROP_COLUMN
true
DIFF00000007101
raw_sql_destructive
SQL
products_904.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE reviews DROP COLUMN name;
DROP_COLUMN
true
DIFF00000007102
mentioned_in_comment
Python
comments_630.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DELETE FROM accounts;")
DELETE_UNQUALIFIED
false
DIFF00000007103
raw_sql_safe
SQL
subscriptions_885.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE inventory SET order_id = %s WHERE amount = %s;
NONE
false
DIFF00000007104
test_suite_cleanup
SQL
tests/customers_461.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE orders;
TRUNCATE
false
DIFF00000007105
raw_sql_destructive
SQL
refunds_82.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE subscriptions;
TRUNCATE
true
DIFF00000007106
raw_sql_safe
SQL
invoices_868.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE logs ADD COLUMN state VARCHAR(255);
NONE
false
DIFF00000007107
obfuscated_destructive
SQL
transactions_442.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE shipments DROP COLUMN phone;
DROP_COLUMN
true
DIFF00000007108
raw_sql_destructive
SQL
comments_862.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE tickets DROP COLUMN price;
DROP_COLUMN
true
DIFF00000007109
raw_sql_destructive
SQL
transactions_587.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE sessions SET email = CONCAT(email, category);
UPDATE_CONCAT
true
DIFF00000007110
orm_schema_change
JavaScript
products_86.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('sessions', table => table.dropColumn('score'))
NONE
true
DIFF00000007111
raw_sql_safe
SQL
accounts_443.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE refunds SET updated_at = %s WHERE role = %s;
NONE
false
DIFF00000007112
general_code_change
Go
events_257.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00000007113
obfuscated_destructive
SQL
accounts_840.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE payments;
DROP_TABLE
true
DIFF00000007114
obfuscated_destructive
SQL
refunds_254.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM payments;
DELETE_UNQUALIFIED
true
DIFF00000007115
general_code_change
Python
events_416.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000007116
general_code_change
Python
subscriptions_932.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000007117
orm_schema_change
Python
users_591.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='users', name='quantity')
NONE
true
DIFF00000007118
test_suite_cleanup
SQL
test/tickets_971.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE comments RENAME COLUMN phone TO state;
ALTER_RENAME
false
DIFF00000007119
general_code_change
Go
accounts_287.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00000007120
mentioned_in_comment
Python
logs_61.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: TRUNCATE TABLE shipments; -- now deprecated"""
TRUNCATE
false
DIFF00000007121
raw_sql_safe
SQL
inventory_78.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM events WHERE category = 'active';
NONE
false
DIFF00000007122
general_code_change
TypeScript
events_518.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
DIFF00000007123
raw_sql_destructive
SQL
employees_413.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE products;
DROP_TABLE
true
DIFF00000007124
orm_schema_change
Ruby
products_555.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :employees, :order_id
NONE
true
DIFF00000007125
raw_sql_safe
SQL
users_968.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE inventory ADD COLUMN amount_cents VARCHAR(255);
NONE
false
DIFF00000007126
raw_sql_destructive
SQL
orders_601.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE customers SET user_id = CONCAT(user_id, category);
UPDATE_CONCAT
true
DIFF00000007127
raw_sql_safe
SQL
notifications_713.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO logs (user_id, price) VALUES (%s, %s);
NONE
false
DIFF00000007128
general_code_change
Java
employees_402.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000007129
raw_sql_safe
SQL
shipments_288.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE transactions ADD COLUMN state VARCHAR(255);
NONE
false
DIFF00000007130
raw_sql_destructive
SQL
reviews_903.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE inventory;
DROP_TABLE
true
DIFF00000007131
raw_sql_destructive
SQL
tickets_275.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE comments SET priority = CONCAT(priority, price);
UPDATE_CONCAT
true
DIFF00000007132
raw_sql_destructive
SQL
users_878.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE users;
TRUNCATE
true
DIFF00000007133
mentioned_in_comment
Python
inventory_946.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE employees RENAME COLUMN role TO user_role; -- now deprecated"""
ALTER_RENAME
false
DIFF00000007134
obfuscated_destructive
SQL
logs_567.sql
schema cleanup
@@ -1,3 +1,3 @@ +TrUNcatE TaBLe inVenTory;
TRUNCATE
true
DIFF00000007135
general_code_change
Java
orders_617.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000007136
raw_sql_destructive
SQL
inventory_428.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE invoices;
DROP_TABLE
true
DIFF00000007137
raw_sql_destructive
SQL
subscriptions_438.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE notifications DROP COLUMN score;
DROP_COLUMN
true
DIFF00000007138
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
DIFF00000007139
mentioned_in_comment
Python
comments_839.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE invoices RENAME COLUMN score TO contact_email;' manually, handled by migration tool
ALTER_RENAME
false
DIFF00000007140
general_code_change
Go
transactions_866.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00000007141
orm_schema_change
JavaScript
shipments_529.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('inventory', 'created_at')
NONE
true
DIFF00000007142
mentioned_in_comment
Python
employees_203.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'TRUNCATE TABLE comments;' manually, handled by migration tool
TRUNCATE
false
DIFF00000007143
obfuscated_destructive
SQL
orders_581.sql
schema cleanup
@@ -1,3 +1,3 @@ +DRop tABLe accoUnTS;
DROP_TABLE
true
DIFF00000007144
obfuscated_destructive
SQL
products_328.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM customers;
DELETE_UNQUALIFIED
true
DIFF00000007145
raw_sql_safe
SQL
users_364.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE transactions SET address = %s WHERE is_active = %s;
NONE
false
DIFF00000007146
general_code_change
Ruby
transactions_901.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000007147
general_code_change
Python
inventory_660.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000007148
general_code_change
Python
accounts_313.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000007149
obfuscated_destructive
SQL
subscriptions_850.sql
schema cleanup
@@ -1,3 +1,3 @@ +alter table reviews drop column metadata;
DROP_COLUMN
true
DIFF00000007150
raw_sql_destructive
SQL
tickets_360.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE users;
DROP_TABLE
true
DIFF00000007151
general_code_change
Python
logs_160.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000007152
raw_sql_safe
SQL
accounts_306.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM tickets WHERE updated_at = 'active';
NONE
false
DIFF00000007153
obfuscated_destructive
SQL
orders_396.sql
schema cleanup
@@ -1,3 +1,3 @@ +delete from invoices;
DELETE_UNQUALIFIED
true
DIFF00000007154
general_code_change
TypeScript
sessions_978.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
DIFF00000007155
test_suite_cleanup
SQL
spec/tickets_865.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE users RENAME COLUMN phone TO full_name;
ALTER_RENAME
false
DIFF00000007156
raw_sql_safe
SQL
payments_69.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO comments (name, role) VALUES (%s, %s);
NONE
false
DIFF00000007157
raw_sql_destructive
SQL
accounts_843.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE sessions;
TRUNCATE
true
DIFF00000007158
general_code_change
TypeScript
products_435.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
DIFF00000007159
orm_schema_change
JavaScript
notifications_478.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('comments', table => table.dropColumn('email'))
NONE
true
DIFF00000007160
general_code_change
JavaScript
orders_820.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000007161
orm_schema_change
Python
payments_981.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='transactions', name='description')
NONE
true
DIFF00000007162
general_code_change
Java
employees_482.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000007163
raw_sql_destructive
SQL
invoices_210.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE logs;
DROP_TABLE
true
DIFF00000007164
obfuscated_destructive
SQL
transactions_77.sql
schema cleanup
@@ -1,3 +1,3 @@ +altER TABle invOIcES rENAME columN emAil To AMoUNT_cENTS;
ALTER_RENAME
true
DIFF00000007165
general_code_change
JavaScript
events_325.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000007166
orm_schema_change
Ruby
products_62.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :shipments, :balance
NONE
true
DIFF00000007167
raw_sql_safe
SQL
shipments_498.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_customers_status ON customers (balance);
NONE
false
DIFF00000007168
raw_sql_safe
SQL
products_384.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE tickets SET role = %s WHERE created_at = %s;
NONE
false
DIFF00000007169
obfuscated_destructive
SQL
logs_338.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE shipments;
TRUNCATE
true
DIFF00000007170
raw_sql_destructive
SQL
employees_968.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE payments RENAME COLUMN address TO contact_email;
ALTER_RENAME
true
DIFF00000007171
general_code_change
Python
tickets_582.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000007172
general_code_change
Python
users_497.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000007173
mentioned_in_comment
Python
payments_147.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE employees RENAME COLUMN balance TO contact_email;")
ALTER_RENAME
false
DIFF00000007174
raw_sql_safe
SQL
logs_995.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO products (balance, email) VALUES (%s, %s);
NONE
false
DIFF00000007175
orm_schema_change
JavaScript
comments_797.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('tickets', table => table.dropColumn('status'))
NONE
true
DIFF00000007176
test_suite_cleanup
SQL
tests/inventory_888.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE shipments;
DROP_TABLE
false
DIFF00000007177
raw_sql_destructive
SQL
shipments_612.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE logs;
TRUNCATE
true
DIFF00000007178
general_code_change
TypeScript
orders_344.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
DIFF00000007179
general_code_change
Java
payments_707.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000007180
raw_sql_safe
SQL
employees_867.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_logs_email ON logs (score);
NONE
false
DIFF00000007181
general_code_change
JavaScript
inventory_365.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000007182
obfuscated_destructive
SQL
subscriptions_229.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE payments RENAME COLUMN name TO full_name;
ALTER_RENAME
true
DIFF00000007183
orm_schema_change
JavaScript
events_258.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('logs', 'price')
NONE
true
DIFF00000007184
general_code_change
Ruby
reviews_785.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000007185
raw_sql_destructive
SQL
reviews_877.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE transactions;
TRUNCATE
true
DIFF00000007186
raw_sql_safe
SQL
subscriptions_867.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_accounts_phone ON accounts (category);
NONE
false
DIFF00000007187
raw_sql_safe
SQL
shipments_638.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE notifications SET quantity = %s WHERE amount = %s;
NONE
false
DIFF00000007188
general_code_change
Python
notifications_591.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000007189
mentioned_in_comment
Python
customers_635.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: UPDATE tickets SET balance = CONCAT(balance, is_active);")
UPDATE_CONCAT
false
DIFF00000007190
raw_sql_safe
SQL
tickets_370.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM orders WHERE category = 'active';
NONE
false
DIFF00000007191
general_code_change
TypeScript
refunds_526.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
DIFF00000007192
raw_sql_safe
SQL
sessions_801.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_tickets_amount ON tickets (balance);
NONE
false
DIFF00000007193
obfuscated_destructive
SQL
products_825.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE orders RENAME COLUMN order_id TO amount_cents;
ALTER_RENAME
true
DIFF00000007194
general_code_change
Java
customers_347.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000007195
raw_sql_safe
SQL
reviews_603.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE users ADD COLUMN contact_email VARCHAR(255);
NONE
false
DIFF00000007196
general_code_change
JavaScript
users_681.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
DIFF00000007197
test_suite_cleanup
SQL
mysql-test/suite/shipments_281.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE inventory SET role = CONCAT(role, email);
UPDATE_CONCAT
false
DIFF00000007198
general_code_change
Ruby
customers_192.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000007199
general_code_change
Go
logs_263.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false