Search:
Namespaces
Discussions
.NET v1.1
Feedback
Users table and UserRoles table question
Messages
Related Types
This message was discovered on
ASPFriends.com 'aspngibuyspy' list
.
Ronald Ward
I want to load a very large number of users manually into the portal user
table, however I do not want everyone to have the same user role setting.
Since these are two separate tables it is tricky to batch import into the
Users table while also assigning appropriate UserRoles id setting. I was
wondering if anyone here has done the same and how it was achieved.
So far all I could think of was to pre-sort each block of users based on
their role id and import just that batch, of say users that are of user role
1. I would then jot down the starting id in the Users table and also the
ending id. Then pop over to the UserRoles table and assign users 1 thru 20
say, the role id of 1.
This seems very manual and since my total user population is roughly 12k it
also does not seem like an efficient way of doing this.
Any suggestions?
-Ronald Ward
Reply to this message...
Karen Healey
Why don't you write a program that reads a role from a file (text or xml based file), creates the role using the stored procedure, then reads a list of users for that role, creates those users, and moves on to the next role.
Don't try to do it all with a SQL script.... do it in VB or C#.
Karen
----- Original Message -----
From: Ronald Ward
To: aspngibuyspy
Sent: Tuesday, July 23, 2002 10:52
Subject: [aspngibuyspy] Users table and UserRoles table question
I want to load a very large number of users manually into the portal user table, however I do not want everyone to have the same user role setting. Since these are two separate tables it is tricky to batch import into the Users table while also assigning appropriate UserRoles id setting. I was wondering if anyone here has done the same and how it was achieved.
So far all I could think of was to pre-sort each block of users based on their role id and import just that batch, of say users that are of user role 1. I would then jot down the starting id in the Users table and also the ending id. Then pop over to the UserRoles table and assign users 1 thru 20 say, the role id of 1.
This seems very manual and since my total user population is roughly 12k it also does not seem like an efficient way of doing this.
Any suggestions?
-Ronald Ward
| [aspngibuyspy] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.asplists.com/asplists/aspngibuyspy.asp
= JOIN/QUIT
|
http://www.asplists.com/search
= SEARCH Archives
Reply to this message...
Brian Desmond
Definitely. The only way to really do this sort of transformation with
SQL is to use the Data Import Wizard that comes with the Client Tools.
And even then, youll probably have to write a lot of Transact to get it
all the way you want.
A Simple program that loops through the file & Does the Inserts on the
Database will make it a lot easier on you.
--Brian Desmond
HYPERLINK "mailto:
Click here to reveal e-mail address
"
Click here to reveal e-mail address
-----Original Message-----
From: Karen Healey [mailto:
Click here to reveal e-mail address
]
Sent: Tuesday, July 23, 2002 7:41 PM
To: aspngibuyspy
Subject: [aspngibuyspy] Re: Users table and UserRoles table question
Why don't you write a program that reads a role from a file (text or xml
based file), creates the role using the stored procedure, then reads a
list of users for that role, creates those users, and moves on to the
next role.
Don't try to do it all with a SQL script.... do it in VB or C#.
Karen
----- Original Message -----
From: HYPERLINK "mailto:
Click here to reveal e-mail address
"Ronald Ward
To: HYPERLINK "mailto:
Click here to reveal e-mail address
"aspngibuyspy
Sent: Tuesday, July 23, 2002 10:52
Subject: [aspngibuyspy] Users table and UserRoles table question
I want to load a very large number of users manually into the portal
user table, however I do not want everyone to have the same user role
setting. Since these are two separate tables it is tricky to batch
import into the Users table while also assigning appropriate UserRoles
id setting. I was wondering if anyone here has done the same and how it
was achieved.
So far all I could think of was to pre-sort each block of users based on
their role id and import just that batch, of say users that are of user
role 1. I would then jot down the starting id in the Users table and
also the ending id. Then pop over to the UserRoles table and assign
users 1 thru 20 say, the role id of 1.
This seems very manual and since my total user population is roughly 12k
it also does not seem like an efficient way of doing this.
Any suggestions?
-Ronald Ward
| [aspngibuyspy] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.asplists.com/asplists/aspngibuyspy.asp
= JOIN/QUIT
|
http://www.asplists.com/search
= SEARCH Archives
| [aspngibuyspy] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.asplists.com/asplists/aspngibuyspy.asp
= JOIN/QUIT
|
http://www.asplists.com/search
= SEARCH Archives
---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (
http://www.grisoft.com
).
Version: 6.0.373 / Virus Database: 208 - Release Date: 7/1/2002
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (
http://www.grisoft.com
).
Version: 6.0.373 / Virus Database: 208 - Release Date: 7/1/2002
Reply to this message...
Duncan C. Ion
Ronald,
Take your 12K list and set it up in excel along with an extra column for
the User Role. Upload the excel data to a temporary table in SQL to take
the column details and write a SPROC (Stored Procedure) to insert the
table contents accordingly into the User and roles tables.
with regards,
Duncan
email:
Click here to reveal e-mail address
All outgoing email is scanned using the Norton Antivirus system.
This email is private and may contain confidential matter. If you are
not the designated recipient, please return this email to
<mailto:
Click here to reveal e-mail address
>
Click here to reveal e-mail address
Thank you.
-----Original Message-----
From: Ronald Ward [mailto:
Click here to reveal e-mail address
]
Sent: 23 July 2002 15:52
To: aspngibuyspy
Subject: [aspngibuyspy] Users table and UserRoles table question
I want to load a very large number of users manually into the portal
user table, however I do not want everyone to have the same user role
setting. Since these are two separate tables it is tricky to batch
import into the Users table while also assigning appropriate UserRoles
id setting. I was wondering if anyone here has done the same and how it
was achieved.
So far all I could think of was to pre-sort each block of users based on
their role id and import just that batch, of say users that are of user
role 1. I would then jot down the starting id in the Users table and
also the ending id. Then pop over to the UserRoles table and assign
users 1 thru 20 say, the role id of 1.
This seems very manual and since my total user population is roughly 12k
it also does not seem like an efficient way of doing this.
Any suggestions?
-Ronald Ward
| [aspngibuyspy] member
Click here to reveal e-mail address
= YOUR ID
|
http://www.asplists.com/asplists/aspngibuyspy.asp
= JOIN/QUIT
|
http://www.asplists.com/search
= SEARCH Archives
Reply to this message...
Ad
MBR BootFX
Best-of-breed application framework for .NET projects, developed by Matthew Baxter-Reynolds and MBR IT
Copyright © Matthew Baxter-Reynolds 2001-2008. '.NET 247 Software Development Services' is a trading style of MBR IT Solutions Ltd.
Contact Us
-
Terms of Use
-
Privacy Policy
-
www.dotnet247.com