[teiid-issues] [JBoss JIRA] Updated: (TEIID-962) Create new system function to dump temp table contents to file.

Steve Hawkins (JIRA) jira-events at lists.jboss.org
Mon Jun 7 17:41:38 EDT 2010


     [ https://jira.jboss.org/browse/TEIID-962?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Steve Hawkins updated TEIID-962:
--------------------------------

        Fix Version/s: 7.1
    Affects Version/s: 6.0.0


The file resource adapter will also have the ability to save.  The save will be relative to the configured parent directory.  I would also add a textagg aggregate function to handle the creation of a csv clob:

textagg(expression [as name], ... [DELIMITER char] [QUOTE char] [HEADER] [order by ...])

when header is specified, then all expression must be column references or have names.

usage example:

<file model>.saveFile('newFile.csv', (select textagg(col1, col2, col3 HEADER) from t))

> Create new system function to dump temp table contents to file.  
> -----------------------------------------------------------------
>
>                 Key: TEIID-962
>                 URL: https://jira.jboss.org/browse/TEIID-962
>             Project: Teiid
>          Issue Type: Feature Request
>          Components: Query Engine
>    Affects Versions: 6.0.0
>         Environment: All
>            Reporter: Ken Johnson
>            Assignee: Steve Hawkins
>             Fix For: 7.1
>
>
> A requirement to produce a CSV file reflecting the contents of a query result set so it can be subsequently FTP'd or email'd. In Nov 07 implemented this feature using the exec connector, a shell script and mods to JDBCISQL.  
> Suggested capability:  function will take the following parameters:
> - Temp table name as string
> - Target file name (path qualified) as string
> - Delimiter as string
> When invoked, the specified temp table contents will be written out to the specified file using the specified delimiter to separate the column values.
> This generic capability will allow the CSV file thats needed and subsequently process it with other UDF functionality as necessary.
> Open questions:
> 1. How does file path behave in a clustered environment?  Is it relative to the MM Server install dir or fully qualified?
> Suggest this feature remain undocumented for the short term.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the teiid-issues mailing list