|
-
Jun 25th, 2007, 01:49 PM
#1
[RESOLVED] sql insert picture
how can i use a sql insert statement to insert a picture?
i know i need to use a binary field in my database, and its called blob, but i'm not sure how to insert pictures.
thanks
-
Jun 25th, 2007, 01:51 PM
#2
Re: sql insert picture
Look up AppendChunk and GetChunk.... they are the methods by which one moves data into (AppendChunk) and out of (GetChunk) binary fields.
-tg
-
Jun 25th, 2007, 02:42 PM
#3
Re: sql insert picture
would that work with an access database + classic ado?
-
Jun 25th, 2007, 03:14 PM
#4
Re: sql insert picture
yes on both accounts.
-tg
-
Jun 25th, 2007, 03:25 PM
#5
Re: sql insert picture
ok thanks i'll look it up
-
Jun 25th, 2007, 03:26 PM
#6
Re: sql insert picture
See our FAQs & Tutorials at the top of this forum - there is a tutorial specifically about this.
-
Jun 26th, 2007, 01:52 PM
#7
Re: sql insert picture
[My Two Cents] unless you need to secure your pictures in a database, I think you would be better off saving the pictures as JPegs and then store the path to the picture in the database. Much more efficient usage of disk space.[/My Two Cents]
Regards,
Mark
Please remember to rate posts! Rate any post you find helpful. Use the link to the left - "Rate this Post". Please use [highlight='vb'] your code goes in here [/highlight] tags when posting code. When a question you asked has been resolved, please go to the top of the original post and click "Thread Tools" then select "Mark Thread Resolved."
-
Jun 26th, 2007, 02:08 PM
#8
Re: sql insert picture
In most cases, I would agree.... but we use BLOBs in our app for convience as well.... when ever we have to roll out a new report, or modify an existing one, we stuff it into our DB, then run a script that create a script that inserts the bits... and ship the script off to the necessary client(s). We wouldn't be able to easily deploy things like that other wise. We thought about network shares bvut some of our clients have some extremely strict rules that don't make that a viable option. Plus we also do it to store incoming data that we can later extract for auditing purposes (to get back to the original).
-tg
-
Jun 26th, 2007, 06:44 PM
#9
Re: sql insert picture
i reconsidered and decided to save the filenames.
the pictures might be quite large.
thanks for all your help
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|