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
DIFF00000004500
orm_schema_change
JavaScript
users_206.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('subscriptions', table => table.dropColumn('price'))
NONE
true
DIFF00000004501
raw_sql_safe
SQL
invoices_827.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM shipments WHERE metadata = 'active';
NONE
false
DIFF00000004502
obfuscated_destructive
SQL
sessions_445.sql
schema cleanup
@@ -1,3 +1,3 @@ +altEr TABLe ORdErS REnaME coLumN PrioRiTy To contacT_emAIl;
ALTER_RENAME
true
DIFF00000004503
general_code_change
Ruby
transactions_94.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004504
orm_schema_change
JavaScript
orders_869.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('inventory', table => table.dropColumn('created_at'))
NONE
true
DIFF00000004505
general_code_change
JavaScript
tickets_319.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
DIFF00000004506
orm_schema_change
Ruby
comments_123.rb
rails migration: drop unused field
@@ -1,3 +1,3 @@ +remove_column :events, :role
NONE
true
DIFF00000004507
general_code_change
JavaScript
logs_726.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004508
raw_sql_destructive
SQL
invoices_492.sql
update schema
@@ -1,3 +1,3 @@ +DELETE FROM tickets;
DELETE_UNQUALIFIED
true
DIFF00000004509
general_code_change
Python
employees_770.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004510
raw_sql_safe
SQL
events_571.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE payments SET role = %s WHERE order_id = %s;
NONE
false
DIFF00000004511
general_code_change
JavaScript
invoices_598.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004512
raw_sql_safe
SQL
tickets_727.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM logs WHERE status = 'active';
NONE
false
DIFF00000004513
raw_sql_destructive
SQL
refunds_690.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE events RENAME COLUMN user_id TO state;
ALTER_RENAME
true
DIFF00000004514
raw_sql_destructive
SQL
users_735.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE products DROP COLUMN score;
DROP_COLUMN
true
DIFF00000004515
raw_sql_safe
SQL
tickets_420.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM notifications WHERE order_id = 'active';
NONE
false
DIFF00000004516
general_code_change
Ruby
employees_767.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004517
test_suite_cleanup
SQL
spec/refunds_515.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +DELETE FROM events;
DELETE_UNQUALIFIED
false
DIFF00000004518
raw_sql_safe
SQL
invoices_379.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE refunds SET priority = %s WHERE metadata = %s;
NONE
false
DIFF00000004519
general_code_change
JavaScript
subscriptions_364.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004520
general_code_change
Ruby
reviews_988.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004521
raw_sql_safe
SQL
products_568.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE orders SET user_id = %s WHERE name = %s;
NONE
false
DIFF00000004522
raw_sql_destructive
SQL
payments_206.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE transactions SET order_id = CONCAT(order_id, priority);
UPDATE_CONCAT
true
DIFF00000004523
raw_sql_safe
SQL
accounts_406.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM products WHERE quantity = 'active';
NONE
false
DIFF00000004524
raw_sql_safe
SQL
customers_171.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_shipments_name ON shipments (metadata);
NONE
false
DIFF00000004525
orm_schema_change
TypeScript
tickets_833.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Inventory { // removed field: name }
NONE
true
DIFF00000004526
raw_sql_safe
SQL
products_985.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO accounts (amount, address) VALUES (%s, %s);
NONE
false
DIFF00000004527
raw_sql_safe
SQL
logs_829.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE invoices ADD COLUMN state VARCHAR(255);
NONE
false
DIFF00000004528
raw_sql_destructive
SQL
subscriptions_695.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE subscriptions SET name = CONCAT(name, status);
UPDATE_CONCAT
true
DIFF00000004529
raw_sql_safe
SQL
notifications_946.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE reviews SET balance = %s WHERE phone = %s;
NONE
false
DIFF00000004530
mentioned_in_comment
Python
products_577.py
add warning comment
@@ -1,3 +1,3 @@ +logger.warning("Skipping legacy query: DELETE FROM accounts;")
DELETE_UNQUALIFIED
false
DIFF00000004531
raw_sql_destructive
SQL
employees_551.sql
update schema
@@ -1,3 +1,3 @@ +TRUNCATE TABLE tickets;
TRUNCATE
true
DIFF00000004532
raw_sql_safe
SQL
comments_574.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE shipments ADD COLUMN full_name VARCHAR(255);
NONE
false
DIFF00000004533
obfuscated_destructive
SQL
notifications_428.sql
schema cleanup
@@ -1,3 +1,3 @@ +Drop TaBLe RevIeWs;
DROP_TABLE
true
DIFF00000004534
raw_sql_safe
SQL
invoices_187.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO tickets (metadata, user_id) VALUES (%s, %s);
NONE
false
DIFF00000004535
general_code_change
Ruby
logs_295.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004536
general_code_change
TypeScript
employees_569.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
DIFF00000004537
general_code_change
JavaScript
reviews_405.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004538
orm_schema_change
JavaScript
comments_629.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('shipments', 'is_active')
NONE
true
DIFF00000004539
orm_schema_change
JavaScript
notifications_319.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('subscriptions', table => table.dropColumn('updated_at'))
NONE
true
DIFF00000004540
orm_schema_change
TypeScript
products_180.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Sessions { // removed field: quantity }
NONE
true
DIFF00000004541
test_suite_cleanup
SQL
mysql-test/suite/logs_600.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE products SET user_id = CONCAT(user_id, metadata);
UPDATE_CONCAT
false
DIFF00000004542
general_code_change
Python
employees_793.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004543
obfuscated_destructive
SQL
accounts_1.sql
schema cleanup
@@ -1,3 +1,3 @@ +DROP TABLE tickets;
DROP_TABLE
true
DIFF00000004544
raw_sql_safe
SQL
products_651.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +SELECT * FROM reviews WHERE balance = 'active';
NONE
false
DIFF00000004545
raw_sql_destructive
SQL
orders_29.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE accounts;
DROP_TABLE
true
DIFF00000004546
orm_schema_change
JavaScript
customers_507.js
sequelize migration: drop unused field
@@ -1,3 +1,3 @@ +queryInterface.removeColumn('refunds', 'score')
NONE
true
DIFF00000004547
mentioned_in_comment
Python
accounts_898.py
add warning comment
@@ -1,3 +1,3 @@ +# NOTE: do not run 'ALTER TABLE shipments DROP COLUMN category;' manually, handled by migration tool
DROP_COLUMN
false
DIFF00000004548
test_suite_cleanup
SQL
test/payments_913.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE refunds DROP COLUMN email;
DROP_COLUMN
false
DIFF00000004549
mentioned_in_comment
Python
comments_257.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: ALTER TABLE notifications DROP COLUMN score; -- now deprecated"""
DROP_COLUMN
false
DIFF00000004550
test_suite_cleanup
SQL
mysql-test/suite/customers_358.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE reviews RENAME COLUMN is_active TO full_name;
ALTER_RENAME
false
DIFF00000004551
raw_sql_destructive
SQL
invoices_519.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE reviews DROP COLUMN category;
DROP_COLUMN
true
DIFF00000004552
orm_schema_change
JavaScript
notifications_853.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('notifications', table => table.dropColumn('description'))
NONE
true
DIFF00000004553
general_code_change
TypeScript
comments_111.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
DIFF00000004554
raw_sql_destructive
SQL
customers_964.sql
update schema
@@ -1,3 +1,3 @@ +DROP TABLE sessions;
DROP_TABLE
true
DIFF00000004555
general_code_change
Java
sessions_397.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000004556
test_suite_cleanup
SQL
test/comments_443.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE logs SET price = CONCAT(price, address);
UPDATE_CONCAT
false
DIFF00000004557
raw_sql_safe
SQL
users_524.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_notifications_updated_at ON notifications (created_at);
NONE
false
DIFF00000004558
raw_sql_safe
SQL
tickets_802.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +INSERT INTO refunds (score, priority) VALUES (%s, %s);
NONE
false
DIFF00000004559
general_code_change
Ruby
customers_125.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004560
test_suite_cleanup
SQL
tests/notifications_902.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE customers DROP COLUMN amount;
DROP_COLUMN
false
DIFF00000004561
raw_sql_safe
SQL
tickets_655.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_products_priority ON products (description);
NONE
false
DIFF00000004562
test_suite_cleanup
SQL
tests/notifications_655.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE refunds DROP COLUMN score;
DROP_COLUMN
false
DIFF00000004563
general_code_change
Ruby
shipments_300.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004564
raw_sql_safe
SQL
events_28.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE notifications SET metadata = %s WHERE score = %s;
NONE
false
DIFF00000004565
general_code_change
JavaScript
shipments_281.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004566
test_suite_cleanup
SQL
tests/users_840.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +TRUNCATE TABLE shipments;
TRUNCATE
false
DIFF00000004567
orm_schema_change
TypeScript
shipments_242.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Invoices { // removed field: user_id }
NONE
true
DIFF00000004568
general_code_change
Ruby
shipments_560.rb
refactor / feature work
@@ -1,3 +1,3 @@ +def full_name "#{first_name} #{last_name}" end
NONE
false
DIFF00000004569
obfuscated_destructive
SQL
shipments_486.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM accounts;
DELETE_UNQUALIFIED
true
DIFF00000004570
orm_schema_change
Python
products_580.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='tickets', name='balance')
NONE
true
DIFF00000004571
raw_sql_safe
SQL
employees_481.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_tickets_metadata ON tickets (role);
NONE
false
DIFF00000004572
raw_sql_safe
SQL
shipments_635.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_comments_is_active ON comments (user_id);
NONE
false
DIFF00000004573
test_suite_cleanup
SQL
spec/transactions_885.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +ALTER TABLE orders RENAME COLUMN email TO amount_cents;
ALTER_RENAME
false
DIFF00000004574
general_code_change
Python
customers_819.py
refactor / feature work
@@ -1,3 +1,3 @@ +def calculate_total(items): return sum(i.price for i in items)
NONE
false
DIFF00000004575
raw_sql_destructive
SQL
tickets_265.sql
update schema
@@ -1,3 +1,3 @@ +UPDATE payments SET status = CONCAT(status, priority);
UPDATE_CONCAT
true
DIFF00000004576
general_code_change
Python
shipments_82.py
refactor / feature work
@@ -1,3 +1,3 @@ +class Cache: def __init__(self): self._store = {}
NONE
false
DIFF00000004577
raw_sql_safe
SQL
notifications_461.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE payments SET email = %s WHERE quantity = %s;
NONE
false
DIFF00000004578
general_code_change
Go
invoices_987.go
refactor / feature work
@@ -1,3 +1,3 @@ +func HandleRequest(w http.ResponseWriter, r *http.Request) { fmt.Fprintln(w, "ok") }
NONE
false
DIFF00000004579
obfuscated_destructive
SQL
orders_630.sql
schema cleanup
@@ -1,3 +1,3 @@ +DELETE FROM accounts;
DELETE_UNQUALIFIED
true
DIFF00000004580
general_code_change
JavaScript
sessions_338.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004581
raw_sql_safe
SQL
comments_266.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE sessions ADD COLUMN state VARCHAR(255);
NONE
false
DIFF00000004582
mentioned_in_comment
Python
employees_684.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: TRUNCATE TABLE products; -- now deprecated"""
TRUNCATE
false
DIFF00000004583
obfuscated_destructive
SQL
subscriptions_900.sql
schema cleanup
@@ -1,3 +1,3 @@ +TRUNCATE TABLE subscriptions;
TRUNCATE
true
DIFF00000004584
general_code_change
JavaScript
subscriptions_595.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004585
obfuscated_destructive
SQL
products_897.sql
schema cleanup
@@ -1,3 +1,3 @@ +DrOP taBle revIEWs;
DROP_TABLE
true
DIFF00000004586
orm_schema_change
Python
customers_383.py
django migration: drop unused field
@@ -1,3 +1,3 @@ +migrations.RemoveField(model_name='notifications', name='user_id')
NONE
true
DIFF00000004587
orm_schema_change
JavaScript
shipments_190.js
knex migration: drop unused field
@@ -1,3 +1,3 @@ +knex.schema.table('transactions', table => table.dropColumn('quantity'))
NONE
true
DIFF00000004588
orm_schema_change
TypeScript
transactions_726.ts
prisma migration: drop unused field
@@ -1,3 +1,3 @@ +model Users { // removed field: created_at }
NONE
true
DIFF00000004589
raw_sql_destructive
SQL
sessions_349.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE transactions DROP COLUMN phone;
DROP_COLUMN
true
DIFF00000004590
raw_sql_safe
SQL
events_444.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE orders SET role = %s WHERE name = %s;
NONE
false
DIFF00000004591
general_code_change
Java
comments_690.java
refactor / feature work
@@ -1,3 +1,3 @@ +public class UserService { public User findById(Long id) { return repo.find(id); } }
NONE
false
DIFF00000004592
raw_sql_safe
SQL
invoices_853.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE accounts ADD COLUMN user_role VARCHAR(255);
NONE
false
DIFF00000004593
mentioned_in_comment
Python
payments_114.py
add warning comment
@@ -1,3 +1,3 @@ +"""This function used to run: UPDATE tickets SET status = CONCAT(status, quantity); -- now deprecated"""
UPDATE_CONCAT
false
DIFF00000004594
raw_sql_safe
SQL
subscriptions_551.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +UPDATE transactions SET metadata = %s WHERE user_id = %s;
NONE
false
DIFF00000004595
test_suite_cleanup
SQL
tests/tickets_980.sql
test cleanup fixture
@@ -1,3 +1,3 @@ +UPDATE orders SET metadata = CONCAT(metadata, email);
UPDATE_CONCAT
false
DIFF00000004596
raw_sql_destructive
SQL
refunds_574.sql
update schema
@@ -1,3 +1,3 @@ +ALTER TABLE tickets RENAME COLUMN status TO user_role;
ALTER_RENAME
true
DIFF00000004597
general_code_change
JavaScript
logs_820.js
refactor / feature work
@@ -1,3 +1,3 @@ +function formatDate(d) { return d.toISOString(); }
NONE
false
DIFF00000004598
raw_sql_safe
SQL
reviews_426.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +ALTER TABLE reviews ADD COLUMN amount_cents VARCHAR(255);
NONE
false
DIFF00000004599
raw_sql_safe
SQL
accounts_21.sql
add index / minor schema tweak
@@ -1,3 +1,3 @@ +CREATE INDEX idx_payments_price ON payments (price);
NONE
false