Expand my Community achievements bar.

SOLVED

PGS-220000 PostgreSQL error: ERROR: function substr(integer, integer, integer) does not exist LINE 1: ...0.ts4, W0.ts9, W0.ts11, W0.ts10, W0.ts12, W0.ts6, substr(W0.... ^

Avatar

Level 6

Hi, how to debug this error? 

I was tasked with adding a new column to a table. So I:

1.- Modified the XML of the schema to add this new column (attribute).
2.- Updated DB Structure.
3.- Configure fields on the Load activity.
4.- Add the new field in the Update activity (Destination and Source Expression).

What does it mean? 

Edit: I didn't find the reason. But exporting the pacakge , that was working from Production to Development, solve this.  


 

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hello @god_prophet 

 

You are trying to ingest an integer value in a String column.

 

To fix the issue, use ToString(@COLUMN_NAME) in the update data activity.


     Manoj
     Find me on LinkedIn

View solution in original post

6 Replies

Avatar

Community Advisor

Hi @god_prophet ,

Share the screenshot of Update data activity where you had configured substring function.

Syntax of substring is Substring(<string>,<offset> ,<length> )

Example,

Substring(@StringTypeAttributeName,1 ,1 )

 

Avatar

Level 6

Please, see edit 1.

There is not SubString function applied, not by me.  Just added the last highlighted field.

Avatar

Community Advisor

@god_prophet , So just after adding the 'yellow highlighted' field in update data activity, you're getting error?

Check what is the data type of that field in your schema.

Then select 'display target' in the inbound transition of update data activity, In top left navigate to 'Schema' tab. Click on your field and in bottom you can see the data type of it. This data type should be same as the data type of your schema.

ParthaSarathy_0-1695833772799.png

Cross check the same for other fields as well.

Avatar

Level 6

Please, see edit 2. 

I did what you mentioned and it was a string column as expected. But apparently the error is somwhere else. 

However, error messasge is not clear.

Avatar

Correct answer by
Community Advisor

Hello @god_prophet 

 

You are trying to ingest an integer value in a String column.

 

To fix the issue, use ToString(@COLUMN_NAME) in the update data activity.


     Manoj
     Find me on LinkedIn

Avatar

Administrator

Hi @god_prophet,

Was the given solution by @_Manoj_Kumar_ helpful in answering your doubt or do you still need more help here? Do let us know.



Sukrity Wadhwa