Hi,
maybe someone can help me with my little LiveCode problem.
I want to create a tool where you can write data into your database and view the data which is in your database.
Well this isn't the problem.. the problem is, that this tool should have a login for seperate users
and every user got it's specific rights.
For example:
User 1 can only see the data which is in the database
User 2 can create new database entry but is not allowed to delete
User 3 can delete and see the data
User admin is allowed to do everything
I can't find anything in the dictonary or something that helps me
to connect the rights with the specific usergroups.
(I'm using mssql windows 64bit
don't know it it matters)
regards
Nibor
Database login
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Re: Database login
Hi Nibor,
1. welcome to the forum
2. I would put the current user (1,2,3, or admin) into a global variable or custom property and en-/disable
your buttons "new entry" resp. "delete entry" accordingly, maybe in an "pre-/opencard" script. Know what I mean?
A quick and clean solution I think
Best
Klaus
1. welcome to the forum

2. I would put the current user (1,2,3, or admin) into a global variable or custom property and en-/disable
your buttons "new entry" resp. "delete entry" accordingly, maybe in an "pre-/opencard" script. Know what I mean?
A quick and clean solution I think

Best
Klaus
Re: Database login
Hi Nibor,
MSSQL has a built-in feature for this. You can create users with special permissions. You set these permissions when executing the CREATE USER command. Once you have created the users, you can log in to your database with these users and you're sure that each user can only do what you allow them to do.
Kind regards,
Mark
MSSQL has a built-in feature for this. You can create users with special permissions. You set these permissions when executing the CREATE USER command. Once you have created the users, you can log in to your database with these users and you're sure that each user can only do what you allow them to do.
Kind regards,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
Re: Database login
Hi Klaus,Klaus wrote:Hi Nibor,
1. welcome to the forum![]()
2. I would put the current user (1,2,3, or admin) into a global variable or custom property and en-/disable
your buttons "new entry" resp. "delete entry" accordingly, maybe in an "pre-/opencard" script. Know what I mean?
A quick and clean solution I think![]()
Best
Klaus
it is a good solution, but in my case there are more than one user in each group.
For example:
user1 is in group "admin"
user2 is in group "admin"
user3-7 is in group "create; no delete"
user8-10 is in group "only view"
as far as I understand your solution, I would have just one user per group.
I tried to create a new table in my database and added a few new users with a column for group and a column for userid.
In another table I added the userid aswell as the username, name and the password.
Now I would like to connect these tables in LiveCode so that each user can do what I gave them the rights for.
I'm able to add new users with password and so on.
kind regards
Nibor
Re: Database login
My solution was just a proposal and could certainly be enhanced to fit your needs!Nibor wrote:Hi Klaus,
it is a good solution, but in my case there are more than one user in each group.
For example:
user1 is in group "admin"
user2 is in group "admin"
user3-7 is in group "create; no delete"
user8-10 is in group "only view"
as far as I understand your solution, I would have just one user per group.
Just check the GROUP in your case and not the users

Hm, I thought you meant a Livecode solution, but you come up with a "real" database solutionNibor wrote:I tried to create a new table in my database and added a few new users with a column for group and a column for userid.
In another table I added the userid aswell as the username, name and the password.
Now I would like to connect these tables in LiveCode so that each user can do what I gave them the rights for.
I'm able to add new users with password and so on.

Can't you connect to the correct tables according to the technique explained above?
Or just create different "edit" or "access" cards for the different groups?
Know what I mean?
Best
Klaus