inlined sql functions in 7.4

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Aleksey Serba

    inlined sql functions in 7.4

    Hi!

    I found the very useful feature into 7.4 release
    [color=blue]
    > Release Notes 7.4:
    > Function-inlining for simple SQL functions
    > Simple SQL functions can now be inlined by including their SQL in the main query.
    > This improves performance by eliminating per-call overhead.
    > That means, simple SQL functions now behave like macros.[/color]

    but, i can't find any docs about syntax :(

    Could you point me in the right direction?

    Thx in advance

    Aleksey


    ---------------------------(end of broadcast)---------------------------
    TIP 6: Have you searched our list archives?



  • Jeff Eckermann

    #2
    Re: inlined sql functions in 7.4

    --- Aleksey Serba <aserba@voltweb .com> wrote:[color=blue]
    > Hi!
    >
    > I found the very useful feature into 7.4 release
    >[color=green]
    > > Release Notes 7.4:
    > > Function-inlining for simple SQL functions
    > > Simple SQL functions can now be inlined by[/color]
    > including their SQL in the main query.[color=green]
    > > This improves performance by eliminating[/color]
    > per-call overhead.[color=green]
    > > That means, simple SQL functions now behave[/color]
    > like macros.
    >
    > but, i can't find any docs about syntax :(
    >
    > Could you point me in the right direction?[/color]

    This happens automatically, i.e. you don't need to do
    anything. It is a performance optimization in the
    backend.
    [color=blue]
    >
    > Thx in advance
    >
    > Aleksey
    >
    >
    > ---------------------------(end of
    > broadcast)---------------------------
    > TIP 6: Have you searched our list archives?
    >
    > http://archives.postgresql.org[/color]


    _______________ _______________ ____
    Do you Yahoo!?
    Get better spam protection with Yahoo! Mail.


    ---------------------------(end of broadcast)---------------------------
    TIP 7: don't forget to increase your free space map settings

    Comment

    • Tom Lane

      #3
      Re: inlined sql functions in 7.4

      Aleksey Serba <aserba@voltweb .com> writes:[color=blue]
      > I found the very useful feature into 7.4 release[color=green]
      >> Function-inlining for simple SQL functions[/color]
      > but, i can't find any docs about syntax :([/color]

      There isn't any --- it happens automatically if the planner thinks it's
      an appropriate transformation.

      regards, tom lane

      ---------------------------(end of broadcast)---------------------------
      TIP 9: the planner will ignore your desire to choose an index scan if your
      joining column's datatypes do not match

      Comment

      • Aleksey Serba

        #4
        Re: inlined sql functions in 7.4

        [color=blue][color=green]
        >> I found the very useful feature into 7.4 release[color=darkred]
        >>> Function-inlining for simple SQL functions[/color]
        >> but, i can't find any docs about syntax :([/color][/color]

        TL> There isn't any --- it happens automatically if the planner thinks it's
        TL> an appropriate transformation.
        TL> regards, tom lane

        Ops. I was mistaken.
        I'm sorry for wasting your time.

        Aleksey


        ---------------------------(end of broadcast)---------------------------
        TIP 6: Have you searched our list archives?



        Comment

        Working...