[JBoss JIRA] (TEIID-2572) Add native-query functionality to pushdown functions
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2572?page=com.atlassian.jira.plugin... ]
Steven Hawkins resolved TEIID-2572.
-----------------------------------
Resolution: Done
Added native-query support to functions and updated the release notes/docs.
> Add native-query functionality to pushdown functions
> ----------------------------------------------------
>
> Key: TEIID-2572
> URL: https://issues.jboss.org/browse/TEIID-2572
> Project: Teiid
> Issue Type: Enhancement
> Components: Connector API
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
> Fix For: 8.5
>
>
> Source functions should also support the parameterized native-query extension property to easily add calls that use non-standard or mapped function syntax.
> For an operator like pg bit shift left:
> {code}
> create foreign function bsl (arg1 integer, arg2 integer) returns integer OPTIONS ("teiid_rel:native-query" '$1 << $2')
> {code}
> For an oracle sequence:
> {code}
> create foreign function seq_nextval () returns integer OPTIONS ("teiid_rel:native-query" 'seq.nextval')
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (TEIID-2567) issues with permission element in vdb-deployer.xsd contains problematic choice node
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2567?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-2567:
---------------------------------------
Yes, I spoke too quickly. An extra element is not desirable.
> We can manage the limitations/issues with allowable choices for attributes in Designer/VDB Editor, if attributes are a cleaner for you guys.
Attributes aren't inherently "cleaner" it's just if we were to pursue that change we would make things more concise from an xml perspective:
{code}
<grant on="table" name="x.foo" select="true" insert="true"/>
{code}
vs.
{code}
<permission>
<resource-name>x.foo</resource-name>
<allow-read>true</allow-read>
<allow-create>true</allow-create>
</permission>
{code}
longer term though we should have DDL support so this is just an intermediate state. I'm fine if we just put all of the allows under a single sequence for now.
> issues with permission element in vdb-deployer.xsd contains problematic choice node
> -----------------------------------------------------------------------------------
>
> Key: TEIID-2567
> URL: https://issues.jboss.org/browse/TEIID-2567
> Project: Teiid
> Issue Type: Task
> Affects Versions: 8.4
> Reporter: Barry LaFond
> Assignee: Steven Hawkins
> Fix For: 8.4.1
>
>
> Having a lot of trouble trying to tweak our JaxB VDB element classes to accommodate the permission's choice node which contains a <sequence> and an <element>.
> This structure is basically impossible to unmarshall using JAXB annotations (i.e. @XmlElements(value= {}) )
> Would clean things up to convert the <allow-language> element to an attribute: <xs:attribute name="allow-language" type="xs:boolean"/> and place it on the <permission> element AND remove the <choice> node entirely
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (TEIID-2567) issues with permission element in vdb-deployer.xsd contains problematic choice node
by Ramesh Reddy (JIRA)
[ https://issues.jboss.org/browse/TEIID-2567?page=com.atlassian.jira.plugin... ]
Ramesh Reddy commented on TEIID-2567:
-------------------------------------
That adds a extra element that will not be compatible with whole lot more cases than moving the allows-language inside the sequence.
> issues with permission element in vdb-deployer.xsd contains problematic choice node
> -----------------------------------------------------------------------------------
>
> Key: TEIID-2567
> URL: https://issues.jboss.org/browse/TEIID-2567
> Project: Teiid
> Issue Type: Task
> Affects Versions: 8.4
> Reporter: Barry LaFond
> Assignee: Steven Hawkins
> Fix For: 8.4.1
>
>
> Having a lot of trouble trying to tweak our JaxB VDB element classes to accommodate the permission's choice node which contains a <sequence> and an <element>.
> This structure is basically impossible to unmarshall using JAXB annotations (i.e. @XmlElements(value= {}) )
> Would clean things up to convert the <allow-language> element to an attribute: <xs:attribute name="allow-language" type="xs:boolean"/> and place it on the <permission> element AND remove the <choice> node entirely
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (TEIID-1131) Document/expand sequence support
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-1131?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-1131:
---------------------------------------
With TEIID-2571 and TEIID-2572 it is straight-forward to represent sequences as source functions. For sequences an Oracle example would be:
{code}
create foreign function seq_nextval () returns integer OPTIONS ("teiid_rel:native-query" 'seq.nextval')
{code}
could be called through Teiid as:
{code}
SELECT seq_nextval()
{code}
and would result in the source sql:
{code}
SELECT seq.nextval FROM DUAL
{code}
The same approach will work for postgresql, db2, etc. We still will want to consider if a proper metadata/calling mechanism should be added and what to offer on import (for pg/oracle at least sequences can be obtained through just DatabaseMetaData).
> Document/expand sequence support
> --------------------------------
>
> Key: TEIID-1131
> URL: https://issues.jboss.org/browse/TEIID-1131
> Project: Teiid
> Issue Type: Feature Request
> Components: JDBC Connector, Query Engine
> Affects Versions: 7.0
> Reporter: Steven Hawkins
> Assignee: Steven Hawkins
>
> Currently sequence workaround logic only exists for oracle and is undocumented. We should look at expanding sequence support - even for dynamic vdbs, see SQuriel's handling of system queries for retrieving sequence metadata.
> At least allowing the workaround logic to work for all sources that support sequences (Postgres, DB2, etc.) would be good.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (TEIID-2572) Add native-query functionality to pushdown functions
by Steven Hawkins (JIRA)
Steven Hawkins created TEIID-2572:
-------------------------------------
Summary: Add native-query functionality to pushdown functions
Key: TEIID-2572
URL: https://issues.jboss.org/browse/TEIID-2572
Project: Teiid
Issue Type: Enhancement
Components: Connector API
Reporter: Steven Hawkins
Assignee: Steven Hawkins
Fix For: 8.5
Source functions should also support the parameterized native-query extension property to easily add calls that use non-standard or mapped function syntax.
For an operator like pg bit shift left:
{code}
create foreign function bsl (arg1 integer, arg2 integer) returns integer OPTIONS ("teiid_rel:native-query" '$1 << $2')
{code}
For an oracle sequence:
{code}
create foreign function seq_nextval () returns integer OPTIONS ("teiid_rel:native-query" 'seq.nextval')
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (TEIID-2567) issues with permission element in vdb-deployer.xsd contains problematic choice node
by Steven Hawkins (JIRA)
[ https://issues.jboss.org/browse/TEIID-2567?page=com.atlassian.jira.plugin... ]
Steven Hawkins commented on TEIID-2567:
---------------------------------------
If you can confirm that JAXB likes the above, then I don't see any issue with that change.
> issues with permission element in vdb-deployer.xsd contains problematic choice node
> -----------------------------------------------------------------------------------
>
> Key: TEIID-2567
> URL: https://issues.jboss.org/browse/TEIID-2567
> Project: Teiid
> Issue Type: Task
> Affects Versions: 8.4
> Reporter: Barry LaFond
> Assignee: Steven Hawkins
> Fix For: 8.4.1
>
>
> Having a lot of trouble trying to tweak our JaxB VDB element classes to accommodate the permission's choice node which contains a <sequence> and an <element>.
> This structure is basically impossible to unmarshall using JAXB annotations (i.e. @XmlElements(value= {}) )
> Would clean things up to convert the <allow-language> element to an attribute: <xs:attribute name="allow-language" type="xs:boolean"/> and place it on the <permission> element AND remove the <choice> node entirely
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months
[JBoss JIRA] (TEIID-2567) issues with permission element in vdb-deployer.xsd contains problematic choice node
by Barry LaFond (JIRA)
[ https://issues.jboss.org/browse/TEIID-2567?page=com.atlassian.jira.plugin... ]
Barry LaFond commented on TEIID-2567:
-------------------------------------
We can manage the limitations/issues with allowable choices for attributes in Designer/VDB Editor, if attributes are a cleaner for you guys.
As far as keeping a choice node option, I'd push for creating a complex type <data-access> so the xsd would read as below. This would allow additional choices in the future if you envisioned them... being added.
{code:xml}
<xs:element name="permission" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:element name="resource-name" type="xs:string"/>
<xs:choice>
<element name="data-access" type="dataaccess"/>
<element name="allow-language" type="xs:boolean"/>
</xs:choice>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:complexType name="dataaccess">
<xs:sequence>
<xs:element name="allow-create" type="xs:boolean" minOccurs="0"/>
<xs:element name="allow-read" type="xs:boolean" minOccurs="0"/>
<xs:element name="allow-update" type="xs:boolean" minOccurs="0"/>
<xss:element name="allow-delete" type="xs:boolean" minOccurs="0"/>
<xs:element name="allow-execute" type="xs:boolean" minOccurs="0"/>
<xs:element name="allow-alter" type="xs:boolean" minOccurs="0"/>
<xs:element name="condition" minOccurs="0">
<xs:complexType>
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute name="constraint" type="xs:boolean" default="true"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
</xs:element>
<xs:element name="mask" minOccurs="0">
<xs:complexType>
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute name="order" type="xs:string"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
{code}
> issues with permission element in vdb-deployer.xsd contains problematic choice node
> -----------------------------------------------------------------------------------
>
> Key: TEIID-2567
> URL: https://issues.jboss.org/browse/TEIID-2567
> Project: Teiid
> Issue Type: Task
> Affects Versions: 8.4
> Reporter: Barry LaFond
> Assignee: Steven Hawkins
> Fix For: 8.4.1
>
>
> Having a lot of trouble trying to tweak our JaxB VDB element classes to accommodate the permission's choice node which contains a <sequence> and an <element>.
> This structure is basically impossible to unmarshall using JAXB annotations (i.e. @XmlElements(value= {}) )
> Would clean things up to convert the <allow-language> element to an attribute: <xs:attribute name="allow-language" type="xs:boolean"/> and place it on the <permission> element AND remove the <choice> node entirely
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 9 months