I'm learning SQL, and a lot of the examples have | (vertical bar) in function parameters. What does it represent? Like this:
TRUNC(column|expression, decimal places)
between column and expression.
It means "or". In that example you could have a column name or an expression.
A typical method of defining or explaining a grammar is with Backus-Naur Form (BNF) or some variation that is usually much less formal. In BNF, definitions that can have one of two or more choices often show the valid choices separated by a vertical bar. The example you show says that a couple of valid uses of TRUNC are:
TRUNC( somecolumn, 5 )
TRUNC( colA * colB, 8 )
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With