Following @ipsors post:
http://forums.sqlteam.com/t/stored-proc-with-select-statement-sometimes-returns-the-value/3083/10
I thought it might be helpful to pool any knowledge about how to format posts
Amen to that. I absolutely hate the MarkDown used in this forum. It frequently screws up my post - e.g. completely hiding a whole block of code, or accidentally formatting something I didn't intend to, or leaving a character out.
I would much prefer a mark-up syntax where I am in complete control of the formatting. For example, I have found absolutely no way of highlighting a snippet in a code block, and I see others, too, resorting to "--<<< HERE" comments in the code to try to indicate where they have made a one word / one letter change. The fact that so little first-time-post questions include any code-block markers suggests to me that 99% of the world don't "get" this mark-down stuff (even though it is defacto on StackOverflow - maybe everything is neatly formatted there because of the huge number of Code Tsars who spend their life editing other people's posts to "fix them" ...)
Send me your unformatted code, I'll format it for you, because I have nothing better to do!! (Also fits in nicely with "Doing it Kristen's way" )
Amen!
Here's what little I have found
```
Start / End of a code block. Parsers auto-detects the language
Sometime screws up royally ... it can help to have a blank line before and/or after the ''' lines
'''text
Start of a Text block (end with regular ''', do not end with '''text, cannot use '''TEXT )
'''xxx
Other languages - such as "sql" and "C" (that one does work in uppercase)
Sometimes necessary to use ```sql where parser does not auto-detect correctly
Note that the Preview is Javascript whereas the actual render is something-else, so sometimes they do different things
[code]
[/code]
Sort of works. All blank lines within the code block are suppressed, which screws up the formatting
Then there is the 4-leading-spaces thing, which is what you get if you highlight a block and press the [</>] button. And is also what you get on PART of someone's code that is indented with spaces
SELECT [Foo] = ThisIsAVeryLongColumnName
What happened to the colour formatting there then?
THere's another example (except I can't find it just now ...) where the first ' was not recognised as a String, so everything after that was wrongly formatted. I couldn't find any way to fix that, so I had to post it as text rather than
sql
I haven't found a way to boldface something in the middle of a word? like this aaaBccc
And so on ...