Emojis in SQL in ICM InfoWorks - 6 Functions ๐Ÿงฎ

6 Functions ๐Ÿงฎ

SQL expressions can utilize a myriad of functions alongside field values and constants. Each function needs a set number of 'arguments' and yields one value.

6.1 Aggregate functions ๐Ÿ“Š

Refer to Section 10.3 for details.

6.2 Date functions ๐Ÿ“†

  • YEARPART ๐Ÿ“…
    YEARPART(date) - Retrieves the year of the date.

  • MONTHPART ๐Ÿ“†
    MONTHPART(date) - Determines the month of the date.

  • DAYPART ๐ŸŒž
    DAYPART(date) - Extracts the day from the date.

  • DATEPART ๐Ÿ—“
    DATEPART(date) - Provides the date while removing minutes.

  • TIMEPART
    TIMEPART(date) - Gives the time in minutes from the date.

  • YEARMONTHPART ๐Ÿ“…๐Ÿ“†
    YEARMONTHPART(date) - Shows year and month as a string.

  • MONTHYEARPART ๐Ÿ“†๐Ÿ“…
    MONTHYEARPART(date) - Displays month and year in a string format.

  • MONTHNAME ๐Ÿ“†
    MONTHNAME(date) - Returns the full month name.

  • SHORTMONTHNAME ๐Ÿ—“
    SHORTMONTHNAME(date) - Gives the abbreviated month name.

  • DAYNAME ๐ŸŒž
    DAYNAME(date) - Fetches the full day name.

  • SHORTDAYNAME ๐ŸŒค
    SHORTDAYNAME(date) - Offers the abbreviated day name.

  • NOW ๐Ÿ•ฐ
    NOW() - Provides the current date and time.

  • YEARSDIFF ๐Ÿ“…⏳
    YEARSDIFF(from,to) - Calculates the year difference between two dates.

  • MONTHSDIFF ๐Ÿ“†⏳
    MONTHSDIFF(from,to) - Determines the month difference between two dates.

  • DAYSDIFF ๐ŸŒž⏳
    DAYSDIFF(from,to) - Measures the day difference between two dates.

... and many more!

6.3 List variable functions ๐Ÿ“

Refer to the List Variables section for more details.

6.4 Trigonometric and logarithmic functions ๐Ÿ“๐Ÿ“ˆ

Covers functions related to angles and logs. Includes functions like ACOS, ASIN, ATAN, LOG, and more.

6.5 String manipulation ๐ŸŽป

Delves into manipulating strings with functions like LEN, LEFT, RIGHT, MID, SUBST, etc.

6.6 Number conversion and formatting ๐Ÿ”ข

Functions like FIXED help in formatting numbers.

6.7 Numerical functions ๐Ÿ”ข๐Ÿ”

Includes functions such as ABS, INT, FLOOR, CEIL and more for number operations.

6.7 Conditional expression ๐Ÿ”„

IIF and NVL functions that help in setting conditions in SQL expressions.