Results 1 to 5 of 5

Thread: Store and Retrieve File To and From Database using ADO

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Oct 1999
    Location
    NY, USA.
    Posts
    240

    Question

    Hi,
    How can I use ADO to store and retrieve a file from a
    database. What are some things that I need to know or do?

    Omar
    [email protected]
    http://omar.caribwalk.com
    To God Be The Glory

    I see Tech People ...

  2. #2
    Addicted Member
    Join Date
    Jan 2000
    Location
    Sydney, Australia
    Posts
    196
    to give us a bit of a hand, when you say you want to store a file to a database, what database are you using, how big is the file, is it a text file?

    this might help you get a better answer...


  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Oct 1999
    Location
    NY, USA.
    Posts
    240

    Database Info

    Hi,
    Thanks for your reply. I'm planning on using a ACCESS
    Database to store image files (JPG,GIF etc..) .

    BTW : Could this also me implemented on a SQL Server?


    Thanks
    Omar
    [email protected]
    http://omar.caribwalk.com
    To God Be The Glory

    I see Tech People ...

  4. #4
    Addicted Member
    Join Date
    Jan 2000
    Location
    Sydney, Australia
    Posts
    196
    ok, i'm not sure 100% on the total solution but i believe you can use memo fields in access to save pictures etc. I've only really used them to store large text fields (greater than 255 characters) and i know they have a max length of about 64000 characters. So this might mean that your pictures cannot be bigger than 64k in size - i'm not sure.

    also - you can use the "appendchunk" method to append binary data to an ado field - so i think you could use this.

    what i'm not sure on is how to read in your binary data from the picture files that you have. I'm still looking for that now...

    hope this might help

    btw i assumed you know how to use ado to put normal data to a database seeing as though you have many posts. is this true?

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Oct 1999
    Location
    NY, USA.
    Posts
    240

    Question

    Hi,
    I know how to store normal data to a database but I
    don't know to use AppendChunk and stuff like that to
    store files to a database. I've recently written a Family
    Address Book Program that uses ADO and I was hoping to
    allow the use to store photos in the next version.

    Take a look at it (full source code.)
    http://www.planetsourcecode.com/vb/s...xtCodeId=10324

    Please Vote If You Like It



    [Edited by omarswan on 08-02-2000 at 11:11 PM]
    Omar
    [email protected]
    http://omar.caribwalk.com
    To God Be The Glory

    I see Tech People ...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width