Книга: Learning GNU Emacs, 3rd Edition

9.7.2.2 Editing mode

9.7.2.2 Editing mode

You can also put a buffer directly into SQL mode with M-x sql-mode. This provides some assistance for motion and composition of SQL statements, but mostly it's there to let you build complex statements and then ship them to the interactive buffer for execution. Table 9-10 shows how to send various segments of the buffer to the database.

Table 9-10. SQL mode send commands

Keystroke Command name Action
C-c C-c sql-send-paragraph Send the paragraph the cursor is on. A paragraph is defined by the particular database client. For the sql-mysql process, for example, a paragraph begins with a statement like select or update and ends with a semicolon. Any number of lines can intervene.
C-c C-r sql-send-region Send the marked region.
C-c C-b sql-send-buffer Send the entire buffer.

The output of all of these send commands shows up in your interactive buffer. Nothing changes in the editing buffer so you should feel free to experiment. That's what these modes are here for!

Оглавление книги

Оглавление статьи/книги

Генерация: 0.084. Запросов К БД/Cache: 0 / 0
поделиться
Вверх Вниз