Added new sql statements. In new reply entry_id and created swapped places.
This commit is contained in:
parent
49a92151e4
commit
005330ff2c
2
internal/database/sqlite/queries/entryCount.sql
Normal file
2
internal/database/sqlite/queries/entryCount.sql
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
SELECT COUNT(`entry_id`) AS `total`
|
||||||
|
FROM `entry`;
|
7
internal/database/sqlite/queries/entryUpdate.sql
Normal file
7
internal/database/sqlite/queries/entryUpdate.sql
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
UPDATE OR REPLACE `entry`
|
||||||
|
SET
|
||||||
|
`name` = ?,
|
||||||
|
`message` = ?,
|
||||||
|
`website` = ?,
|
||||||
|
`hide_website` = ?,
|
||||||
|
WHERE `entry_id` = ?;
|
@ -1,4 +1,4 @@
|
|||||||
INSERT INTO `reply`
|
INSERT INTO `reply`
|
||||||
(`created`, `entry_id`, `message`)
|
(`entry_id`, `created`, `message`)
|
||||||
VALUES
|
VALUES
|
||||||
(?, ?, ?);
|
(?, ?, ?);
|
5
internal/database/sqlite/queries/replyUpdate.sql
Normal file
5
internal/database/sqlite/queries/replyUpdate.sql
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
UPDATE OR REPLACE `reply`
|
||||||
|
SET
|
||||||
|
`created` = ?,
|
||||||
|
`message` = ?,
|
||||||
|
WHERE `entry_id` = ?;
|
Loading…
Reference in New Issue
Block a user