Search Postgresql Archives

Re: rows and array

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



FERREIRA William (COFRAMI) wrote:
i want do to it in a stored procedure using the pl/pgSQL language.
i can't use "ORDER by" because the traitment is very specific.

for example, in oracle syntaxe i can create my own type :
	type recordChild is TABLE OF XDB_CHILD%ROWTYPE
and next when i declare my variable with this type :
	children recordChild;
i can store rows and re-order them like this :
children(i-j) := children(i-j-1);

Well, I'd look at one of three solutions: 1. Functional index to order by 2. Temporary table (read up on EXECUTE and OID caching) 3. pl/perl/python (which are better suited to this sort of thing)

Probably worth looking into functional indexes - might be what you need.
--
  Richard Huxton
  Archonet Ltd

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
   (send "unregister YourEmailAddressHere" to majordomo@xxxxxxxxxxxxxx)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux