@@ -640,21 +640,21 @@ instance PGTyped 'PGJsonb where pgtype = jsonb
640640statements
641641-----------------------------------------}
642642
643−newtype DataDefinition
643+newtype Definition
644644 (schema0 :: [(Symbol,[(Symbol,ColumnType)])])
645645 (schema1 :: [(Symbol,[(Symbol,ColumnType)])])
646− = UnsafeDataDefinition { renderDataDefinition :: ByteString }
646+ = UnsafeDefinition { renderDefinition :: ByteString }
647647
648−instance Category DataDefinition where
649− id = UnsafeDataDefinition ";"
650− dd1 . dd0 = UnsafeDataDefinition $
651− renderDataDefinition dd0 <> " " <> renderDataDefinition dd1
648+instance Category Definition where
649+ id = UnsafeDefinition ";"
650+ dd1 . dd0 = UnsafeDefinition $
651+ renderDefinition dd0 <> " " <> renderDefinition dd1
652652
653−newtype DataManipulation
653+newtype Manipulation
654654 (schema :: [(Symbol,[(Symbol,ColumnType)])])
655655 (params :: [ColumnType])
656656 (columns :: [(Symbol,ColumnType)])
657− = UnsafeDataManipulation { renderDataManipulation :: ByteString }
657+ = UnsafeManipulation { renderManipulation :: ByteString }
658658
659659newtype Query
660660 (schema :: [(Symbol,[(Symbol,ColumnType)])])
@@ -664,8 +664,8 @@ newtype Query
664664
665665query
666666 :: Query schema params columns
667− -> DataManipulation schema params columns
668−query q = UnsafeDataManipulation $ renderQuery q <> ";"
667+ -> Manipulation schema params columns
668+query q = UnsafeManipulation $ renderQuery q <> ";"
669669
670670union, unionAll, intersect, intersectAll, except, exceptAll
671671 :: Query schema params columns
@@ -723,8 +723,8 @@ createTable
723723 :: (KnownSymbol table, SListI columns)
724724 => Alias table
725725 -> NP (Aliased TypeExpression) columns
726− -> DataDefinition schema (Create table columns schema)
727−createTable table columns = UnsafeDataDefinition $ mconcat
726+ -> Definition schema (Create table columns schema)
727+createTable table columns = UnsafeDefinition $ mconcat
728728 [ "CREATE TABLE "
729729 , renderAlias table
730730 , " ("
@@ -744,8 +744,8 @@ DROP statements
744744dropTable
745745 :: KnownSymbol table
746746 => Alias table
747− -> DataDefinition schema (Drop table schema)
748−dropTable table = UnsafeDataDefinition $ "DROP TABLE " <> renderAlias table <> ";"
747+ -> Definition schema (Drop table schema)
748+dropTable table = UnsafeDefinition $ "DROP TABLE " <> renderAlias table <> ";"
749749
750750{-----------------------------------------
751751ALTER statements
@@ -755,8 +755,8 @@ alterTable
755755 :: HasTable table schema columns0
756756 => Alias table
757757 -> AlterTable columns0 columns1
758− -> DataDefinition schema (Alter table schema columns1)
759−alterTable table alteration = UnsafeDataDefinition $
758+ -> Definition schema (Alter table schema columns1)
759+alterTable table alteration = UnsafeDefinition $
760760 "ALTER TABLE "
761761 <> renderAlias table
762762 <> " "
@@ -767,8 +767,8 @@ alterTableRename
767767 :: (KnownSymbol table0, KnownSymbol table1)
768768 => Alias table0
769769 -> Alias table1
770− -> DataDefinition schema (Rename table0 table1 schema)
771−alterTableRename table0 table1 = UnsafeDataDefinition $
770+ -> Definition schema (Rename table0 table1 schema)
771+alterTableRename table0 table1 = UnsafeDefinition $
772772 "ALTER TABLE "
773773 <> renderAlias table0
774774 <> " RENAME TO "
@@ -861,8 +861,8 @@ insertInto
861861 :: (SListI columns, HasTable table schema columns)
862862 => Alias table
863863 -> NP (Aliased (Expression params '[])) columns
864− -> DataManipulation schema params '[]
865−insertInto table expressions = UnsafeDataManipulation $ "INSERT INTO "
864+ -> Manipulation schema params '[]
865+insertInto table expressions = UnsafeManipulation $ "INSERT INTO "
866866 <> renderAlias table
867867 <> " (" <> ByteString.intercalate ", " aliases
868868 <> ") VALUES ("
@@ -881,9 +881,9 @@ insertIntoReturning
881881 => Alias table
882882 -> NP (Aliased (Expression params '[])) columns
883883 -> NP (Aliased (Expression params '[table ::: columns])) results
884− -> DataManipulation schema params results
884+ -> Manipulation schema params results
885885insertIntoReturning table inserts results
886− = UnsafeDataManipulation . mconcat $
886+ = UnsafeManipulation . mconcat $
887887 [ "INSERT INTO "
888888 , renderAlias table
889889 , " (" <> ByteString.intercalate ", " aliases
@@ -929,8 +929,8 @@ update
929929 => Alias table
930930 -> NP (Aliased (UpdateExpression params '[table ::: columns])) columns
931931 -> Condition params '[table ::: columns]
932− -> DataManipulation schema params '[]
933−update table columns wh = UnsafeDataManipulation $ mconcat
932+ -> Manipulation schema params '[]
933+update table columns wh = UnsafeManipulation $ mconcat
934934 [ "UPDATE "
935935 , renderAlias table
936936 , " SET "
@@ -945,8 +945,8 @@ updateReturning
945945 -> NP (Aliased (UpdateExpression params '[table ::: columns])) columns
946946 -> Condition params '[table ::: columns]
947947 -> NP (Aliased (Expression params '[table ::: columns])) results
948− -> DataManipulation schema params results
949−updateReturning table updates wh results = UnsafeDataManipulation $ mconcat
948+ -> Manipulation schema params results
949+updateReturning table updates wh results = UnsafeManipulation $ mconcat
950950 [ "UPDATE "
951951 , renderAlias table
952952 , " SET "
@@ -968,8 +968,8 @@ upsertInto
968968 -> NP (Aliased (Expression params '[])) columns
969969 -> NP (Aliased (UpdateExpression params '[table ::: columns])) columns
970970 -> Condition params '[table ::: columns]
971− -> DataManipulation schema params '[]
972−upsertInto table inserts updates wh = UnsafeDataManipulation . mconcat $
971+ -> Manipulation schema params '[]
972+upsertInto table inserts updates wh = UnsafeManipulation . mconcat $
973973 [ "INSERT INTO "
974974 , renderAlias table
975975 , " (" <> ByteString.intercalate ", " aliases
@@ -996,9 +996,9 @@ upsertIntoReturning
996996 -> NP (Aliased (UpdateExpression params '[table ::: columns])) columns
997997 -> Condition params '[table ::: columns]
998998 -> NP (Aliased (Expression params '[table ::: columns])) results
999− -> DataManipulation schema params results
999+ -> Manipulation schema params results
10001000upsertIntoReturning table inserts updates wh results =
1001− UnsafeDataManipulation . mconcat $
1001+ UnsafeManipulation . mconcat $
10021002 [ "INSERT INTO "
10031003 , renderAlias table
10041004 , " (" <> ByteString.intercalate ", " aliases
@@ -1032,8 +1032,8 @@ deleteFrom
10321032 :: HasTable table schema columns
10331033 => Alias table
10341034 -> Condition params '[table ::: columns]
1035− -> DataManipulation schema params '[]
1036−deleteFrom table wh = UnsafeDataManipulation $ mconcat
1035+ -> Manipulation schema params '[]
1036+deleteFrom table wh = UnsafeManipulation $ mconcat
10371037 [ "DELETE FROM "
10381038 , renderAlias table
10391039 , " WHERE ", renderExpression wh, ";"