Microsoft Windows Vista Community Forums - Vistaheads
Recommended Download



Welcome to the Microsoft Windows Vista Community Forums - Vistaheads, YOUR Largest Resource for Windows Vista related information.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so , join our community today!

If you have any problems with the registration process or your account login, please contact us.

Driver Scanner

Vista and SQL Express issues

microsoft.public.windows.vista.security






Speedup My PC
Reply
  #1 (permalink)  
Old 06-22-2007
mmcd79@tampabay.rr.com
 

Posts: n/a
Vista and SQL Express issues
Can someone point me in the right direction here?

I have Vista with SQL Express installed. I can run the SQL Express
Management console (without running as administrator), and because of
my rights in SQL I can access the system tables fine.

I created a new database and I put the DB/log files in a different
directory (i.e. D:\MSSQL). I can NOT access this database unless I
start the SQL Express Management console with the "run as
administrator" privilege.

Furthermore, I can't even edit the files in D:\MSSQL with any program
unless I "run as administrator". How do I grant myself access to a
newly created folder so I can access the files there without "run as
administrator" right?

I understand why this option is here (for my protection), but I don't
understand why Vista thinks DB files located in C:\Program Files
\Microsoft SQL Server\MSSQL\Data is "SAFE" and allows me access
without "run as administrator" right, but a newly created directory is
"NOT SAFE" and requires me to have this right.

I can't see a feasible way to make this work UAC enabled.

Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 06-22-2007
mmcd79@tampabay.rr.com
 

Posts: n/a
Re: Vista and SQL Express issues
Correction.. I misidentified some information in my original post.

I can edit data fine under d:\mssql\data, i.e. text documents. I
remember what I meant to say. When I created the DB's and told the
SQL management console to change their location during creation to
this directory, I could not do it unless I ran SQL management console
as administrator.

To further clarify... I'm looking in my D:\mssql\data directory right
now. If I create a text file in there and look at the properties of
this file.. I can click the Security tab and it lists the permissions
fine. But if I check the properties of the MDF (database) file
located in this same directory, and click the security tab.. I get the
message: "you must be an administrative user with permission to view
this object's security properties" with a button to continue, in which
case I get prompted by UAC to run as administrator.

I proceeded by running as administrator, and set my permissions to
inherit from parent folder, and now I can see the permissions on the
MDF file like I could with the text file. But my problems still exist
with SQL Management Console.

Unless I run the SQL management console as administrator, I cannot
expect my DB, however I can expand the system databases with no
problem. WTF is going on?

The reason I ask, is because I just made a .NET application (on vista)
that reads data from this database. It cannot query the DB unless I
run the app as administrator. I shouldn't have to do this when the
account I'm using IS AN ADMINISTRATOR, especially on the Database.
I'm just missing something stupid here. Please help!

On Jun 22, 2:47 am, mmc...@tampabay.rr.com wrote:
> Can someone point me in the right direction here?
>
> I have Vista with SQL Express installed. I can run the SQL Express
> Management console (without running as administrator), and because of
> my rights in SQL I can access the system tables fine.
>
> I created a new database and I put the DB/log files in a different
> directory (i.e. D:\MSSQL). I can NOT access this database unless I
> start the SQL Express Management console with the "run as
> administrator" privilege.
>
> Furthermore, I can't even edit the files in D:\MSSQL with any program
> unless I "run as administrator". How do I grant myself access to a
> newly created folder so I can access the files there without "run as
> administrator" right?
>
> I understand why this option is here (for my protection), but I don't
> understand why Vista thinks DB files located in C:\Program Files
> \Microsoft SQL Server\MSSQL\Data is "SAFE" and allows me access
> without "run as administrator" right, but a newly created directory is
> "NOT SAFE" and requires me to have this right.
>
> I can't see a feasible way to make this work UAC enabled.



Reply With Quote
  #3 (permalink)  
Old 06-22-2007
Mr. Arnold
 

Posts: n/a
Re: Vista and SQL Express issues

