Skip to main content
Override Data Type

Using the Override Data Type feature

  • December 20, 2022
  • 1 reply
  • 1002 views
Using the Override Data Type feature
Forum|alt.badge.img+3

The Override Data Type feature lets you decide the data type for a certain field.

Example Scenarios

  • You have an Excel data source with some sheets that contains a field with only numbers. Even though it actually is an Item Id, it gets treated as a numeric value.
  • You have a data source connection to a database with a datetime field that contains both nulls and dates lower than 1753-01-01.

In both cases, the Override Data Type feature may help. You can set up a general rule at the Ingest Instance data source, or edit a field in the prepare instance to change its data type.

Set up a general rule at Ingest Instance data source

  1. Right-click on an Ingest Instance data sourceOverride Data Types..
  2. Specify the SchemaTableField or Data type where this rule will be applied.
  3. Choose what data type you want to convert to.

 

Note: The schema refers to the data source, not the one you created in this system.

Right-click on the Ingest Instance Synchronize objects and run the Synchronize and Transfer tasks in the Ingest Instance data source.

Edit a field in a prepare instance to change its data type

Below is an example, explicitly changing data type of a field in prepare instance.

 

 

Did this topic help you find an answer to your question?

1 reply

I tried doing this, but my Hubspot connector still gives me error, not being able to even load data because some close dates are -- (which is completely logical) and I cannot change the source data type from datetime to nvarchar. 

see the error I constantly get, even if I try the override data type function. How do you guys suggest this to be resolved?

“Failed to execute callback for endpoint 'companies':
String was not recognized as a valid DateTime.Couldn't store <> in closedate Column.  Expected type is DateTime.
String was not recognized as a valid DateTime.

System.ArgumentException: String was not recognized as a valid DateTime.Couldn't store <> in closedate Column.  Expected type is DateTime. ---> System.FormatException: String was not recognized as a valid DateTime.
   at System.DateTimeParse.Parse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles)
   at System.Convert.ToDateTime(String value, IFormatProvider provider)
   at System.Data.Common.DateTimeStorage.Set(Int32 record, Object value)
   at System.Data.DataColumn.set_Item(Int32 record, Object value)
   --- End of inner exception stack trace ---
   at System.Data.DataColumn.set_Item(Int32 record, Object value)
   at System.Data.RecordManager.CopyRecord(DataTable src, Int32 record, Int32 copy)
   at System.Data.DataTable.ImportRow(DataRow row)
   at TimeXtender.RestEngine.DataTableHelper.CreateTypedDataTable(DataTable untypedDataTable, CoreTable coreTable, CultureInfo cultureInfo)
   at TimeXtender.RestEngine.DataTableHelper.CreateTypedDataTable(RestDataCache restDataCache, CoreTable coreTable, CultureInfo cultureInfo, Boolean emptyFieldsAsNull)
   at TimeXtender.REST.Core.ExtensionMethods.ToRestCoreDataCache(RestDataCache restDataCache, CultureInfo cultureInfo, Boolean emptyFieldsAsNull)
   at System.Linq.Enumerable.WhereSelectListIterator`2.MoveNext()
   at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
   at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
   at TimeXtender.REST.Core.ExtensionMethods.ToRestCoreCallbackObject(RestCallbackObject restCallbackObject)
   at TimeXtender.HubSpot.Core.HubSpotCore.<>c__DisplayClass19_0.<ExecuteEndpointRequests>b__1(RestCallbackObject restCallbackObject)
   at TimeXtender.RestEngine.RestEngine.<>c__DisplayClass24_0.<ExecuteEndpoints>b__0(RestCallbackObject restCallbackObject)
   at TimeXtender.RestEngine.RestEngine.<>c__DisplayClass30_0.<CreateExecutionTask>b__0()”


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings