Subject | Re: Beginner needs help |
---|---|
Author | Adam |
Post date | 2008-01-31T22:48:45Z |
--- In firebird-support@yahoogroups.com, "john" <sta_john@...> wrote:
Officially, there is no command line to do it through iSQL. Any
application can do it using a trivial paramatised query, but it is a
bit harder from the command line.
There are however third party tools that probably do something like
what you want. For example, FSQL:
http://www.volny.cz/iprenosil/interbase/fsql.htm
You can run a query like:
INSERT INTO tab(id, pict, thumb) VALUES (1, @'c:\pict.jpg',
@'c:\smallpict.jpg');
It is not official SQL Standard or official Firebird sanctioned
syntax, but useful nonetheless.
Adam
>John,
> After trying to figure this out for while I've decided to swallow my
> pride and post this. Please let me know if there's a different group
> I should post this to.
>
> I need to store an image to a to the DB and I can't seem to figure it
> out. I'd like to use SQL directly in the SQL Editor if possible.
>
> DB = Firebird 2.0 using SQL Hammer's (1.4.1 Community Edition) to run
> SQL.
> Field Type saving to = BLOB SUB_TYPE 0 SEGMENT SIZE 80
> Image File Type = .gif
> File Image Path = c:\anvil.gif
>
> Saving the image to a directory and then saving the path to the DB is
> not an option for this project.
>
> Please advise if I can provide anymore information.
>
> Again, I'm sorry for the simple question, but I just can't seem to
> get the SQL syntax down right.
Officially, there is no command line to do it through iSQL. Any
application can do it using a trivial paramatised query, but it is a
bit harder from the command line.
There are however third party tools that probably do something like
what you want. For example, FSQL:
http://www.volny.cz/iprenosil/interbase/fsql.htm
You can run a query like:
INSERT INTO tab(id, pict, thumb) VALUES (1, @'c:\pict.jpg',
@'c:\smallpict.jpg');
It is not official SQL Standard or official Firebird sanctioned
syntax, but useful nonetheless.
Adam