<mmcd79@tampabay.rr.com> wrote in message
news:1182495497.447598.195470@q75g2000hsh.googlegr oups.com...
> Correction.. I misidentified some information in my original post.
>
> I can edit data fine under d:\mssql\data, i.e. text documents. I
> remember what I meant to say. When I created the DB's and told the
> SQL management console to change their location during creation to
> this directory, I could not do it unless I ran SQL management console
> as administrator.
>
> To further clarify... I'm looking in my D:\mssql\data directory right
> now. If I create a text file in there and look at the properties of
> this file.. I can click the Security tab and it lists the permissions
> fine. But if I check the properties of the MDF (database) file
> located in this same directory, and click the security tab.. I get the
> message: "you must be an administrative user with permission to view
> this object's security properties" with a button to continue, in which
> case I get prompted by UAC to run as administrator.
>
> I proceeded by running as administrator, and set my permissions to
> inherit from parent folder, and now I can see the permissions on the
> MDF file like I could with the text file. But my problems still exist
> with SQL Management Console.
>
> Unless I run the SQL management console as administrator, I cannot
> expect my DB, however I can expand the system databases with no
> problem. WTF is going on?


I suggest that you go look at the accounts on Master.MDF and LDF files and
match the accounts on the MDF and LDF files in question. You need NETWORK
SERVICE, SQLServer2005MSSQLUser blah blah whatever and
machine-name/Administrator accounts with full access for the accounts.
NETWORK SERVICES replaces the SYSTEM account.

>
> The reason I ask, is because I just made a .NET application (on vista)
> that reads data from this database. It cannot query the DB unless I
> run the app as administrator. I shouldn't have to do this when the
> account I'm using IS AN ADMINISTRATOR, especially on the Database.
> I'm just missing something stupid here. Please help!


http://blogs.msdn.com/nikhiln/archiv...-in-vista.aspx

This NG is not a MS SQL Server or a .NET NG. I suggest that if you need
further assistance that you post to MS.Public NG(s) concerning the problems
so you can get help.



Reply With Quote
  #4 (permalink)  
Old 06-24-2007
mmcd79@tampabay.rr.com
 

Posts: n/a
Re: Vista and SQL Express issues
Thanks, I'll give your suggestions a try. I did happen to see a SQL
based user (i.e. SQLServer2005MSSQLUser$)that I've never seen before.

As far as the NG, I originally thought this was a problem was directly
related Vista's new security model, and still indeed think that to be
the case, so this NG should be perfectly fine for my request.
Granted, it may be possible to get better help from a SQL specific NG,
but a generic public NG? I doubt that. Thanks for the suggestion
however.

On Jun 22, 8:18 am, "Mr. Arnold" <MR. Arn...@Arnold.com> wrote:
> <mmc...@tampabay.rr.com> wrote in message
>
> news:1182495497.447598.195470@q75g2000hsh.googlegr oups.com...
>
>
>
>
>
> > Correction.. I misidentified some information in my original post.

>
> > I can edit data fine under d:\mssql\data, i.e. text documents. I
> > remember what I meant to say. When I created the DB's and told the
> >SQLmanagement console to change their location during creation to
> > this directory, I could not do it unless I ranSQLmanagement console
> > as administrator.

>
> > To further clarify... I'm looking in my D:\mssql\data directory right
> > now. If I create a text file in there and look at the properties of
> > this file.. I can click the Security tab and it lists the permissions
> > fine. But if I check the properties of the MDF (database) file
> > located in this same directory, and click the security tab.. I get the
> > message: "you must be an administrative user with permission to view
> > this object's security properties" with a button to continue, in which
> > case I get prompted by UAC to run as administrator.

>
> > I proceeded by running as administrator, and set my permissions to
> > inherit from parent folder, and now I can see the permissions on the
> > MDF file like I could with the text file. But my problems still exist
> > withSQLManagement Console.

>
> > Unless I run theSQLmanagement console as administrator, I cannot
> > expect my DB, however I can expand the system databases with no
> > problem. WTF is going on?

>
> I suggest that you go look at the accounts on Master.MDF and LDF files and
> match the accounts on the MDF and LDF files in question. You need NETWORK
> SERVICE, SQLServer2005MSSQLUser blah blah whatever and
> machine-name/Administrator accounts with full access for the accounts.
> NETWORK SERVICES replaces the SYSTEM account.
>
>
>
> > The reason I ask, is because I just made a .NET application (on vista)
> > that reads data from this database. It cannot query the DB unless I
> > run the app as administrator. I shouldn't have to do this when the
> > account I'm using IS AN ADMINISTRATOR, especially on the Database.
> > I'm just missing something stupid here. Please help!

>
> http://blogs.msdn.com/nikhiln/archiv...a-manifest-to-...
>
> This NG is not a MSSQLServer or a .NET NG. I suggest that if you need
> further assistance that you post to MS.Public NG(s) concerning the problems
> so you can get help.- Hide quoted text -
>
> - Show quoted text -



