Skip to content

Commit

Permalink
Correct data kind usage in tutorial
Browse files Browse the repository at this point in the history
  • Loading branch information
ocharles committed Mar 16, 2017
1 parent 1415fd0 commit 790fbe2
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions docs/tutorial.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ type of the form ``C f name hasDefault t``. Let's see how that looks with some
example tables::

data Part f = Part
{ partId :: C f "PID" 'HasDefault' Int
, partName :: C f "PName" 'NoDefault' String
, partColor :: C f "Color" 'NoDefault' Int
, partWeight :: C f "Weight" 'NoDefault' Double
, partCity :: C f "City" 'NoDefault' String
{ partId :: C f "PID" 'HasDefault Int
, partName :: C f "PName" 'NoDefault String
, partColor :: C f "Color" 'NoDefault Int
, partWeight :: C f "Weight" 'NoDefault Double
, partCity :: C f "City" 'NoDefault String
} deriving (Generic)

instance BaseTable Part where tableName = "part"
Expand Down Expand Up @@ -127,10 +127,10 @@ each row of the second query - by sequencing queries inside a ``O.Query``. Let's
introduce another table::

data Supplier f = Supplier
{ supplierId :: C f "SID" HasDefault Int
, supplierName :: C f "SName" NoDefault String
, supplierStatus :: C f "Status" NoDefault Int
, supplierCity :: C f "City" NoDefault String
{ supplierId :: C f "SID" 'HasDefault Int
, supplierName :: C f "SName" 'NoDefault String
, supplierStatus :: C f "Status" 'NoDefault Int
, supplierCity :: C f "City" 'NoDefault String
} deriving (Generic)

instance BaseTable Supplier where tableName = "supplier"
Expand Down

0 comments on commit 790fbe2

Please sign in to comment.