Re: Display BYTE in HTML generated by 4gl cgi
Posted in 1999
Topics: Stored Procedures & SPL, Connectivity: ESQL/C, 4GL & Embedded SQL, Data Types & Schema Design, Migration, Import/Export & Data Conversion
"Art S. Kagel" escribis: > > Sky, > > 4GL has no facility to easily extract a BYTE. You must write an ESQL/C > module, callable from 4GL, that will set up the database to write the BLOB Sorry, but isn't it the same as for TEXT data type? For this type of varible you do: DEFINE mytextvar TEXT -- (May be BYTE for this case?) LOCATE mytextvar IN "/tmp/myfile.txt" -- maybe myfile.jpg SELECT mytexcol INTO mytextvar FROM mytable WHERE condition... -- then you free the file with LOCATE mytextvar IN MEMORY > into a local file. There are examples of how to do this in the ESQL > manual and the sample code directory. 4GL 6.00 will compile MOST > straightforward ESQL/C so you may be able to use the c4gl compiler to do > this if you do not have ESQL/C. If you use RDS and do not have ESQL/C you > are out of luck. If you do you just link the function into a custom > runner. > > Art S. Kagel > > southwel@my-deja.com wrote: > > > > I've written a cgi program (INFORMIX-4GL Version > > 6.00.UE3) that works very well at querying and > > displaying data from an IDS database to an HTML > > page. Problem: I now have a need to display a > > BYTE value (JPG). I realize the IMG tag needs a > > URI, so I am attempting to save the BYTE to a temp > > file, then display that. UNLOAD give a HEX dump > > that is of no use, and REPORT simply writes 'BYTE > > value' into the file, also of no use. > > > > I know the byte value is O.K., as I am able to use > > DELPHI to store and retrieve the value. > > > > Aside from buying the Universal server options, is > > there a way to display a BYTE in a browser? Has > > anyone done this? > > > > ===== > > Sky Southwell > > Data Management > > Maricopa County Attorney's Office > > Phoenix, AZ 85003 > > southwel@mcao.maricopa.gov > > > > Sent via Deja.com http://www.deja.com/ > > Share what you know. Learn what you don't. Byte byte! -- Mario R. Canto mcanto@intec.unl.edu.ar mcanto@intec.arcride.edu.ar http://www.intec.unl.edu.ar/~mcanto