3.5. Line
Prev | Up | Chapter 3. Data Types | Home | Next

## 3.5. Line #

A spherical line is part of a great circle (meridian) that has a beginning and an end and hence, a direction. Use cases are:

- direct connection of two points

- meteors on the sky sphere

To allow lines with a length larger than 180°, the input i syntax is a somewhat complex.

A general located line with a length `length` is defined as a line starting at position `(0d,0d)` and ending at position `(length,0d)` transformed with an Euler transformation `euler`. The input syntax is :

    ( euler ), length

### Note

- For a simpler line input, use casting operators (Section 5.1) or constructor functions (Chapter 4).

- If the length is larger than 360°, the line length is truncated to 360°.

- The transformation `euler` will always be converted to an Euler transformation using axes `Z`, `X`, and `Z`.

Example 3.8. A line input

A line starting at position `(200d,+20d)` and ending at position `(200d,-10d)`.

    sql> SELECT sline '( -90d, -20d, 200d, XYZ ), 30d ';

Prev | Up | Next
3.4. Circle | Home | 3.6. Ellipses