Re: Why exception exporting query result on Derby ?
- From: Arne Vajhøj <arne@xxxxxxxxxx>
- Date: Sun, 27 Apr 2008 11:02:28 -0400
MikeRam wrote:
q="SELECT * FROM "+dbTable+" WHERE "+FieldName+" BETWEEN ? AND ? ORDER BY ID";
q="CALL SYSCS_UTIL.SYSCS_EXPORT_QUERY('"+q+"','"+OutFile+"', null, null, null)";
stm=cn.conn.prepareStatement(q);
stm.setString(1, sd.StringDataOraInizio);
stm.setString(2, sd.StringDataOraFine);
stm.executeUpdate();
I use Apache Derby but,
When i execute the attached code i receive an exception java.sql.SQLException: No input parameters.
The same query in other point of my program do not produce an exception.
Maybe i can't use system procedure with parameter ?
Stored procedures are called via CallableStatement not
PreparedStatement. And with a slightly different syntax.
And I don't think you can use parameters inside '' as you attempt
to do.
Arne
.
- References:
- Why exception exporting query result on Derby ?
- From: MikeRam
- Why exception exporting query result on Derby ?
- Prev by Date: Why exception exporting query result on Derby ?
- Next by Date: Re: Why exception exporting query result on Derby ?
- Previous by thread: Why exception exporting query result on Derby ?
- Next by thread: Re: Why exception exporting query result on Derby ?
- Index(es):
Relevant Pages
|
|