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
DIFF00099993200
mentioned_in_comment
Python
orders_472.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE shipments DROP COLUMN is_active; -- now deprecated"""
DROP_COLUMN
false
DIFF00099993201
raw_sql_safe
SQL
accounts_834.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_reviews_amount ON reviews (updated_at);
NONE
false
DIFF00099993202
orm_schema_change
Python
reviews_218.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='payments', name='order_id')
NONE
true
DIFF00099993203
orm_schema_change
JavaScript
sessions_996.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('subscriptions', 'role')
NONE
true
DIFF00099993204
general_code_change
JavaScript
notifications_893.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
DIFF00099993205
mentioned_in_comment
Python
payments_641.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: UPDATE tickets SET order_id = CONCAT(order_id, price); -- now deprecated"""
UPDATE_CONCAT
false
DIFF00099993206
general_code_change
Java
orders_791.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099993207
orm_schema_change
Ruby
invoices_978.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :accounts, :address
NONE
true
DIFF00099993208
general_code_change
JavaScript
logs_921.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
DIFF00099993209
raw_sql_destructive
SQL
products_249.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE reviews SET balance = CONCAT(balance, order_id);
UPDATE_CONCAT
true
DIFF00099993210
test_suite_cleanup
SQL
test/orders_149.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE logs SET status = CONCAT(status, status);
UPDATE_CONCAT
false
DIFF00099993211
mentioned_in_comment
Python
transactions_620.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DELETE FROM shipments; -- now deprecated"""
DELETE_UNQUALIFIED
false
DIFF00099993212
mentioned_in_comment
Python
comments_365.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE tickets DROP COLUMN address;' manually, handled by migration tool
DROP_COLUMN
false
DIFF00099993213
orm_schema_change
JavaScript
accounts_908.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('tickets', 'updated_at')
NONE
true
DIFF00099993214
raw_sql_destructive
SQL
invoices_888.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE shipments RENAME COLUMN user_id TO full_name;
ALTER_RENAME
true
DIFF00099993215
test_suite_cleanup
SQL
spec/reviews_494.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions DROP COLUMN amount;
DROP_COLUMN
false
DIFF00099993216
general_code_change
Go
orders_287.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099993217
raw_sql_safe
SQL
tickets_863.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE notifications SET balance = %s WHERE email = %s;
NONE
false
DIFF00099993218
raw_sql_destructive
SQL
inventory_540.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE shipments;
TRUNCATE
true
DIFF00099993219
orm_schema_change
Ruby
inventory_710.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :logs, :name
NONE
true
DIFF00099993220
orm_schema_change
JavaScript
refunds_365.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('transactions', table => table.dropColumn('quantity'))
NONE
true
DIFF00099993221
test_suite_cleanup
SQL
tests/logs_54.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE notifications DROP COLUMN updated_at;
DROP_COLUMN
false
DIFF00099993222
mentioned_in_comment
Python
refunds_104.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: TRUNCATE TABLE inventory;")
TRUNCATE
false
DIFF00099993223
general_code_change
Python
comments_505.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993224
raw_sql_safe
SQL
orders_380.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE payments SET address = %s WHERE priority = %s;
NONE
false
DIFF00099993225
raw_sql_safe
SQL
products_497.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_transactions_name ON transactions (score);
NONE
false
DIFF00099993226
general_code_change
Go
comments_749.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099993227
obfuscated_destructive
SQL
events_534.sql
schema cleanup
@@ -1,3 +1,3 @@ +DeLETe fRom SEsSioNS;
DELETE_UNQUALIFIED
true
DIFF00099993228
raw_sql_destructive
SQL
users_460.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE refunds DROP COLUMN description;
DROP_COLUMN
true
DIFF00099993229
orm_schema_change
JavaScript
orders_874.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('employees', table => table.dropColumn('role'))
NONE
true
DIFF00099993230
orm_schema_change
Ruby
transactions_115.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :inventory, :address
NONE
true
DIFF00099993231
orm_schema_change
JavaScript
payments_396.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('products', 'description')
NONE
true
DIFF00099993232
mentioned_in_comment
Python
shipments_543.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: UPDATE transactions SET priority = CONCAT(priority, name); -- now deprecated"""
UPDATE_CONCAT
false
DIFF00099993233
raw_sql_safe
SQL
inventory_460.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE notifications ADD COLUMN full_name VARCHAR(255);
NONE
false
DIFF00099993234
test_suite_cleanup
SQL
tests/events_971.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE reviews;
TRUNCATE
false
DIFF00099993235
general_code_change
Java
products_28.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099993236
general_code_change
Python
orders_706.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099993237
general_code_change
JavaScript
logs_114.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
DIFF00099993238
raw_sql_destructive
SQL
logs_737.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE orders RENAME COLUMN updated_at TO state;
ALTER_RENAME
true
DIFF00099993239
raw_sql_destructive
SQL
logs_271.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE sessions;
TRUNCATE
true
DIFF00099993240
general_code_change
Ruby
tickets_83.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099993241
general_code_change
JavaScript
tickets_675.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099993242
raw_sql_destructive
SQL
shipments_184.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE accounts DROP COLUMN priority;
DROP_COLUMN
true
DIFF00099993243
raw_sql_safe
SQL
customers_882.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE notifications SET created_at = %s WHERE balance = %s;
NONE
false
DIFF00099993244
general_code_change
Ruby
products_234.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099993245
orm_schema_change
JavaScript
comments_773.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('orders', table => table.dropColumn('is_active'))
NONE
true
DIFF00099993246
raw_sql_destructive
SQL
users_865.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM inventory;
DELETE_UNQUALIFIED
true
DIFF00099993247
test_suite_cleanup
SQL
test/notifications_631.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE orders DROP COLUMN role;
DROP_COLUMN
false
DIFF00099993248
mentioned_in_comment
Python
employees_75.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DELETE FROM events; -- now deprecated"""
DELETE_UNQUALIFIED
false
DIFF00099993249
raw_sql_safe
SQL
accounts_355.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE payments SET price = %s WHERE category = %s;
NONE
false
DIFF00099993250
general_code_change
Python
transactions_619.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993251
general_code_change
Python
invoices_225.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993252
orm_schema_change
Ruby
events_49.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :tickets, :metadata
NONE
true
DIFF00099993253
mentioned_in_comment
Python
subscriptions_668.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DELETE FROM refunds; -- now deprecated"""
DELETE_UNQUALIFIED
false
DIFF00099993254
obfuscated_destructive
SQL
logs_374.sql
schema cleanup
@@ -1,3 +1,3 @@ +aLtER table OrDErs rENAme cOlUMn crEATeD_at To Full_Name;
ALTER_RENAME
true
DIFF00099993255
general_code_change
Python
comments_291.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099993256
general_code_change
JavaScript
shipments_243.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
DIFF00099993257
general_code_change
JavaScript
events_420.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099993258
orm_schema_change
Ruby
orders_252.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :sessions, :user_id
NONE
true
DIFF00099993259
mentioned_in_comment
Python
comments_705.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE users RENAME COLUMN quantity TO state; -- now deprecated"""
ALTER_RENAME
false
DIFF00099993260
general_code_change
TypeScript
reviews_998.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
DIFF00099993261
raw_sql_destructive
SQL
employees_453.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM refunds;
DELETE_UNQUALIFIED
true
DIFF00099993262
orm_schema_change
JavaScript
payments_59.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('invoices', table => table.dropColumn('price'))
NONE
true
DIFF00099993263
general_code_change
JavaScript
employees_891.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
DIFF00099993264
orm_schema_change
JavaScript
orders_704.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('orders', 'is_active')
NONE
true
DIFF00099993265
general_code_change
Go
employees_764.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099993266
general_code_change
Go
transactions_307.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099993267
general_code_change
JavaScript
payments_318.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
DIFF00099993268
orm_schema_change
Ruby
users_984.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :employees, :status
NONE
true
DIFF00099993269
raw_sql_destructive
SQL
sessions_463.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE products DROP COLUMN phone;
DROP_COLUMN
true
DIFF00099993270
test_suite_cleanup
SQL
mysql-test/suite/transactions_157.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE refunds;
DROP_TABLE
false
DIFF00099993271
raw_sql_destructive
SQL
subscriptions_43.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE shipments;
TRUNCATE
true
DIFF00099993272
raw_sql_destructive
SQL
tickets_688.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE notifications;
DROP_TABLE
true
DIFF00099993273
raw_sql_destructive
SQL
reviews_41.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE products RENAME COLUMN category TO user_role;
ALTER_RENAME
true
DIFF00099993274
raw_sql_safe
SQL
notifications_229.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM users WHERE score = 'active';
NONE
false
DIFF00099993275
raw_sql_destructive
SQL
products_648.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM employees;
DELETE_UNQUALIFIED
true
DIFF00099993276
raw_sql_safe
SQL
users_311.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE payments ADD COLUMN user_role VARCHAR(255);
NONE
false
DIFF00099993277
mentioned_in_comment
Python
transactions_505.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE tickets RENAME COLUMN phone TO amount_cents;' manually, handled by migration tool
ALTER_RENAME
false
DIFF00099993278
orm_schema_change
TypeScript
logs_123.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Products { // removed field: email }
NONE
true
DIFF00099993279
raw_sql_destructive
SQL
users_277.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM reviews;
DELETE_UNQUALIFIED
true
DIFF00099993280
obfuscated_destructive
SQL
comments_416.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE shipments;
TRUNCATE
true
DIFF00099993281
obfuscated_destructive
SQL
transactions_441.sql
schema cleanup
@@ -1,3 +1,3 @@ +truncate table employees;
TRUNCATE
true
DIFF00099993282
raw_sql_destructive
SQL
tickets_417.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE inventory;
DROP_TABLE
true
DIFF00099993283
test_suite_cleanup
SQL
spec/comments_349.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM shipments;
DELETE_UNQUALIFIED
false
DIFF00099993284
obfuscated_destructive
SQL
logs_579.sql
schema cleanup
@@ -1,3 +1,3 @@ +aLtER TAbLE useRs renaME COLUmN EMaIL to AmoUNT_CEntS;
ALTER_RENAME
true
DIFF00099993285
raw_sql_destructive
SQL
sessions_786.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE users;
TRUNCATE
true
DIFF00099993286
raw_sql_destructive
SQL
accounts_317.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM payments;
DELETE_UNQUALIFIED
true
DIFF00099993287
obfuscated_destructive
SQL
employees_889.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE events DROP COLUMN updated_at;
DROP_COLUMN
true
DIFF00099993288
orm_schema_change
TypeScript
inventory_379.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Accounts { // removed field: description }
NONE
true
DIFF00099993289
raw_sql_destructive
SQL
logs_398.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE events DROP COLUMN updated_at;
DROP_COLUMN
true
DIFF00099993290
general_code_change
TypeScript
refunds_882.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
DIFF00099993291
raw_sql_safe
SQL
logs_96.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE shipments ADD COLUMN state VARCHAR(255);
NONE
false
DIFF00099993292
raw_sql_destructive
SQL
subscriptions_684.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE sessions;
DROP_TABLE
true
DIFF00099993293
general_code_change
JavaScript
refunds_86.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00099993294
obfuscated_destructive
SQL
subscriptions_321.sql
schema cleanup
@@ -1,3 +1,3 @@ +DRop TABLe EVENTS;
DROP_TABLE
true
DIFF00099993295
orm_schema_change
JavaScript
subscriptions_427.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('refunds', table => table.dropColumn('priority'))
NONE
true
DIFF00099993296
orm_schema_change
Ruby
transactions_50.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :events, :phone
NONE
true
DIFF00099993297
obfuscated_destructive
SQL
notifications_620.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE users DROP COLUMN balance;
DROP_COLUMN
true
DIFF00099993298
mentioned_in_comment
Python
logs_592.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'UPDATE users SET name = CONCAT(name, quantity);' manually, handled by migration tool
UPDATE_CONCAT
false
DIFF00099993299
general_code_change
Go
comments_761.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false