Hacker News new | ask | show | jobs
by santa_boy 377 days ago
Curious, Is there an easy way to do row-level and field-level security in MySQL?
2 comments

Field-level is just column privileges. Row-level, I think you can only achieve that with views, which is less than ideal.
Views?
I guess he meant to create a view of a table with “where” conditions depend on your user privileges
Yes, using the DEFINER clause.

For all i know there could be other methods in mysql at this point, but views is how people have been doing fine grained row permissions in mysql for decades.