Updating default in factory schema | Community
Skip to main content
Level 3
Oct 1, 2019 11:01 AM UTC
Solved

Updating default in factory schema

Hi team,

we have a requirement that we want to change the default value of an attribute in a factory schema.

Say, for example, in xtk:workflow schema,

    <attribute default="3600" label="Delay" name="delay" type="timespan"/>

I Need to change this default value to 3000.

So what can i do? I have extended xtk:wokflow schema as  abc:workflow. Now what should i need to?

Please help me with this!

Thanks and Regards,

Partha.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Partha18Accepted solution
Level 3
Oct 1, 2019 11:36 AM UTC

Hi David ,   davidk23955130​

Thanks for responding!

So u will place this syntax in extended schema?

As per my case, mentioned in my question, i need to extend xtk:workflow and save it as abc:workflow,

And then i need to insert this

<attribute default="'3000'" label="Delay" name="delay" type="timespan" sqlDefault="'3000'"/>

Am i right? or we need to use any attributes like update to update this default value?

(in xtk:workflow it will be default="3600", but i need to change that default into 3000)

Thanks and Regards,

Partha

6 replies

Partha18Author
Level 3
Oct 7, 2019 2:04 PM UTC

Hi davidk23955130​ ,

Thank you so much!

Translate
DavidKangni
New Participant
Oct 7, 2019 1:07 PM UTC

Hi Partha,

you're trying to set up a default value to 20 while your workflows templates are set up to 30.

Thanks

David

Translate
David Kangni
Partha18Author
Level 3
Oct 7, 2019 8:31 AM UTC

Hi, davidk23955130​

I want my "history" attributes default value as "20" in xtk:workflow. so i extended that schema, and gave the attribute as you mentioned above.

(Note: while i tried to update database structure, i didn't found anything to update there.)

Then i disconnected and reconnected.

Then i created a dummy workflow and i found the history of that newly created workflow as "30" and not "20" in xtk:workflow data.

So This doesn't worked for this case. Please help me with this!

Thanks and Regards,

Partha.

Translate
DavidKangni
New Participant
Oct 1, 2019 11:46 AM UTC

correct. It will work for the new entries created. old entries need to be updated if needed

Translate
David Kangni
Partha18AuthorAccepted solution
Level 3
Oct 1, 2019 11:36 AM UTC

Hi David ,   davidk23955130​

Thanks for responding!

So u will place this syntax in extended schema?

As per my case, mentioned in my question, i need to extend xtk:workflow and save it as abc:workflow,

And then i need to insert this

<attribute default="'3000'" label="Delay" name="delay" type="timespan" sqlDefault="'3000'"/>

Am i right? or we need to use any attributes like update to update this default value?

(in xtk:workflow it will be default="3600", but i need to change that default into 3000)

Thanks and Regards,

Partha

Translate
DavidKangni
New Participant
Oct 1, 2019 11:25 AM UTC

Hi Partha,

Here is an example of syntax to achieve this

   <attribute default="'0'" label="PrimaryPhoneNumber" length="30" name="primaryPhoneNumber" notNull="true" sqlDefault="'0'"

type="string"/>

thanks

david

Translate
David Kangni