db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rick Hillegas <rick.hille...@gmail.com>
Subject Re: where condition in CALL SYSCS_UTIL.SYSCS_EXPORT_QUERY fails
Date Thu, 03 Dec 2015 14:40:27 GMT
On 11/30/15 9:02 PM, Anjana Prakash wrote:
> CALL SYSCS_UTIL.SYSCS_EXPORT_QUERY('select t.tablename from 
> sys.systables t,sys.sysschemas s where t.schemaid = s.schemaid and 
> t.tabletype=T','test.txt',null,'/',null);
Hi Anjana,

Your call to SYSCS_UTIL.SYSCS_EXPORT_QUERY() fails because you need to 
single-quote the string literal 'T', which you are using to restrict the 
table type. Note that you need to double the single-quotes in order to 
escape the ' character inside the already single-quoted query string. 
Try this:

CALL SYSCS_UTIL.SYSCS_EXPORT_QUERY('select t.tablename from 
sys.systables t,sys.sysschemas s where t.schemaid = s.schemaid and 
t.tabletype=''T''','test.txt',null,'/',null);

Hope this helps,
-Rick


Mime
View raw message