About bitrix-database
A Bitrix database development skill for developers working with ORM and SQL. It documents connection management, safe queries, schema changes, and operational constraints for direct database access.
Key features
- 01Connection configuration and named locks
- 02ORM and SQL query guidance
- 03Placeholder and SqlHelper usage
- 04DDL and index change guidance
- 05SqlTracker debugging guidance
Use cases
- 01Reviewing database connection setup
- 02Writing safe SQL queries and upserts
- 03Changing tables or indexes
- 04Debugging database activity
Install
Copy the command and run it in a terminal.
$
npx skills add https:/ / github.com/ bxmaximum/ bitrix-framework-skills --skill bitrix-databaseAfter installing, type/bitrix-databasein Claude Code to confirm it loaded.
Bundled files
References and scripts installed along with SKILL.md.
rules/connections.mdddl-debug.mdqueries.mdDetails
From the project READMEDirect database access
Baseline: main 23.0+ · Verified: main 26.800.0
ORM first (bitrix-orm: query(), batch writes, merge, deleteByFilter). Drop to SQL for upserts, windows/CTE, heavy reports, extra connections and schema changes.
| Task | Read |
|---|---|
connections config, extra DBs, charset, after-connect hook, named locks | rules/connections.md |
query*, add/addMulti, SqlHelper, placeholders, upsert, transactions | rules/queries.md |
| DDL builders, table/index changes, SqlTracker | rules/ddl-debug.md |
Invariants
- Every value reaches SQL through
SqlExpressionplaceholders orSqlHelper(forSql,convertToDb*). The$bindsargument ofquery()/queryExecute()is not a prepared statement. - Identifiers from input: whitelist first, then
quote()/?#. - Raw writes skip ORM events and cache: call
XxxTable::cleanCache()afterwards. - Portable SQL only: SqlHelper functions, no backticks,
ENGINE,UNSIGNED(bitrix-postgresql). - One connection per transaction; keep transactions short.
Comments
Markdown supported