[Sqlalchemy-tickets] [sqlalchemy] #2925: oracle nested table support
Brought to you by:
zzzeek
|
From: sqlalchemy <mi...@zz...> - 2014-01-28 22:08:11
|
#2925: oracle nested table support
-------------------------+--------------------------------------------
Reporter: zzzeek | Owner: zzzeek
Type: enhancement | Status: new
Priority: medium | Milestone: 0.9.xx
Component: oracle | Severity: very major - up to 2 days
Keywords: | Progress State: in queue
-------------------------+--------------------------------------------
see:
http://www.orafaq.com/wiki/NESTED_TABLE
example:
{{{
#!python
SQL> create or replace type str_list as table of varchar2(256 char) not
null;
2 /
create table foo (id integer primary key, data str_list) nested table data
store as data_tab;
SQL> insert into foo (id, data) values (1, str_list('a', 'b', 'c'));
1 row created.
SQL> select * from foo;
ID
----------
DATA
--------------------------------------------------------------------------------
1
STR_LIST('a', 'b', 'c')
}}}
steps needed:
1. get the above sequence to work in Python - cx_oracle must have some way
to get the data in and out. If cx_oracle doesnt' support custom types
directly, see if string formatting can be used. however bound parameters
must be used.
2. build out an ARRAY type similar to that of Postgresql. We can use
SchemaType here in a similar fashion.
--
Ticket URL: <http://www.sqlalchemy.org/trac/ticket/2925>
sqlalchemy <http://www.sqlalchemy.org/>
The Database Toolkit for Python
|