Export file to External SQL Database (BLOB)

KlaasFeenstraKlaasFeenstra Member Posts: 35
edited 2010-06-06 in SQL General
Hello,

I need to store scanned purchase invoices into an external SQL database. How can I do this. Once stored in this external database I also need to read this Blob file from Navision.

Thanks in advance.

Klaas

Comments

  • Lars_WestmanLars_Westman Member Posts: 116
    I suggest that you never store the scanned image in a blob in the first place. Otherwise You might end up with a huge database in the end. I helped a customer some time a go which had 15GB scanned images in the database. Someone thought it was a good idea to scan with higer resolution and the size of the files went up.

    A better solution is to store the images outside the database and then You just need to pass the path and filename to the other database.

    /Lars
  • KlaasFeenstraKlaasFeenstra Member Posts: 35
    Hello Lars,

    For this reason I don't want to create the blobs in the same database as Navision, for some other clients we save it directly on a file server, but this client wants to have it into a database because of an easier control of access. If it is on a file server everybody can access all invoices and for the client it is not acceptable.

    Thanks,

    Klaas
  • Lars_WestmanLars_Westman Member Posts: 116
    OK.

    You can access an external database through views that You define in the NAV database. That way You can access that data almost as if it was inside NAV. I have done that several times but I have not tried it with blob fields though. It might be worth a try.
  • kinekine Member Posts: 12,562
    ...but this client wants to have it into a database because of an easier control of access. If it is on a file server everybody can access all invoices and for the client it is not acceptable.

    What about folder permissions, permission groups in AD etc.? Or they are missing file access management? :wink:
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • strykstryk Member Posts: 645
    I also suggest to look into the FILESTREAM feature of SQL Server 2008 (does not necessarily apply to NAV db but maybe the external one) which allows you to store the image etc. within the file-system but still provides transactional control!
    Jörg A. Stryk (MVP - Dynamics NAV)
    NAV/SQL Performance Optimization & Troubleshooting
    STRYK System Improvement
    The Blog - The Book - The Tool
Sign In or Register to comment.