Re: Limit on LONGVARBINARY in MS JDBC driver?
- From: "Sue Purkis" <suepurkis@xxxxxxxxx>
- Date: Wed, 9 Nov 2005 18:23:38 -0500
Charles,
I am using SQL Server and I created the same stored procedure as you did.
My table definition matches yours. The only difference is that my sp name
is attachment_sp. I am able to get back more than 500,000 bytes. Here is
the code that I used -- see if it works for you.
The output from the run:
Trying to connect...
Connected.
please wait... retrieving file. This may take a while.
Length 1555799
The code I used:
System.out.print("Trying to connect...\n");
con = DriverManager.getConnection(url,"test", "test");
System.out.print("Connected.\n");
PreparedStatement ps = con.prepareStatement("{call attachment_sp(?)]}");
ps.setInt(1,4);
ps.execute();
r = ps.getResultSet();
r.next();
System.out.print("please wait... retrieving file. This may take a
while.\n");
byte[] data = r.getBytes(1);
int bytecount = data.length;
System.out.print(" Length " + bytecount + "\n");
con.close();
Sue
DataDirect Technologies
.
- Follow-Ups:
- Re: Limit on LONGVARBINARY in MS JDBC driver?
- From: Charles Krebs
- Re: Limit on LONGVARBINARY in MS JDBC driver?
- References:
- Limit on LONGVARBINARY in MS JDBC driver?
- From: Charles Krebs
- Re: Limit on LONGVARBINARY in MS JDBC driver?
- From: Sue Purkis
- Re: Limit on LONGVARBINARY in MS JDBC driver?
- From: Charles Krebs
- Re: Limit on LONGVARBINARY in MS JDBC driver?
- From: Charles Krebs
- Limit on LONGVARBINARY in MS JDBC driver?
- Prev by Date: Re: Limit on LONGVARBINARY in MS JDBC driver?
- Next by Date: Records saved twice
- Previous by thread: Re: Limit on LONGVARBINARY in MS JDBC driver?
- Next by thread: Re: Limit on LONGVARBINARY in MS JDBC driver?
- Index(es):
Loading