14 lines
214 B
MySQL
14 lines
214 B
MySQL
|
CREATE VIEW api.post AS
|
||
|
SELECT
|
||
|
p.id,
|
||
|
p.user_id,
|
||
|
p.content,
|
||
|
p.date
|
||
|
FROM
|
||
|
admin.post p;
|
||
|
|
||
|
GRANT SELECT ON TABLE api.post
|
||
|
TO rest_anon, rest_user;
|
||
|
GRANT SELECT ON TABLE admin.post
|
||
|
TO rest_anon, rest_user;
|