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
DIFF00099998700
general_code_change
TypeScript
products_476.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
DIFF00099998701
raw_sql_destructive
SQL
payments_283.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE refunds SET quantity = CONCAT(quantity, name);
UPDATE_CONCAT
true
DIFF00099998702
orm_schema_change
JavaScript
tickets_752.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('payments', 'order_id')
NONE
true
DIFF00099998703
raw_sql_destructive
SQL
inventory_160.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE reviews;
DROP_TABLE
true
DIFF00099998704
general_code_change
Python
logs_739.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099998705
general_code_change
JavaScript
invoices_434.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
DIFF00099998706
mentioned_in_comment
Python
products_893.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE inventory RENAME COLUMN is_active TO contact_email;' manually, handled by migration tool
ALTER_RENAME
false
DIFF00099998707
orm_schema_change
TypeScript
employees_886.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Refunds { // removed field: order_id }
NONE
true
DIFF00099998708
orm_schema_change
Python
customers_140.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='comments', name='created_at')
NONE
true
DIFF00099998709
raw_sql_destructive
SQL
logs_887.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE inventory;
DROP_TABLE
true
DIFF00099998710
general_code_change
Ruby
employees_708.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099998711
obfuscated_destructive
SQL
subscriptions_156.sql
schema cleanup
@@ -1,3 +1,3 @@ +alter table notifications rename column description to state;
ALTER_RENAME
true
DIFF00099998712
raw_sql_safe
SQL
payments_332.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM reviews WHERE user_id = 'active';
NONE
false
DIFF00099998713
raw_sql_safe
SQL
products_123.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE logs SET phone = %s WHERE amount = %s;
NONE
false
DIFF00099998714
obfuscated_destructive
SQL
shipments_847.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE reviews DROP COLUMN order_id;
DROP_COLUMN
true
DIFF00099998715
raw_sql_destructive
SQL
products_331.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE comments SET name = CONCAT(name, price);
UPDATE_CONCAT
true
DIFF00099998716
raw_sql_destructive
SQL
transactions_829.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE comments SET category = CONCAT(category, order_id);
UPDATE_CONCAT
true
DIFF00099998717
raw_sql_destructive
SQL
transactions_464.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE events;
DROP_TABLE
true
DIFF00099998718
raw_sql_safe
SQL
payments_205.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO employees (role, category) VALUES (%s, %s);
NONE
false
DIFF00099998719
mentioned_in_comment
Python
products_687.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: UPDATE orders SET quantity = CONCAT(quantity, created_at);")
UPDATE_CONCAT
false
DIFF00099998720
general_code_change
TypeScript
refunds_861.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
DIFF00099998721
orm_schema_change
TypeScript
transactions_752.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Tickets { // removed field: score }
NONE
true
DIFF00099998722
obfuscated_destructive
SQL
inventory_727.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM accounts;
DELETE_UNQUALIFIED
true
DIFF00099998723
raw_sql_destructive
SQL
events_197.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE tickets SET phone = CONCAT(phone, score);
UPDATE_CONCAT
true
DIFF00099998724
test_suite_cleanup
SQL
tests/accounts_478.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE employees SET amount = CONCAT(amount, updated_at);
UPDATE_CONCAT
false
DIFF00099998725
raw_sql_safe
SQL
events_517.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE sessions SET order_id = %s WHERE name = %s;
NONE
false
DIFF00099998726
raw_sql_safe
SQL
tickets_140.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO shipments (score, email) VALUES (%s, %s);
NONE
false
DIFF00099998727
mentioned_in_comment
Python
inventory_6.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE products DROP COLUMN category;' manually, handled by migration tool
DROP_COLUMN
false
DIFF00099998728
raw_sql_safe
SQL
invoices_976.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO invoices (name, balance) VALUES (%s, %s);
NONE
false
DIFF00099998729
raw_sql_destructive
SQL
customers_724.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions DROP COLUMN price;
DROP_COLUMN
true
DIFF00099998730
orm_schema_change
JavaScript
refunds_769.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('shipments', 'amount')
NONE
true
DIFF00099998731
test_suite_cleanup
SQL
test/refunds_934.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM accounts;
DELETE_UNQUALIFIED
false
DIFF00099998732
test_suite_cleanup
SQL
tests/logs_909.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE comments;
TRUNCATE
false
DIFF00099998733
general_code_change
Go
products_230.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099998734
general_code_change
TypeScript
payments_64.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
DIFF00099998735
raw_sql_safe
SQL
tickets_249.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO products (created_at, quantity) VALUES (%s, %s);
NONE
false
DIFF00099998736
obfuscated_destructive
SQL
shipments_559.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE inventory;
TRUNCATE
true
DIFF00099998737
general_code_change
Python
comments_658.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099998738
general_code_change
JavaScript
customers_854.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
DIFF00099998739
mentioned_in_comment
Python
tickets_76.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE sessions RENAME COLUMN is_active TO contact_email;")
ALTER_RENAME
false
DIFF00099998740
raw_sql_destructive
SQL
reviews_559.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE tickets DROP COLUMN amount;
DROP_COLUMN
true
DIFF00099998741
test_suite_cleanup
SQL
mysql-test/suite/products_59.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE accounts;
TRUNCATE
false
DIFF00099998742
raw_sql_destructive
SQL
shipments_848.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE shipments RENAME COLUMN address TO contact_email;
ALTER_RENAME
true
DIFF00099998743
mentioned_in_comment
Python
subscriptions_796.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'DROP TABLE transactions;' manually, handled by migration tool
DROP_TABLE
false
DIFF00099998744
obfuscated_destructive
SQL
notifications_596.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE accounts;
DROP_TABLE
true
DIFF00099998745
general_code_change
Python
employees_75.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00099998746
raw_sql_safe
SQL
tickets_41.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE accounts ADD COLUMN contact_email VARCHAR(255);
NONE
false
DIFF00099998747
test_suite_cleanup
SQL
spec/subscriptions_117.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE customers RENAME COLUMN order_id TO amount_cents;
ALTER_RENAME
false
DIFF00099998748
test_suite_cleanup
SQL
tests/events_535.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions RENAME COLUMN score TO state;
ALTER_RENAME
false
DIFF00099998749
raw_sql_safe
SQL
inventory_365.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO inventory (quantity, description) VALUES (%s, %s);
NONE
false
DIFF00099998750
raw_sql_destructive
SQL
shipments_482.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE customers SET balance = CONCAT(balance, balance);
UPDATE_CONCAT
true
DIFF00099998751
obfuscated_destructive
SQL
employees_166.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE customers RENAME COLUMN amount TO contact_email;
ALTER_RENAME
true
DIFF00099998752
orm_schema_change
TypeScript
comments_998.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Employees { // removed field: is_active }
NONE
true
DIFF00099998753
obfuscated_destructive
SQL
refunds_965.sql
schema cleanup
@@ -1,3 +1,3 @@ +drop table customers;
DROP_TABLE
true
DIFF00099998754
raw_sql_safe
SQL
transactions_498.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO accounts (metadata, is_active) VALUES (%s, %s);
NONE
false
DIFF00099998755
raw_sql_safe
SQL
accounts_227.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO employees (is_active, is_active) VALUES (%s, %s);
NONE
false
DIFF00099998756
obfuscated_destructive
SQL
products_311.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPDATE subscriptions SET created_at = CONCAT(created_at, is_active);
UPDATE_CONCAT
true
DIFF00099998757
orm_schema_change
TypeScript
orders_739.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Sessions { // removed field: metadata }
NONE
true
DIFF00099998758
general_code_change
TypeScript
shipments_340.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
DIFF00099998759
raw_sql_destructive
SQL
refunds_881.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE shipments SET metadata = CONCAT(metadata, phone);
UPDATE_CONCAT
true
DIFF00099998760
mentioned_in_comment
Python
comments_615.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE customers RENAME COLUMN phone TO contact_email;")
ALTER_RENAME
false
DIFF00099998761
general_code_change
Python
users_582.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099998762
general_code_change
Java
orders_589.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099998763
obfuscated_destructive
SQL
notifications_416.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE invoices DROP COLUMN priority;
DROP_COLUMN
true
DIFF00099998764
raw_sql_safe
SQL
tickets_395.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE employees SET category = %s WHERE quantity = %s;
NONE
false
DIFF00099998765
general_code_change
JavaScript
users_357.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
DIFF00099998766
orm_schema_change
Python
customers_371.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='refunds', name='score')
NONE
true
DIFF00099998767
general_code_change
Java
accounts_136.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099998768
raw_sql_safe
SQL
events_849.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_refunds_order_id ON refunds (created_at);
NONE
false
DIFF00099998769
general_code_change
JavaScript
orders_345.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
DIFF00099998770
obfuscated_destructive
SQL
payments_776.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE notifications;
DROP_TABLE
true
DIFF00099998771
general_code_change
Java
inventory_633.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099998772
general_code_change
Ruby
transactions_275.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099998773
raw_sql_safe
SQL
comments_766.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO invoices (amount, user_id) VALUES (%s, %s);
NONE
false
DIFF00099998774
obfuscated_destructive
SQL
transactions_890.sql
schema cleanup
@@ -1,3 +1,3 @@ +update employees set description = concat(description, is_active);
UPDATE_CONCAT
true
DIFF00099998775
obfuscated_destructive
SQL
inventory_725.sql
schema cleanup
@@ -1,3 +1,3 @@ +delete from notifications;
DELETE_UNQUALIFIED
true
DIFF00099998776
general_code_change
Go
logs_745.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00099998777
orm_schema_change
Ruby
transactions_592.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :employees, :role
NONE
true
DIFF00099998778
raw_sql_destructive
SQL
shipments_796.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE refunds;
TRUNCATE
true
DIFF00099998779
general_code_change
Ruby
logs_186.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099998780
general_code_change
Ruby
orders_101.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00099998781
mentioned_in_comment
Python
orders_649.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: TRUNCATE TABLE users;")
TRUNCATE
false
DIFF00099998782
orm_schema_change
Python
sessions_647.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='inventory', name='is_active')
NONE
true
DIFF00099998783
raw_sql_destructive
SQL
inventory_373.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE accounts RENAME COLUMN user_id TO amount_cents;
ALTER_RENAME
true
DIFF00099998784
general_code_change
TypeScript
refunds_604.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
DIFF00099998785
raw_sql_safe
SQL
transactions_465.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO logs (address, metadata) VALUES (%s, %s);
NONE
false
DIFF00099998786
raw_sql_safe
SQL
subscriptions_974.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE logs ADD COLUMN user_role VARCHAR(255);
NONE
false
DIFF00099998787
general_code_change
Java
products_226.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00099998788
orm_schema_change
Python
tickets_539.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='employees', name='role')
NONE
true
DIFF00099998789
general_code_change
JavaScript
notifications_480.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
DIFF00099998790
raw_sql_destructive
SQL
refunds_586.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM reviews;
DELETE_UNQUALIFIED
true
DIFF00099998791
general_code_change
TypeScript
orders_556.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
DIFF00099998792
mentioned_in_comment
Python
inventory_258.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DELETE FROM invoices; -- now deprecated"""
DELETE_UNQUALIFIED
false
DIFF00099998793
raw_sql_safe
SQL
orders_390.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE products ADD COLUMN contact_email VARCHAR(255);
NONE
false
DIFF00099998794
obfuscated_destructive
SQL
invoices_80.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE invoices;
TRUNCATE
true
DIFF00099998795
general_code_change
Python
tickets_737.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00099998796
raw_sql_destructive
SQL
tickets_243.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM invoices;
DELETE_UNQUALIFIED
true
DIFF00099998797
test_suite_cleanup
SQL
mysql-test/suite/transactions_564.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM employees;
DELETE_UNQUALIFIED
false
DIFF00099998798
test_suite_cleanup
SQL
spec/comments_51.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE users;
TRUNCATE
false
DIFF00099998799
obfuscated_destructive
SQL
shipments_670.sql
schema cleanup
@@ -1,3 +1,3 @@ +upDate PrODUctS sEt PHONe = CoNCAT(pHone, pRicE);
UPDATE_CONCAT
true