Hi,
I use hdf5 with fortran and I'm actually trying to read a table with
string columns.
Imagine a two string column table :
···
=========+========
name surname
=========+========
Name is a 30 characters string column.
Surname is a 20 characters string column.
According to my tests, the function
character(len=30), dimension(:), allocatable :: name
call h5tbread_field_name_f(file_id, path, "name", &
start, nrecords, type_size, &
name, hdferr)
must absolutely be a 30 characters array.
However, varying length character string is not (or very bad) supported
by compilers (as it is an extension).
So string length is a static value. I can only foresee a MAX length for
character string.
Is it (would it be) possible that the "name" array be a MAX characters
string array ?
Best regards,
Cyril.
I make a mistake in the preceding message :
In the
h5tbread_field_name_f
function call, the argument "name" must be a 30 characters array and not
the function.
Regards,
Cyril.
Le 24/02/2010 15:23, Giraudon Cyril a �crit :
···
Hi,
I use hdf5 with fortran and I'm actually trying to read a table with
string columns.
Imagine a two string column table :
=========+========
name surname
=========+========
Name is a 30 characters string column.
Surname is a 20 characters string column.
According to my tests, the function
character(len=30), dimension(:), allocatable :: name
call h5tbread_field_name_f(file_id, path, "name", &
start, nrecords, type_size, &
name, hdferr)
must absolutely be a 30 characters array.
However, varying length character string is not (or very bad) supported
by compilers (as it is an extension).
So string length is a static value. I can only foresee a MAX length for
character string.
Is it (would it be) possible that the "name" array be a MAX characters
string array ?
Best regards,
Cyril.
_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org