1. euphoria database
- Posted by buzzo Sep 18, 2014
- 1292 views
receiving this error when writing data (kss-head-1.jpg) to a table (name is photographs):
...\include\std\eds.e:2119 in function db_insert()
subscript value 10 is out of bounds, reading from a sequence of length 9
db_compress() works ok...
2. Re: euphoria database
- Posted by _tom (admin) Sep 18, 2014
- 1241 views
I wrote a small test program:
Testing with "mongoose.jpg" which is a 1K file.
include std/console.e include std/eds.e include std/io.e display( "*** jpg file to use a data" ) object mongoose = read_file( "mongoose.jpg" ) ? length(mongoose) display( "*** create new database or open exising database" ) db_create( "foo" ) db_open( "foo" ) display( "*** create new table or open exising database" ) db_create_table( "jpgs" ) db_select_table( "jpgs" ) display( db_table_list() ) display( db_table_size() ) display( "*** insert record into table" ) db_insert( "one", mongoose ) display( "*** get jpg from database and save as new file" ) integer keynum = db_find_key( "one" ) object jpg = db_record_data( keynum ) write_file( "new_mongoose.jpg", jpg)
This demo works for me. I end up with a copy of the original jpg.
A small test program showing what you are doing is now required.
_tom
3. Re: euphoria database
- Posted by DerekParnell (admin) Sep 18, 2014
- 1239 views
receiving this error when writing data (kss-head-1.jpg) to a table (name is photographs):
...\include\std\eds.e:2119 in function db_insert()
subscript value 10 is out of bounds, reading from a sequence of length 9
db_compress() works ok...
This is not enough information to work out your problem.
What version of Eu are you using?
Can you create a tiny program to demonstrates the problem?