Re: Oracle Style packages on postgres
От | Thomas Hallgren |
---|---|
Тема | Re: Oracle Style packages on postgres |
Дата | |
Msg-id | thhal-02KFcA52kyicjvodABWUq7K94+GDTR8@mailblocks.com обсуждение исходный текст |
Ответ на | Re: Oracle Style packages on postgres ("Jim C. Nasby" <decibel@decibel.org>) |
Список | pgsql-hackers |
Jim C. Nasby wrote: >I guess maybe I'm not clear on what you mean by static methods. IIRC, in >Oracle nomenclature, static means it will retain state between >invocations in the same session. Of course, functions and procedures >that don't do this are also allowed. > > A STATIC prefix on a method simply means that it is not tied to a particular instance of the type where it is defined. You have the type Foo with the method bar(). If the method is STATIC, you can use: SELECT Foo.bar(); If it's an INSTANCE method, you can only call it when you have an instance available, so if FooTable is a table described by the type Foo and bar is non-static, you could write: SELECT x.bar() FROM FooTable x; >I think both should allow for private functions/procedures/methods. BTW, >I'm also very keen on the idea of nested schemas, which is another >possible means to the package ends. > > I'd like that too although I don't think it's included in the SQL-standard. Regards, Thomas Hallgren
В списке pgsql-hackers по дате отправления: