Need some quick help: How to remove "Memo" field limit of 100?


Userlevel 3
Badge +16

Hi,

 

Form deployed, then was asked to change requirements to allow more than 100 characters of 3 fields

 

So i changed the Smartobject field from TEXT to MEMO, went into Smartobject Tester and refreshed the Smartobject.

 

Checked on the K2 Server Smartbox table and it's still showing NVARCHAR(100) on all 3 fields  ...

 

Help, what do i do?

 

I looked here: http://community.k2.com/t5/K2-blackpearl/Changing-datatype-for-a-smartobject-does-not-change-database/ta-p/87943

it talks about dropping table etc, but this worries me as i have live records in there which are linked back to active processes etc.

 

Is there any other way of updating the SQL Table?

 

What would happen if i did DESIGN on the table and altered the Field type from NVARCHAR(100) to NVARCHAR(MAX) manually? Would that screw up everything?

 

Thanks


5 replies

Badge +3

Hi,

 

we had similar situation with live data in the table. the user will get message stating the the text will be truncated as it exceeded the size when he enters the data more than the specified length.

 

As a best practice we took backup of the table with data and we did change the datatype from nvarchar(100) to Nvarchar(Max) in the SQlL table design.

 

It will not impact the data already stored. after doing this change query the smart object in the SO Tester. it should fetch all the records.

 

Thanks

Vijay

Badge +7

Hi,

 

 

 

Please visit the blog post 

https://prajwalshambhu.wordpress.com/2015/08/03/smartobject-data-type-change-from-text-to-memo/

 

 

Hope it helps!

 

Cheers,

Prajwal Shambhu

Userlevel 3
Badge +16

Hi Prajwal,

 

Thanks for the link, I had a look at your Blog, but i can't quite understand what to do...

 

On my PC, i opened up K2 Studio and went to the Object Browser -> Smartobject Server(s) and drill down to my Smartobject

When i right-click on the Smartobject, i only get Refresh or Delete Smartobject

 

There is no "Select Save to Local"....

 

Any ideas what i'm doing wrong?

 

Thanks

 

EDIT: I realised I have to open up a Process in K2 Studio, then open the Smartobject via Object Explorer. Is it possible to deploy just the changes to the Smartobject? When i deploy, it also tried to deploy the Workflow process as well.... What if i have a Smartobject to change, but there is no associated Process? How do i deploy the smartobject then? Can you again just deploy the Smartobject? Thanks
Userlevel 5
Badge +18

The process can be excluded from the project, such that it will not deploy:


http://help.k2.com/onlinehelp/k2blackpearl/userguide/current/webframe.html#K2_Studio_Solution_Explorer.html

Userlevel 3
Badge +16

As i changed the properties in K2 Designer for the Smartobject to Memo dataypes originally, do i need to change them back to TEXT, before i go ahead and do this in K2 Studio? In K2 Studio the fields say memo at the moment?

 

Or should i change the fields in k2 studio Solution explorer to text, deploy, then go back and change to memo and re-deploy?

 

Thanks

Reply