Trdin,
Like Ed, I'm also unable to decipher your requirement fully. However, if I understood bit of it, then I feel that you have column-wise data horizontally placed in your data file, and every 3 lines of information makes a Row for your base table. If so, here is a solution:
database testdb
main
define m_dat varchar(255), cntr smallint,
arr_cols array[3] of
record
mcol varchar(255)
end record
create temp table t_data (dat varchar(255)) with no log
load from 'your.data' insert into t_data
declare cur1 cursor for select * from t_data
let cntr=0
open cur1
while(1)
fetch cur1 into m_dat
if status=notfound then
exit while
end if
let cntr=cntr+1
let arr_cols[cntr].mcol=m_dat clipped
display m_dat
if cntr=3 then
-- send the full row into your database table
while (1)
insert into base_table values
(arr_cols[1].mcol,
arr_cols[2].mcol,
arr_cols[3].mcol)
if status=0 then
exit while
else
error "<base_table> Insert ", status sleep 1
end if
end while
for cntr=1 to 3
let arr_cols[cntr].mcol=""
end for
let cntr=0
end if
end while
end main
Regards,
Shriyan