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
DIFF00000002800
general_code_change
Ruby
reviews_457.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000002801
mentioned_in_comment
Python
orders_189.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DELETE FROM logs; -- now deprecated"""
DELETE_UNQUALIFIED
false
DIFF00000002802
general_code_change
TypeScript
products_828.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
DIFF00000002803
raw_sql_safe
SQL
logs_18.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE notifications SET user_id = %s WHERE email = %s;
NONE
false
DIFF00000002804
obfuscated_destructive
SQL
inventory_75.sql
schema cleanup
@@ -1,3 +1,3 @@ +AltER taBlE LogS reNAmE COlUMn iS_aCTIvE To USer_role;
ALTER_RENAME
true
DIFF00000002805
mentioned_in_comment
Python
sessions_832.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE users RENAME COLUMN user_id TO contact_email; -- now deprecated"""
ALTER_RENAME
false
DIFF00000002806
general_code_change
Java
comments_610.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000002807
obfuscated_destructive
SQL
notifications_450.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE notifications;
TRUNCATE
true
DIFF00000002808
general_code_change
JavaScript
events_650.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
DIFF00000002809
obfuscated_destructive
SQL
logs_795.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE events;
DROP_TABLE
true
DIFF00000002810
raw_sql_destructive
SQL
transactions_665.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE accounts SET status = CONCAT(status, balance);
UPDATE_CONCAT
true
DIFF00000002811
obfuscated_destructive
SQL
transactions_440.sql
schema cleanup
@@ -1,3 +1,3 @@ +update comments set updated_at = concat(updated_at, name);
UPDATE_CONCAT
true
DIFF00000002812
general_code_change
Python
orders_776.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000002813
obfuscated_destructive
SQL
invoices_981.sql
schema cleanup
@@ -1,3 +1,3 @@ +update comments set updated_at = concat(updated_at, order_id);
UPDATE_CONCAT
true
DIFF00000002814
mentioned_in_comment
Python
comments_327.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE orders RENAME COLUMN priority TO state; -- now deprecated"""
ALTER_RENAME
false
DIFF00000002815
raw_sql_destructive
SQL
reviews_103.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE accounts;
TRUNCATE
true
DIFF00000002816
general_code_change
Java
reviews_373.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000002817
raw_sql_safe
SQL
tickets_75.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_events_priority ON events (phone);
NONE
false
DIFF00000002818
orm_schema_change
JavaScript
orders_681.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('subscriptions', table => table.dropColumn('address'))
NONE
true
DIFF00000002819
general_code_change
Python
products_436.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000002820
general_code_change
Python
users_851.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000002821
mentioned_in_comment
Python
shipments_585.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE payments RENAME COLUMN role TO amount_cents;")
ALTER_RENAME
false
DIFF00000002822
raw_sql_safe
SQL
logs_393.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE tickets SET category = %s WHERE updated_at = %s;
NONE
false
DIFF00000002823
general_code_change
Python
comments_211.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000002824
raw_sql_destructive
SQL
sessions_938.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM logs;
DELETE_UNQUALIFIED
true
DIFF00000002825
obfuscated_destructive
SQL
customers_954.sql
schema cleanup
@@ -1,3 +1,3 @@ +delete from tickets;
DELETE_UNQUALIFIED
true
DIFF00000002826
general_code_change
Python
notifications_856.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000002827
general_code_change
JavaScript
subscriptions_101.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
DIFF00000002828
general_code_change
JavaScript
payments_514.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
DIFF00000002829
obfuscated_destructive
SQL
subscriptions_24.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE users RENAME COLUMN category TO contact_email;
ALTER_RENAME
true
DIFF00000002830
raw_sql_safe
SQL
logs_598.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM payments WHERE amount = 'active';
NONE
false
DIFF00000002831
mentioned_in_comment
Python
transactions_386.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE invoices RENAME COLUMN amount TO amount_cents;' manually, handled by migration tool
ALTER_RENAME
false
DIFF00000002832
obfuscated_destructive
SQL
logs_981.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE transactions DROP COLUMN priority;
DROP_COLUMN
true
DIFF00000002833
raw_sql_destructive
SQL
users_321.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE comments;
TRUNCATE
true
DIFF00000002834
general_code_change
Java
payments_245.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000002835
mentioned_in_comment
Python
reviews_731.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: ALTER TABLE shipments DROP COLUMN score;")
DROP_COLUMN
false
DIFF00000002836
general_code_change
Go
users_666.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00000002837
orm_schema_change
JavaScript
payments_956.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('events', table => table.dropColumn('amount'))
NONE
true
DIFF00000002838
orm_schema_change
TypeScript
comments_750.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Accounts { // removed field: balance }
NONE
true
DIFF00000002839
general_code_change
JavaScript
transactions_124.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
DIFF00000002840
raw_sql_safe
SQL
invoices_16.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM products WHERE amount = 'active';
NONE
false
DIFF00000002841
raw_sql_safe
SQL
shipments_394.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE notifications ADD COLUMN contact_email VARCHAR(255);
NONE
false
DIFF00000002842
general_code_change
Java
comments_934.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000002843
mentioned_in_comment
Python
customers_207.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: UPDATE refunds SET description = CONCAT(description, priority); -- now deprecated"""
UPDATE_CONCAT
false
DIFF00000002844
raw_sql_safe
SQL
events_43.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM logs WHERE created_at = 'active';
NONE
false
DIFF00000002845
obfuscated_destructive
SQL
inventory_956.sql
schema cleanup
@@ -1,3 +1,3 @@ +upDAtE LOGs seT ORdeR_Id = cOncAT(ordEr_Id, metAdaTA);
UPDATE_CONCAT
true
DIFF00000002846
raw_sql_destructive
SQL
logs_468.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE refunds RENAME COLUMN metadata TO contact_email;
ALTER_RENAME
true
DIFF00000002847
test_suite_cleanup
SQL
mysql-test/suite/users_290.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM users;
DELETE_UNQUALIFIED
false
DIFF00000002848
obfuscated_destructive
SQL
refunds_227.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE subscriptions RENAME COLUMN description TO state;
ALTER_RENAME
true
DIFF00000002849
obfuscated_destructive
SQL
sessions_751.sql
schema cleanup
@@ -1,3 +1,3 @@ +UPDATE reviews SET email = CONCAT(email, category);
UPDATE_CONCAT
true
DIFF00000002850
raw_sql_safe
SQL
logs_853.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM invoices WHERE metadata = 'active';
NONE
false
DIFF00000002851
test_suite_cleanup
SQL
test/payments_520.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE payments SET description = CONCAT(description, balance);
UPDATE_CONCAT
false
DIFF00000002852
general_code_change
JavaScript
customers_951.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000002853
raw_sql_destructive
SQL
notifications_573.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE reviews;
DROP_TABLE
true
DIFF00000002854
obfuscated_destructive
SQL
inventory_269.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE payments;
TRUNCATE
true
DIFF00000002855
test_suite_cleanup
SQL
spec/employees_215.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DROP TABLE reviews;
DROP_TABLE
false
DIFF00000002856
raw_sql_safe
SQL
refunds_167.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE transactions SET email = %s WHERE user_id = %s;
NONE
false
DIFF00000002857
general_code_change
Python
sessions_257.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000002858
raw_sql_destructive
SQL
sessions_783.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM invoices;
DELETE_UNQUALIFIED
true
DIFF00000002859
test_suite_cleanup
SQL
test/logs_264.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM customers;
DELETE_UNQUALIFIED
false
DIFF00000002860
obfuscated_destructive
SQL
orders_336.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE notifications;
DROP_TABLE
true
DIFF00000002861
raw_sql_safe
SQL
inventory_734.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_accounts_is_active ON accounts (email);
NONE
false
DIFF00000002862
raw_sql_safe
SQL
notifications_689.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO users (updated_at, name) VALUES (%s, %s);
NONE
false
DIFF00000002863
raw_sql_safe
SQL
products_612.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE users SET category = %s WHERE phone = %s;
NONE
false
DIFF00000002864
test_suite_cleanup
SQL
mysql-test/suite/users_798.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM payments;
DELETE_UNQUALIFIED
false
DIFF00000002865
orm_schema_change
TypeScript
comments_269.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Tickets { // removed field: balance }
NONE
true
DIFF00000002866
raw_sql_destructive
SQL
invoices_559.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM events;
DELETE_UNQUALIFIED
true
DIFF00000002867
test_suite_cleanup
SQL
test/sessions_948.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM shipments;
DELETE_UNQUALIFIED
false
DIFF00000002868
raw_sql_destructive
SQL
transactions_953.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE customers;
DROP_TABLE
true
DIFF00000002869
general_code_change
Java
inventory_221.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000002870
orm_schema_change
Python
comments_799.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='products', name='phone')
NONE
true
DIFF00000002871
raw_sql_destructive
SQL
orders_448.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE events;
DROP_TABLE
true
DIFF00000002872
obfuscated_destructive
SQL
employees_764.sql
schema cleanup
@@ -1,3 +1,3 @@ +ALTER TABLE comments RENAME COLUMN user_id TO user_role;
ALTER_RENAME
true
DIFF00000002873
general_code_change
Python
reviews_64.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000002874
test_suite_cleanup
SQL
mysql-test/suite/customers_68.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE payments DROP COLUMN description;
DROP_COLUMN
false
DIFF00000002875
raw_sql_destructive
SQL
shipments_759.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE tickets DROP COLUMN email;
DROP_COLUMN
true
DIFF00000002876
general_code_change
JavaScript
transactions_192.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
DIFF00000002877
general_code_change
JavaScript
subscriptions_814.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
DIFF00000002878
mentioned_in_comment
Python
events_955.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DROP TABLE employees; -- now deprecated"""
DROP_TABLE
false
DIFF00000002879
raw_sql_destructive
SQL
reviews_20.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE payments RENAME COLUMN updated_at TO full_name;
ALTER_RENAME
true
DIFF00000002880
test_suite_cleanup
SQL
mysql-test/suite/notifications_232.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM customers;
DELETE_UNQUALIFIED
false
DIFF00000002881
raw_sql_destructive
SQL
comments_19.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE employees;
TRUNCATE
true
DIFF00000002882
orm_schema_change
TypeScript
refunds_651.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Events { // removed field: category }
NONE
true
DIFF00000002883
general_code_change
Ruby
sessions_923.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000002884
orm_schema_change
Ruby
shipments_677.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :refunds, :status
NONE
true
DIFF00000002885
general_code_change
Java
tickets_16.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000002886
orm_schema_change
JavaScript
products_134.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('shipments', 'updated_at')
NONE
true
DIFF00000002887
obfuscated_destructive
SQL
inventory_572.sql
schema cleanup
@@ -1,3 +1,3 @@ +Alter taBle TicKEtS DRop COLumn RoLe;
DROP_COLUMN
true
DIFF00000002888
general_code_change
Python
users_673.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000002889
raw_sql_destructive
SQL
tickets_181.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE employees DROP COLUMN address;
DROP_COLUMN
true
DIFF00000002890
orm_schema_change
Python
transactions_742.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='accounts', name='score')
NONE
true
DIFF00000002891
general_code_change
Python
refunds_458.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000002892
raw_sql_destructive
SQL
customers_842.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE comments DROP COLUMN order_id;
DROP_COLUMN
true
DIFF00000002893
raw_sql_safe
SQL
tickets_954.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO logs (email, address) VALUES (%s, %s);
NONE
false
DIFF00000002894
raw_sql_safe
SQL
comments_443.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO tickets (description, price) VALUES (%s, %s);
NONE
false
DIFF00000002895
raw_sql_destructive
SQL
employees_906.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM events;
DELETE_UNQUALIFIED
true
DIFF00000002896
mentioned_in_comment
Python
accounts_411.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: UPDATE notifications SET quantity = CONCAT(quantity, order_id);")
UPDATE_CONCAT
false
DIFF00000002897
mentioned_in_comment
Python
reviews_138.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: DELETE FROM invoices; -- now deprecated"""
DELETE_UNQUALIFIED
false
DIFF00000002898
raw_sql_safe
SQL
payments_988.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM products WHERE role = 'active';
NONE
false
DIFF00000002899
mentioned_in_comment
Python
notifications_710.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'DROP TABLE accounts;' manually, handled by migration tool
DROP_TABLE
false