This is a migrated thread and some comments may be shown as answers.

How to obtain User Id from ObjectScope or Database Object?

3 Answers 85 Views
Getting Started
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Huy
Top achievements
Rank 1
Huy asked on 03 Aug 2009, 11:48 AM
How do I go about obtaining the UserId used to open the database connection?

I'm aware that we can use the ConnectionURL property of the Database object, and I am looking to obtain just the UserId information.

Thank you in advance...

3 Answers, 1 is accepted

Sort by
0
Jan Blessenohl
Telerik team
answered on 04 Aug 2009, 07:13 AM
Hello Huy ,
At the moment parsing the ConnectionURL is the only way.

Kind regards,
Jan Blessenohl
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Huy
Top achievements
Rank 1
answered on 04 Aug 2009, 06:13 PM
If Integrated Security is used, Can UserId information still be obtained thru Telerik objects? or it has to be thru other means....

I'm using SQL 2005, and in my tables I have "CreateBy" field to capture user who created the record. In SQL 2005, I setup default value for this field to "suser_sname()"; however, using Telerik OA doesn't trigger default values to be populated. I understand this is its limitation at the moment. Will this be resolved in the next release?

Thank you.
0
Jan Blessenohl
Telerik team
answered on 05 Aug 2009, 07:09 AM
Hi Huy ,
In .NET just use

Environment

 

.UserName;

 


Regards,
Jan Blessenohl
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
Getting Started
Asked by
Huy
Top achievements
Rank 1
Answers by
Jan Blessenohl
Telerik team
Huy
Top achievements
Rank 1
Share this question
or