Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » scout » Download file
Download file [message #1751668] Thu, 12 January 2017 11:23 Go to next message
Luka Cavic is currently offline Luka CavicFriend
Messages: 25
Registered: August 2014
Junior Member
Hi, I have some file stored in postgre db, of type bytea

How can I download it from neon?

Thanks
Re: Download file [message #1751672 is a reply to message #1751668] Thu, 12 January 2017 11:39 Go to previous message
Beat Schwarzentrub is currently offline Beat SchwarzentrubFriend
Messages: 87
Registered: November 2010
Member
Try something along the following code:
  @Override
  protected void execClickAction() {
    byte[] content = ...; // read it from your database
    getDesktop().openUri(new BinaryResource("filename.dat", content), OpenUriAction.DOWNLOAD);
  }


Regards,
Beat
Previous Topic:Table and Disable Specific Cells if needed
Next Topic:[neon] Can the JobAPI replace the Eclipse.JobGroup functionality
Goto Forum:
  


Current Time: Wed May 24 00:36:02 GMT 2017

Powered by FUDForum. Page generated in 0.02681 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software