Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

Error while updating table analyticsconfiges using Enhance query

Ashish_Gupta
New Contributor
New Contributor

Hello Team,

I was trying to update ENABLEARCHIVAL for the table analyticsconfiges to set it as enable/on.
I have tried with below query :-
select 1 as analyticsconfiges__ENABLEARCHIVAL,Analyticskey as analyticsconfiges__PRIMARYKEY from analyticsconfiges where Analyticskey='XXX'

but its giving me error "Error while updating table: ANALYTICSCONFIGES : Data truncation: Data too long for column 'ENABLEARCHIVAL' at row 1"

Its look like its datatype is bit(1), I tried with other values like 1,'1',"1",true,'true','yes' as well but its giving me same error.

Kindly suggest.

Thanks,

Ashish Gupta

5 REPLIES 5

CR
Regular Contributor III
Regular Contributor III

Hi @Ashish_Gupta 

try please  like below it work

select True as analyticsconfiges__ENABLEARCHIVAL,Analyticskey as analyticsconfiges__PRIMARYKEY from analyticsconfiges where Analyticskey='XX'


Thanks,
Raghu
If this reply answered your question, Please Accept As Solution and hit Kudos.

Ashish_Gupta
New Contributor
New Contributor

Hi @CR ,

Thanks for your input.

We have also tried that but still getting the same error:-

Error while updating table: ANALYTICSCONFIGES : Data truncation: Data too long for column 'ENABLEARCHIVAL' at row 1

Thanks,

Ashish Gupta

CR
Regular Contributor III
Regular Contributor III

@Ashish_Gupta 

Please try below, already i done it working fine. just change value need pass as capital value True

select True as analyticsconfiges__ENABLEARCHIVAL,Analyticskey as analyticsconfiges__PRIMARYKEY from analyticsconfiges where Analyticskey='XX'

still send me logs


Thanks,
Raghu
If this reply answered your question, Please Accept As Solution and hit Kudos.

Ashish_Gupta
New Contributor
New Contributor

Hi @CR ,

I have tried the same but its not working for me.

Ashish_Gupta_0-1708050217300.png

I can see below error in logs :-

2024-02-16T08:02:44+05:30-ecm-worker-services.SaviyntGuardRailService-quartzScheduler_Worker-4-DEBUG-Final query for processing SELECT TRUE AS ANALYTICSCONFIGES__ENABLEARCHIVAL,ANALYTICSKEY AS ANALYTICSCONFIGES__PRIMARYKEY FROM ANALYTICSCONFIGES WHERE ANALYTICSKEY='1220'
2024-02-16T08:02:44+05:30-ecm-worker-utility.CustomQueryService-quartzScheduler_Worker-4-DEBUG-Saviynt GuardRail ResultSet : [data:[statement:org.apache.tomcat.jdbc.pool.interceptor.StatementDecoratorInterceptor$StatementProxy[Proxy=655919729; Sql=null; Delegate=com.mysql.jdbc.StatementImpl@66d03a11; Connection=ProxyConnection[PooledConnection[com.mysql.jdbc.JDBC4Connection@2222744a]]], connection:Transaction-aware proxy for target Connection [Transaction-aware proxy for target Connection [ProxyConnection[PooledConnection[com.mysql.jdbc.JDBC4Connection@2222744a]]]], resultSet:com.mysql.jdbc.JDBC4ResultSet@263f511e], errorCode:0, totalQueryExecutionTime:0.0, message:Success]
2024-02-16T08:02:45+05:30-ecm-worker----16-Feb-2024 02:32:44.954 WARNING [quartzScheduler_Worker-4] groovy.sql.Sql.withBatch Error during batch execution: Data truncation: Data too long for column 'ENABLEARCHIVAL' at row 1
2024-02-16T08:02:44+05:30-ecm-worker-utility.CustomQueryService-quartzScheduler_Worker-4-ERROR-Exception Inside transaction: Data truncation: Data too long for column 'ENABLEARCHIVAL' at row 1
2024-02-16T08:02:45+05:30-ecm-worker----16-Feb-2024 02:32:44.954 WARNING [quartzScheduler_Worker-4] groovy.sql.Sql.handleError Rolling back due to: Data truncation: Data too long for column 'ENABLEARCHIVAL' at row 1

 

Thanks,

Ashish Gupta

BIT Data type update is not supported. Please update button manually to enable archival


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.