Identification and marking of SQL script keywords within a Word document

Asked

Viewed 92 times

0

I am making a system error manual for the company where I work. Within this manual you will have a description of the error as well as its solution. Many of the solutions are very extensive SQL scripts.

I wonder if it is possible to mark (leave in bold and other color) the keywords only within the script area, such as: SELECT, UPDATE, *, FROM, WHERE.. etc..

Just as it is used in forums, the Dropbox pages, etc. It can be similar to something that is done right here in stackoverflow, ex:

SELECT * FROM teste;
  • I believe your question is outside the scope of the site. However, I suggest you do not do this in Word. Use another type of documentation tool, one that is based on HTML+CSS. Use some Wiki type tool (where I work we use Twiki exactly for what you are doing).

  • 1

    Even, there is a plugin (for Twiki) called Syntaxhighlight. It highlights several languages. Exactly this way you need.

  • Good morning Cantoni, why would I be out of the scope? About Twiki, I did not know the tool and it is very interesting, mainly of several people are interacting. It would be something similar to the trello, or even the Vernote group?

  • 2

    It’s outside the scope because it’s not about programming. The advantage of Twiki (and other types of collaborative tools are this), several people can interact, change the content, finally contribute. Generally, documentation tends to go out of date. Word potentiates this problem as it is not a collaborative tool. You need to keep copying the file and sending it to each other to change, or share it in a folder, it doesn’t work.

1 answer

2


What you want is syntax highlighting (Syntax Highlighting).

Using the Notepad++ and the plugin Nppexport you can do this.

First select the syntax you will use through the menu Language » S » SQL.

Write your code and then to export to Word go to Plugins » Nppexport » Copy all formats to Clipboard.

Then just paste into Word using the Ctrl + V

Browser other questions tagged

You are not signed in. Login or sign up in order to post.