Posts

Showing posts with the label coldfusion

Best way to store permissions for the user account?

Image
Clash Royale CLAN TAG #URR8PPP Best way to store permissions for the user account? I have permission records that are tied to each account in my application. Each account can have one or multiple permission records based on account type. Here is example: <cfquery name="qryUserPerm" datasource="#Application.dsn#"> SELECT AccessType, AccessLevel, State, City, Building FROM Permissions WHERE AccountID = <cfqueryparam cfsqltype="cf_sql_integer" value="#trim(session.AccountID)#"> </cfquery> Query above will produce data like this for one of the accounts: RecID AccountID AccessType AccessLevel State City Building 70 285A637D82B9 F B NY New York 8010 71 285A637D82B9 F B NY New York 5412 73 285A637D82B9 F B NY New York 6103 74 285A637D82B9 F B NY New York 3106 As you can see above this a...