|
SoftTree Technologies
Technical Support Forums
|
|
Author |
Message |
AndersChan
Joined: 01 Feb 2007 Posts: 2
|
|
BugReport - Popup not working for non-SystemAdmin account |
|
In SQL Query Analyzer or Microsoft SQL Management Studio, if you connect to the SQLServer database using an account WITHOUT System Admin role, the pop up will not come up automatically after you type 'SELECT [Space]' or even after you hit [CTRL][SPACE].
e.g.
You have to at least provide the database name in order for the pop up to come up:
However, if the account you are using has the System Admin role, pop up will appear right after you type 'SELECT [Space]':
I ran a SQL profiler trace and it appears to me that SQLAssistant is issuing the following SQL statement to determine the current username.
select serverproperty('ServerName'), system_user, db_name(), user_name()
For a SystemAdmin account, the user_name() function by default will return 'dbo'. For a non-SystemAdmin account, the user_name() function will return whatever the current user's username which may not be 'dbo':
Unfortunately it appears to me that this SQLStatement is not configuable.
I hope this bug report helps.
Anders
|
|
Thu Feb 01, 2007 11:14 pm |
|
|
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7907
|
|
|
|
Hi ,
Thanks for the detailed information. We will look into this and check what can be done quickly to fix this issue. For now, if you usually login with the same login, I suggest you customize the "Objects (MSSQL)" query in SQL Assistant options and basically hard-code it to return objects from your schema. In line "and uid = ?" replace it with something like "and uid = user_id('your name') and ? is not null"
The "DB Options" tab page in the Options provides you with nearly complete control over SQL Assistant database interactions and behavior
Thanks,
SysOp
|
|
Fri Feb 02, 2007 1:43 am |
|
|
AndersChan
Joined: 01 Feb 2007 Posts: 2
|
|
|
|
Thank you for the fast response. Keep up the good work. I do like SQLAssistant better than SQLPrompt because of performance and configurability reasons.
I tried your suggestion and it does fix some of my issues.
For some databases, where I actually have an individual account, changing the "Objects (MSSQL)" query to what you have suggested works. For those databases,
select user_name() will return my username.
select user_id() will return a value > 0 (ie. one of the sysusers)
This is good. Thanks for your suggestion.
However, for other databases, where I indirectly have access via a NT User Group, I still could not get it to work. I even removed the whole uid = .... criteria so that it reads
select
name, xtype, id
from
/*db.*/dbo.sysobjects
where
xtype in ('U','S','V','P','X','RF','FN','TF','IF')
and not (name = 'dtproperties')
and not (name like 'dt%' and xtype = 'P')
But that doesn't do the trick. If I execute the above modified query directly in SQL query analyser, it will return all the objects fine. So I guess SQLAssistant is doing some extra filterings after it gets all the objects from this query.
I might be wrong but I think it might have something to do with the fact that I don't actually have an account directly on this database. In other words, my NT username 'AD\anchan' does not exist in the sysusers table.
Anyway, hope this information helps. Thanks.
Anders
|
|
Fri Feb 02, 2007 6:08 pm |
|
|
oliverdbw
Joined: 03 Apr 2007 Posts: 3 Country: United Arab Emirates |
|
No pop up after installation while using SQL PLUS for Oracle |
|
Hi, after installing the sql assistant, i run SQL PLUS for oracle. i was able to logon to the server but when i was creating a script (i.e SELECT * .....) after the 'Select' word, an error message would appear.
|
|
Wed Apr 04, 2007 4:08 am |
|
|
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7907
|
|
|
Wed Apr 04, 2007 7:55 am |
|
|
oliverdbw
Joined: 03 Apr 2007 Posts: 3 Country: United Arab Emirates |
|
|
|
Hi,
Thanks for this reply. I have one query though, I can only install one of the fix right? If I install both, it will overide the previous installation.
|
|
Wed Apr 04, 2007 11:42 pm |
|
|
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7907
|
|
|
|
Newest builds overwrite oldest builds, updating modified files, but not the opposite. To have an oldest build installed you need first to uninstall the current build or simply delete the files then install the needed build. Try #77 first, if doesn't work or you don't like it just delete the files and install #70.
|
|
Thu Apr 05, 2007 12:02 am |
|
|
oliverdbw
Joined: 03 Apr 2007 Posts: 3 Country: United Arab Emirates |
|
|
|
Hi,
Thanks. I will try first build 70 since it has been fully tested, Im new to sql assistant so i will try this build first.
|
|
Thu Apr 05, 2007 12:12 am |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|