devxlogo

Using Fields Object with GetChunk

Using Fields Object with GetChunk

Question:
What is the fields object of the GetChunk method?I am trying to access a large (several meg) flatfixed record (160 ascii bytes per record) database and I thought the only way is the GetChunk methodbut I don’t know what the fields object is or howto specify it.

Answer:
Typically, the GetChunk method is used on the Fields object like this:

String = Fields(1).GetChunk

The Fields object is just all the different fields on a particular table. If the table you opened was named Customer, you would do like this:

String = Customer.Fields(1).GetChunk

The 1 (one) is the field number. You can also specify fields by name.

devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist