Docs: Table constraints
See original GitHub issueExpected behavior
The user guide should provide a description and an example on how to define table constraints (model.table()
).
A notebook example mentions table constraints in context of expressions. It would be nice if the user guide showed an equivalent solution using expressions.
Actual behavior
The user guide doesn’t even mention table constraints.
Possible Solution
Steps to Reproduce (for bugs)
Context
I searched for a way to create table constraints.
Environment
- Choco-solver version:
master
- Java version: AdoptOpenJDK (build 14.0.1+7)
- Link to your project:
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
CONSTRAINT clause
A CONSTRAINT clause is an optional part of a CREATE TABLE statement or ALTER TABLE ... Table-level constraints refer to one or more...
Read more >Documentation: 15: 5.4. Constraints - PostgreSQL
Unique constraints ensure that the data contained in a column, or a group of columns, is unique among all the rows in the...
Read more >Create and manage check constraints | Cloud Spanner
A CHECK constraint allows you to specify that the values of one or more columns must satisfy a boolean expression. In this article,...
Read more >Constraints on Databricks
Enforced contraints ensure that the quality and integrity of data added to a table is automatically verified. Informational primary key and ...
Read more >Constraints | CockroachDB Docs
Each non-NULL value must be unique. This also automatically creates an index for the table using the constrained columns. Using constraints. Add constraints....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
https://choco-solver.org/docs/modeling/intconstraints/#table-constraints If you have any comments, let me know
I added a tutorial for the TSP, wherein I use table constraints to get distances between cities. Have a look, and tell if that helps (I know, I should update the documentation too…)
https://choco-solver.org/tutos/traveling-salesman-problem/
Best, CP