GML field

  • 11 February 2019
  • 6 replies

In one of my single text files is a field which is actually a GML field.

When i'm trying to deploy and execute this field as varchar(4000) it gives me the following error: 'string or binary data would be truncated'

So I wanted to override data type vut this seems to be impossible when your data source is a single text file.

So I tried something else, i made an Excel file of my csv file and read objects from data source as Excel, but then my GML field isn't even visible in the data selection tab.

is there another possible way to insert my GML file in TimeXtender without getting an error?


Best answer by Jacob.Ross.Andersen 13 February 2019, 21:50

View original

6 replies

Hi Rik,

I would recommend that you try connecting to the file using the CDATA text file source, this generally has improved handling of many data types over 'single text file'. 

The source is really easy to work with, in many cases you just need to set the URI.

See this article for more details


Hi Tobias,

Thanks for your reply.

I've tried using the CDATA text file source. When I'm trying to read the data it instantly gives me the error: "String or binary data would be truncated."

I also tried to override data type based on fieldname, but it doesn't seems te work....

Hi Rik

The CDATA CSV provider assumes that first row is column headers. I typically get the "String or binary data would be truncated" error when my file doesn't include headers. I believe the limit is 128 characters for objects in SQL Server so that's easy to break.

Solution is to set the "Include Column Headers" property to "False".


Then it should work.

If you get the during Execution then it's likely caused by size of data type. CDATA default size is NVARCHAR(2000). 

You can override the default by setting the "DefaultColumnSize=VALUE" in the "Other" property. 

Remember to Synchronize the data source before executing again. That should resolve that issue.

Let me know if above two possible solutions doesn't fix it.

Hi Jacob,


Thanks for your reply.

I've tried all the steps you've noticed. See screenshots below for the result i got.

Error 1 is what I get when I just have a normal dataset (with clumn headers in my csv file)

Then I changed my datasource, deleted the column headers, changed the column header option. What I see is that i can't see the different columns. I just get 1 column named col0. when I try to deploy and execute it ofcourse gives me an error.

Any extra ideas?

Hi Rik,

Hm... and you remember to synchronize after you set the DefaultColumnSize property? 

Would you be able to send me the file or a sample of the file? I'll be happy to take a quick look and see if I can find the fix.

Please send to:


This issue has been resolved and is not related to GML fields. 


The file contained a non-standard field delimiter (semi-colon). CDATA's standard delimiters are: comma & TAB. 


I created a "schema.ini" file and placed it in the same directory as the text file. It only contained the following script:


You can read more in this article