Reply With Quote
  #5 (permalink)  
Old 06-24-2007
Mr. Arnold
 

Posts: n/a
Re: Vista and SQL Express issues

<mmcd79@tampabay.rr.com> wrote in message
news:1182660326.473604.194060@k79g2000hse.googlegr oups.com...
> Thanks, I'll give your suggestions a try. I did happen to see a SQL
> based user (i.e. SQLServer2005MSSQLUser$)that I've never seen before.
>
> As far as the NG, I originally thought this was a problem was directly
> related Vista's new security model, and still indeed think that to be
> the case, so this NG should be perfectly fine for my request.
> Granted, it may be possible to get better help from a SQL specific NG,
> but a generic public NG? I doubt that. Thanks for the suggestion
> however.


When I say generic public NG I mean, like MS.Public.dotnet (csharp, vb or
general), with people that use SQL Server as programmer's.

I can tell you that I have MS SQL Server 2005 Express and VS 2005 Express on
this Vista machine. I don't have any of the problems you're having.

I did download the Pubs and Author MDF and LDF files I needed for MCTS
70-528 training I am doing. I was getting access denied when I was trying to
attach the files to SQL server. I found out the accounts on the files needed
to do the attach. I put them there, the ones I talked about, and I went on
about my business.

I think you have an accounts permission issue not only with SQL server but
also with a .NET application trying to access the database, which are the
MDF and LDF files.

You have account permission issue, not really related Vista per say.



Reply With Quote
  #6 (permalink)  
Old 06-25-2007
mmcd79@tampabay.rr.com
 

Posts: n/a
Re: Vista and SQL Express issues
I hope I didn't come off too strong, my apologies if it came off that
way. I really appreciate you even responding.

This is definitely permissions related, I just don't know for sure.
You mention you are not having problems, but I'm wondering if you
actually created your databases yourself (or via installer for the
downloaded dbs). I happened to "restore from backup", and I think my
databases still have the permissions from the original database, and
that may be one area for my problems. I'm by no means a SQL DBA, so
I'm probably just overlooking something simple.

I'll post to a SQL group to see if I can get further assistance.
Thanks!

On Jun 24, 1:44 am, "Mr. Arnold" <MR. Arn...@Arnold.com> wrote:
> <mmc...@tampabay.rr.com> wrote in message
>
> news:1182660326.473604.194060@k79g2000hse.googlegr oups.com...
>
> > Thanks, I'll give your suggestions a try. I did happen to see aSQL
> > based user (i.e. SQLServer2005MSSQLUser$)that I've never seen before.

>
> > As far as the NG, I originally thought this was a problem was directly
> > related Vista's new security model, and still indeed think that to be
> > the case, so this NG should be perfectly fine for my request.
> > Granted, it may be possible to get better help from aSQLspecific NG,
> > but a generic public NG? I doubt that. Thanks for the suggestion
> > however.

>
> When I say generic public NG I mean, like MS.Public.dotnet (csharp, vb or
> general), with people that useSQLServer as programmer's.
>
> I can tell you that I have MSSQLServer 2005 Express and VS 2005 Express on
> this Vista machine. I don't have any of the problems you're having.
>
> I did download the Pubs and Author MDF and LDF files I needed for MCTS
> 70-528 training I am doing. I was getting access denied when I was trying to
> attach the files toSQLserver. I found out the accounts on the files needed
> to do the attach. I put them there, the ones I talked about, and I went on
> about my business.
>
> I think you have an accounts permission issue not only withSQLserver but
> also with a .NET application trying to access the database, which are the
> MDF and LDF files.
>
> You have account permission issue, not really related Vista per say.



Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Microsoft SQL Server 2005 Express Edition Service Pack 2 (KB 92189 Puppy Breath microsoft.public.windows.vista.general 7 07-23-2008 16:10
Denied access to SQL Express database files =?iso-8859-1?Q?Stig_Kulvedr=F8sten?= microsoft.public.windows.vista.general 5 03-01-2007 02:47




All times are GMT +1. The time now is 20:40.




Driver Scanner - Free Scan Now

Vistaheads.com is part of the Heads Network. See also XPHeads.com , Win7Heads.com and Win8Heads.com.


Design by Vjacheslav Trushkin for phpBBStyles.com.
Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.6.0 RC 2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120