ICV: Invalid data according to constraints not failing transaction

1 view
Skip to first unread message

jan.bjo...@gmail.com

unread,
Nov 1, 2016, 8:59:09 AM11/1/16
to Stardog
Hello.

I have been trying to enable ICV for my application using Stardog 4.2. I have "ICV Enabled" = true for my database "users" and then run

./stardog-admin icv add users user_constraints.ttl

When I then upload the file two_users.ttl I get no failing transaction. Running CLI validate shows:

./stardog icv validate users
Data is NOT valid.
The following constraints were violated:
AxiomConstraint{<tag:complexible:pinto:User> owl:hasKey (<tag:complexible:pinto:username>)}


Have also tried adding data programatically using transactions.

What am I missing?
user_constraints.ttl
two_users.ttl

Zachary Whitley

unread,
Nov 1, 2016, 9:21:04 AM11/1/16
to Stardog
You might want to double check that ICV guard mode is actually enabled for your db. It's not clear exactly what you did from your description to enable it. Did you do it through the webconsole?, at db creation time?, after creating the db?

Can you send the command that you used to enable ICV guard mode?

What is the output from running the following command?

$> stardog-admin metadata get -o icv.enabled -- users

--
-- --
You received this message because you are subscribed to the C&P "Stardog" group.
To post to this group, send email to sta...@clarkparsia.com
To unsubscribe from this group, send email to
stardog+unsubscribe@clarkparsia.com
For more options, visit this group at
http://groups.google.com/a/clarkparsia.com/group/stardog?hl=en
---
You received this message because you are subscribed to the Google Groups "Stardog" group.
To unsubscribe from this group and stop receiving emails from it, send an email to stardog+unsubscribe@clarkparsia.com.

jan.bjo...@gmail.com

unread,
Nov 1, 2016, 9:27:18 AM11/1/16
to Stardog
I used the webconsole and enabled ICV during creation time.

./stardog-admin metadata get -o icv.enabled -- users
+-------------+-------+
|   Option    | Value |
+-------------+-------+
| icv.enabled | true  |
+-------------+-------+



tirsdag 1. november 2016 14.21.04 UTC+1 skrev Zachary Whitley følgende:
You might want to double check that ICV guard mode is actually enabled for your db. It's not clear exactly what you did from your description to enable it. Did you do it through the webconsole?, at db creation time?, after creating the db?

Can you send the command that you used to enable ICV guard mode?

What is the output from running the following command?

$> stardog-admin metadata get -o icv.enabled -- users
On Tue, Nov 1, 2016 at 8:59 AM, <jan.bjo...@gmail.com> wrote:
Hello.

I have been trying to enable ICV for my application using Stardog 4.2. I have "ICV Enabled" = true for my database "users" and then run

./stardog-admin icv add users user_constraints.ttl

When I then upload the file two_users.ttl I get no failing transaction. Running CLI validate shows:

./stardog icv validate users
Data is NOT valid.
The following constraints were violated:
AxiomConstraint{<tag:complexible:pinto:User> owl:hasKey (<tag:complexible:pinto:username>)}


Have also tried adding data programatically using transactions.

What am I missing?

--
-- --
You received this message because you are subscribed to the C&P "Stardog" group.
To post to this group, send email to sta...@clarkparsia.com
To unsubscribe from this group, send email to

For more options, visit this group at
http://groups.google.com/a/clarkparsia.com/group/stardog?hl=en
---
You received this message because you are subscribed to the Google Groups "Stardog" group.
To unsubscribe from this group and stop receiving emails from it, send an email to stardog+u...@clarkparsia.com.

Evren Sirin

unread,
Nov 1, 2016, 9:29:37 AM11/1/16
to Stardog
Here are the steps I tried now:

$ stardog-admin db create -o icv.enabled=true -n users
Successfully created database 'users'.
$ stardog-admin icv add users user_constraints.ttl
Successfully added constraints in 00:00:00.
$ stardog data add users two_users.ttl
Adding data from file: two_users.ttl
ICV validation failed, one or more constraints have been violated.
VIOLATED <tag:complexible:pinto:User> owl:hasKey
(<tag:complexible:pinto:username>)
ASSERTED <tag:complexible:pinto:jan2> a <tag:complexible:pinto:User>
ASSERTED <tag:complexible:pinto:jan> a <tag:complexible:pinto:User>
ASSERTED <tag:complexible:pinto:jan> <tag:complexible:pinto:username> "Jan"
ASSERTED <tag:complexible:pinto:jan2> <tag:complexible:pinto:username> "Jan"

Are you doing something different? Do you have other configuration
options changed?

Best,
Evren

jan.bjo...@gmail.com

unread,
Nov 4, 2016, 3:41:46 AM11/4/16
to Stardog
Following your guide I got it working without problems. I am not sure what I did wrong though. Maybe there was some existing data in the database, but I am sure I tried to recreate the database many times.

Thank you for your help!
Reply all
Reply to author
Forward
0 new messages