Showing posts with label net. Show all posts
Showing posts with label net. Show all posts

Tuesday, March 20, 2012

Cannot open database"..."requested by the login...??

Hello,

I am using Visual Web Developer 2005 Express Edition and I am following the book:"Beginning ASP.NET 2.0 E-commerce in C# . I am encountering a problem and I haven't got the slightest idea how to solve the problem.

(If you have the book I got to p98)

If I debug then I get the next error: cannot open database"..." requested by the login...

In the book I had to make a GenericDataAccess.cs. What follows are snippets where the error occurs.

public static DataTable ExecuteSelectCommand(DbCommand command)

{

DataTable table

try

{

command.Connection.Open();

DbDataReader reader = command.ExecuteReader();

table = new DataTable();

table.Load(reader);

reader.Close();

}

catch (Exception ex)

{

Utilities.LogError(ex);

throw ex; //this is where my error occurs when I debug it

}

finally

{

commandConnection.close();

}

return table;

}

Ideas and sollutions are more than welcome :-)

YES!!!

I'm currently using the same book and having the same problem too!

May i ask if how did you bypass the SQL Express part? Which programs did you use to substitute SQL Express Manager? I'm having problems with my database connection.

Would appreciate if you can share.

Thanks!

Cannot open database requested in login ?!(help me ! )

Hi
I'm new in using "SqlClient" I have SQLSERVER 2000 on my computer and I made a Database named "TestDB", and a code like this both Using VS.net :

// begin test Code ///////////////////////////////////
string connectionString =
"Integrated Security=SSPI;Persist Security Info=False;Initial Catalog= TestDB;Data Source=HOSSEIN-COM;Workstation ID=HOSSEIN-COM";
string commandString =
"Select * from Categories";
SqlDataAdapter DataAdapter =
new SqlDataAdapter(
commandString, connectionString);
DataSet DataSet = new DataSet( );
DataAdapter.Fill(DataSet,"CategoryID");
Label1.Text= DataSet.Tables[0].Rows[0]["CategoryID"].ToString();

// end test code /////////////////////////////////////

And at browser I found this error when I Start Building the project:

"Cannot open database requested in login 'testdb'. Login fails. Login failed for user '(my coputer name / my name )' "

Then I changed Catalog= TestDB to Catalog= Northwind and the table name to and available table name and it works , then I tried to create a table at northwind database but this error appeared :
"SELECT permission denied on object 'testTB', database 'Northwind', owner 'dbo'"
TestTB = my northwind table
I guess there must be some security setting in creating databases and tables that I do not know , And when I tried to install quick start the database was not installed ,
I have XP and VS.net and SQLserver 2000 . please halp me as You always do ;) …you need to add the user machinename/ASPNET to the db and also give select permissions to this user on the tables.

hth

Cannot open database requested in login

Hi there i'm having a bit of trouble with my asp.net authorisations and was wondering
if anyone would have any idea how I can solve it - as it's driving me nuts!.

On my local machine (I've MDSN) running with Web Matrix - my connection works fine.

However since i've uploaded it to my Hoster - Forms and DB - I get the error

Cannot open database requested in login 'TestDB'. Login fails. Login failed for user AUTHORITY\NET SERVICE'.

Can anyone give me any pointers on where I should be going?

I've been told by my Hosting co. that the server should be set to localhost (as shown)
but thats about it!

My Web.config file looks like:-

<configuration>
<!-- application specific settings -->
<appSettings>
<add key="ConnectionString" value="server=localhost;Trusted_Connection=true;database=TestDB" />
</appSettings
<!-- forms based authentication --
<system.web>
<!-- enable custom errors for the application -->
<customErrors mode="Off"/>
<!--RemoteOnly" defaultRedirect="ErrorPage.aspx" -->
<!-- disable session state for application -->
<sessionState mode="Off" />
</system.web>
</configuration
Thanks in advance for any help.

Dave.Did the host say whether you should use NT Authorization or Sql Authorization? You are using NT Authorization now but perhaps it should be Sql Authorization. If so you'll have to change your connection string to something like:

data source=localhost;initial catalog=TestDb;password=whatever;user id=whatever;packet size=4096

Of course you'll need to find out what username and password to use.|||I know netiquete etc but had to thank you!

Just like to say thanks for that invaluable piece of information!

If anyone else has the problem i've been getting then the solution proposed by McMurdoStation was absolutly spot on.

Thanks again.

Dave|||Your welcome.

Cannot open database on local server

Server Error in '/QuickStartv20/aspnet/samples/data' Application.


This is the error i am getting when i was going through the asp .net quickstart tutorials to learn using the databases. I have installed sql server 2005 on windows xp along with asp .net framework 2.0 on my system. i am student, so i dont how to configure a database. i went through a lot of tutorials of microsoft and macromedia but was unable to get the information requirred to create and access the database on asp .net and sql servers. they assumed that all know how to configure the database to work with the dynamic pages.

|||||||||||||||||||||||||

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException: Cannot open database "pubs" requested by the login. The login failed.
Login failed for user 'MLHPR\ASPNET'.

|||||||||||||||||||||||||

this was another line from the error page.i need help in configuring the sql (and asp .net) server to use the database. i have been getting a lot these error pages when i tried to open (local)database related pages on my system.

i am very much thankful to any help given in this regard.

It looks like the user in the machine/domain MLHPR called ASPNET is the one trying to access the database. I'll bet there's no login for that user in the system.

The first thing to do is try and see if you can connect at all - on the server where SQL Server lives, type this at a Windows command prompt:

osql -E -d pubs -Q "SELECT 'I got in.'"

If you see the words "I got in" on the screen, then SQL Server is up and running. If not, either SQL isn't installed or there is no database called "pubs" on it.

You can read more about SQL Server security here: http://www.informit.com/guides/content.asp?g=sqlserver&seqNum=35&rl=1

Note: If this answers your question, make sure you mark it "answered" so that others can find it!

Buck Woody
http://www.buckwoody.com

|||

thanks you very much for your response

ya pubs was not configured to be used with the sql server. i searched for the file and found the file in some folder of sql but not on the sql server. then i worked around in the microsoft .net folder to find the installation file for configuring the databases 'pubs' and 'northwind' on the sql server.

when i installed the file it worked fine.another reason was that i forgot to add the server to the expection list of the firewall.

the installation file for databases was in the 'microsoft .net/sdk/v2.0/samples/setup/' folder for using with quickstart samples of the asp .net.

Monday, March 19, 2012

Cannot open connection to AS 2005

Hi All,

I have installed AS 2005 and am using VS 2005 and .Net 2.0.

Connection to AS 2005 is configured for HTTP.

Whenever I open a connection it gives me below error.

"Object not found".

Stack Trace:

at System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection)\r\n
at System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject)\r\n
at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup)\r\n
at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)\r\n
at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)\r\n
at System.Data.OleDb.OleDbConnection.Open()\r\n

Below is peace of code:

string Connection = "Provider=MSOLAP.2;Data Source=http://localhost/olap; Initial Catalog=Cube1";

conn = new OleDbConnection(Connection);

conn.Open();

string Query = " ";

OleDbCommand dbCommand = new OleDbCommand(Query, conn);

dbCommand.CommandType = CommandType.Text;

dtrdr = dbCommand.ExecuteReader();

I have .Net 1.1 installed and vs.net 2003 as well as ADOMD.Net 8.0.

I guess when VS.NET 2005 is installed, ADOMD.NET 9.0 should be automatically installed.

Do I need to install ADOMD.Net 9.0 manually.

Appreciate your help as this issue needs to be resolved urgently.

Regards,

Try using

Provider=MSOLAP

rather than

Provider=MSOLAP.2

In your connection string. MSOLAP.2 is the AS2K version of the provider and will probably have problems connecting to AS2005.

Also, the Initial Catalog property should refer to the name of the AS database you're connecting to, not a cube. Is your database really called 'Cube1'?

You may also need to install ADOMD.Net 9.0 manually too...

Chris

|||

Hi Chris,

I tried with Provider=MSOLAP but could not succeed.

You are right. I wrote Cube1 instead of Database name in my post by mistake.

I tried with TCP/IP connection. But I got different error now. It says

"Can not connect to server. Server is either not started or too busy"

But I can view Database in SQL Server Management .

Regards,

|||

Try getting rid of "http://" from your connection string.

Also, you talk about using ADOMD NET 9.0, but you are using OLEDB...which do you want to use?

|||

Hi,

I am not sure if you have to remove "http://" from the connection string, but.....

Try the following:

1. Try using the provider MSOLAP .3 also.

2. Next, add the user account IUSR to a role with required permissions in SSAS 2005.

3. Another check is to see if you have configured msmdpump to connect to the specific SSAS server.

4. The connection string must include msmdpump.dll in the path (see exmaple)

5. Also the connection string can include a username and password. here is an example:

"Provider=MSOLAP.3;

Persist Security Info=True;

Data Source=http://[target server]/olap/msmdpump.dll;

Initial Catalog=PNGReportOLAP;

User Id=[user id];Password=[password]"

6. Read this link for all other details on connectivity problems to ssas 2005 :

http://www.sqljunkies.com/WebLog/edwardm/archive/2006/05/26/21447.aspx

7. For more details on connection strings, check this article:

http://www.connectionstrings.com/

8. An additional thing which I wanted to mention is, you need to use .Net 2.0. only. I am not sure if .Net 1.1 supports ADOMD.Net and some connection features of ssas 2005.

Hope this helps

Regards

Cannot open connection to Access Database.

I am very new to VB.Net but my goal is to build a web app that ineracts with an Access database. This is a very small scale app so I am not interested in using SQL server. I created my Access database and the udl file for connection information.

I created a class that opens a connection to the database when the webpage loads.

I get the following error though,

System.Data.OleDb.OleDbException was unhandled by user code
ErrorCode=-2147467259
Message="The Microsoft Jet database engine cannot open the file 'C:\Inetpub\wwwroot\Test1\RaceData.mdb'. It is already opened exclusively by another user, or you need permission to view its data."
Source="Microsoft JET Database Engine"
StackTrace:
at System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection)
at System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup)
at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
at System.Data.OleDb.OleDbConnection.Open()
at clsDBConn.Open_Connection() in c:\inetpub\wwwroot\Test1\App_Code\clsDBConn.vb:line 12
at Default2.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\Test1\Default2.aspx.vb:line 8
at System.Web.UI.Control.OnLoad(EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

The database is not open so I know it is a matter of security. I have configured IIS to use an admin account and the Access db does not have security turned on. In the UDL file I have selected read/write access and the test connection works.

Can anyone help me narrow down the root of this error,

Thanx in advance,

Chris

Topfuel5

Hi,

The Error is self descriptive that means either you don't have proper privilege or the file is either opened in Edit Mode refer below links for work around

http://support.microsoft.com/kb/174943 & http://www.xlinesoft.com/asprunner/docs/error_the_microsoft_jet_database_engine_cannot%20open%20the%20file%20(unknown).htm

Hemantgiri S. Goswami

Wednesday, March 7, 2012

cannot install sql server 2005 as SSL-certificate is missing

Hi there U all,

for the third time I am installing SQL-Server 2005 express and i have an error.

Cannot install sql because .NET 2.0 framework is missing allthough I have the .NET 2.0 framework allready installed and even re-installed it too. When trying again I get the message that there isn't an SSL-certificate present.

My question is, would this probably cause the error when installing?

Anyone?

Grtz and thx,

Recloose(Thomas)

Hi Thomas,

It's hard to tell what the problem might be without an actual error message, but there are a number of questions about install errors related to IIS in the forums that you could search for. Here are a couple:

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=90906&SiteID=1

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=892757&SiteID=1

Mike

Cannot install SQL Express; peculiar error

SQL Express installation is bombing out with the "A beta version of the .NET Framework 2.0 or SQL Server was detected on the computer...".

From the log file:

Running: PerformSCCAction2 at: 2007/6/26 8:17:27
Loaded DLL:C:\WIN\system32\msi.dll Version:3.1.4000.2435
Product "{7131646D-CD3C-40F4-97B9-CD9E4E6262EF}" versioned 2.0 is not compatible with current builds of SQL Server.Expected at least version: 2.0.50727.42
The Product Name is ".NET Framework"

Now what is peculiar to me is that

1) this machine should have never had the beta software on it;

2) I have seen people with similar issues except their versioned info always said "versioned 2.0.50727" and the product guid is different, this one only says "2.0"; and

3) I thought that product guid was for the RTM 2.0.50727.42 release!

What is going on here and where is it getting this version information?

brian

Try running the removal tool from here: http://go.microsoft.com/fwlink/?LinkId=47598

Jens K. Suessmeyer

http://www.sqlserver2005.de

Cannot install SQL E Service Pack 2 (KB921896)

Hi, i have a clean install of VB2005 Express and it's accompanying SQL Server 2005 Express (yes i'm new to .net).

After installation i ran Windows Update and it found about 40mb of updates including SP1 for SQL Server. All installed correctly up to a reboot point, after which it continued with the update process.

When it reached SP2 (for SQL Server) it tried to install but just says "Updates were unable to be successfully installed" and "The following updates were not installed: Microsoft SQL Server 2005 Express Edition Service Pack 2 (KB 921896)".

Now i have a permanent icon in my system tray which when clicked tries to do the install with the same result.

During the attempted install my floppy drive 'buzzes' a couple of times.

I'm running an AMD3000+ (64bit) cpu with Windows 2000 Pro SP4

As mentioned in another post (on the VB Install forum) my MyDocuments folder is on a networked pc which has caused other non related problems, not sure if this could be responsible for the error. It would seem unlikely as SQL SP1 installed without any errors.

Any help appreciated.

Any official word on this ?|||

Depends on the issue you're encountering, what does the installer log say? You'll find it at C:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\LOG\Hotfix.

Mike

|||

Hi Mike, not too sure which file you need as the folder you mention contains many files and more folders !

However here is the latest 'summary.txt'

Code Snippet

Time: 04/28/2007 03:01:27.078
KB Number: KB921896
Machine: MyPcName
OS Version: Microsoft Windows 2000 Professional Service Pack 4 (Build 2195)
Package Language: 1033 (ENU)
Package Platform: x86
Package SP Level: 2
Package Version: 3042
Command-line parameters specified:
/quiet
/allinstances
Cluster Installation: No

**********************************************************************************
Prerequisites Check & Status
SQLSupport: Passed

**********************************************************************************
Products Detected Language Level Patch Level Platform Edition
Express Database Services (SQLEXPRESS) ENU RTM 2005.090.1399.00 x86 EXPRESS
Express Database Services (SQLExpress) ENU RTM x86 EXPRESS

**********************************************************************************
Products Disqualified & Reason
Product Reason

**********************************************************************************
Processes Locking Files
Process Name Feature Type User Name PID

**********************************************************************************
Product Installation Status
Product : Express Database Services (SQLEXPRESS)
Product Version (Previous): 1399
Product Version (Final) :
Status : Failure
Log File : C:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\LOG\Hotfix\SQL9Express_Hotfix_KB921896_SQLEXPR.EXE
SQL Express Features : SQL_Data_Files,SQL_Engine,SQL_Replication,SQL_SharedTools
Error Number : 70095
Error Description : Unable to install Windows Installer MSI file
-
Product : Express Database Services (SQLExpress)
Product Version (Previous):
Product Version (Final) :
Status : Failure
Log File : C:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\LOG\Hotfix\SQL9Express_Hotfix_KB921896_SQLEXPR.EXE
SQL Express Features : Client_Components,Connectivity,SDK
Error Number : 70095
Error Description : Unable to install Windows Installer MSI file
-

**********************************************************************************
Summary
One or more products failed to install, see above for details
Exit Code Returned: 70095

However there is also a 'Hotfix.log' file:

Code Snippet

04/28/2007 03:00:24.312 ================================================================================
04/28/2007 03:00:24.312 Hotfix package launched
04/28/2007 03:00:24.343 Registry: Opened registry key "SOFTWARE\Microsoft\Windows\CurrentVersion"
04/28/2007 03:00:24.343 Registry: Read registry key value "CommonFilesDir", string value = C:\Program Files\Common Files
04/28/2007 03:00:24.343 Registry: Opened registry key "SOFTWARE\Microsoft\Windows\CurrentVersion"
04/28/2007 03:00:24.343 Registry: Read registry key value "ProgramFilesDir", string value = C:\Program Files
04/28/2007 03:00:24.343 Local Computer:
04/28/2007 03:00:24.343 Target Details: MyPcName
04/28/2007 03:00:24.343 commonfilesdir = C:\Program Files\Common Files
04/28/2007 03:00:24.343 lcidsupportdir = c:\3b642267874f8d43d14991c2\1033
04/28/2007 03:00:24.343 programfilesdir = C:\Program Files
04/28/2007 03:00:24.343 programfilesdir_wow = C:\Program Files
04/28/2007 03:00:24.343 supportdir = c:\3b642267874f8d43d14991c2
04/28/2007 03:00:24.343 supportdirlocal = c:\3b642267874f8d43d14991c2
04/28/2007 03:00:24.343 windir = C:\WINNT
04/28/2007 03:00:24.343 winsysdir = C:\WINNT\system32
04/28/2007 03:00:24.343 winsysdir_wow = C:\WINNT\SysWOW64
04/28/2007 03:00:24.343
04/28/2007 03:00:24.343 Enumerating applicable products for this patch
04/28/2007 03:00:24.343 Found SQL 2005 Express product definition
04/28/2007 03:00:25.250 Enumeration: Determining QFE level for product instance SQLEXPRESS
04/28/2007 03:00:25.265 Enumeration: Associated hotfix build information not found for the following file: c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Binn\SQLServr.exe
04/28/2007 03:00:25.265 Enumeration: Found following QFE level for product instance SQLEXPRESS: 1399
04/28/2007 03:00:25.265 Enumeration: Determining GDR branching Hotfix for product instance SQLEXPRESS
04/28/2007 03:00:25.265 Enumeration: Associated hotfix build information not found for the following file: c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Binn\SQLServr.exe
04/28/2007 03:00:25.265 Enumeration: No GDR branch Hotfix found for product instance SQLEXPRESS
04/28/2007 03:00:25.265 Enumeration: Determining QFE level for product instance
04/28/2007 03:00:25.296 Enumeration: Cannot find following key file for product instance : c:\Program Files\Microsoft SQL Server\90\Tools\\Binn\SQLServr.exe
04/28/2007 03:00:25.296 Enumeration: Determining GDR branching Hotfix for product instance
04/28/2007 03:00:25.296 Enumeration: Cannot find following key file for product instance : c:\Program Files\Microsoft SQL Server\90\Tools\\Binn\SQLServr.exe
04/28/2007 03:00:25.296 Registry: Opened registry key "SOFTWARE\Microsoft\Windows\CurrentVersion"
04/28/2007 03:00:25.296 Registry: Read registry key value "CommonFilesDir", string value = C:\Program Files\Common Files
04/28/2007 03:00:25.296 Registry: Opened registry key "SOFTWARE\Microsoft\Windows\CurrentVersion"
04/28/2007 03:00:25.296 Registry: Read registry key value "ProgramFilesDir", string value = C:\Program Files
04/28/2007 03:00:25.296 Product discovery completed during the install process for SQLEXPRESS
04/28/2007 03:00:25.296 SP Level check completed during the install process for SQLEXPRESS
04/28/2007 03:00:25.296 Product language check completed during the install process for SQLEXPRESS
04/28/2007 03:00:25.296 Product version check completed during the install process for SQLEXPRESS
04/28/2007 03:00:25.296 Registry: Opened registry key "SOFTWARE\Microsoft\Windows\CurrentVersion"
04/28/2007 03:00:25.296 Registry: Read registry key value "CommonFilesDir", string value = C:\Program Files\Common Files
04/28/2007 03:00:25.296 Registry: Opened registry key "SOFTWARE\Microsoft\Windows\CurrentVersion"
04/28/2007 03:00:25.296 Registry: Read registry key value "ProgramFilesDir", string value = C:\Program Files
04/28/2007 03:00:25.296 Product discovery completed during the install process for SQLExpress
04/28/2007 03:00:25.296 SP Level check completed during the install process for SQLExpress
04/28/2007 03:00:25.296 Product language check completed during the install process for SQLExpress
04/28/2007 03:00:25.296 Product version check completed during the install process for SQLExpress
04/28/2007 03:00:25.296 Command-line instance name check completed during the install process
04/28/2007 03:00:25.296 SKU check completed during the install process for SQLEXPRESS
04/28/2007 03:00:25.296 SKU check completed during the install process for SQLExpress
04/28/2007 03:00:25.296 Baseline build check completed during the installation process for SQLEXPRESS
04/28/2007 03:00:25.296 Baseline build check completed during the installation process for SQLExpress
04/28/2007 03:00:25.296 Baseline build check completed during the install process
04/28/2007 03:00:25.312 Product Enumeration Results:
04/28/2007 03:00:25.312 INF File Name: c:\3b642267874f8d43d14991c2\HotFixExpress.inf
04/28/2007 03:00:25.312 baselinebuild = 1399
04/28/2007 03:00:25.328 build = 3042
04/28/2007 03:00:25.328 description = Express Database Services
04/28/2007 03:00:25.328 details = Service Pack for the SQL Server database engine, and the tools for managing relational and XML data, Replication, and Full-Text Search.
04/28/2007 03:00:25.328 installerlogpath = <PROGRAMFILESDIR>\Microsoft SQL Server\90\Setup Bootstrap\LOG\Hotfix
04/28/2007 03:00:25.328 kbarticle = KB921896
04/28/2007 03:00:25.328 kbarticlehyperlink = http://support.microsoft.com/?kbid=921896
04/28/2007 03:00:25.328 lcid = 1033
04/28/2007 03:00:25.328 legalproductname = SQL Server Express Database Services 2005
04/28/2007 03:00:25.328 machinetype = x86
04/28/2007 03:00:25.328 package = HotFixExpress
04/28/2007 03:00:25.328 packagetype = SP
04/28/2007 03:00:25.328 productname = SQL9Express
04/28/2007 03:00:25.328 relatedlinks = <LCIDSUPPORTDIR>\FinalSQL2005Information.rtf
04/28/2007 03:00:25.328 servicepackname = Microsoft SQL Server 2005 Service Pack 2 Setup
04/28/2007 03:00:25.328 sku = EXPRESS
04/28/2007 03:00:25.328 splevel = 2
04/28/2007 03:00:25.328 sqlutility = sqlcmd.exe
04/28/2007 03:00:25.328 supportdir = c:\3b642267874f8d43d14991c2
04/28/2007 03:00:25.328 validateauthentication = true
04/28/2007 03:00:25.328 version = 9
04/28/2007 03:00:25.328
04/28/2007 03:00:25.328 File Group Details: EXE
04/28/2007 03:00:25.328 parameters = INSTANCENAME=<NAME>
04/28/2007 03:00:25.328 sourcepath = <SUPPORTDIR>\<PACKAGE>\Files
04/28/2007 03:00:25.328 File Details: SQLEXPR.EXE
04/28/2007 03:00:25.328
04/28/2007 03:00:25.328 Instance Details: SQLEXPRESS
04/28/2007 03:00:25.328 clustername =
04/28/2007 03:00:25.328 features = SQL_Data_Files,SQL_Engine,SQL_Replication,SQL_SharedTools
04/28/2007 03:00:25.328 fullversion = 2005.090.1399.00
04/28/2007 03:00:25.328 hiveregpath = Software\Microsoft\Microsoft SQL Server\MSSQL.1
04/28/2007 03:00:25.328 id = MSSQL.1
04/28/2007 03:00:25.328 installsqldatadir = c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL
04/28/2007 03:00:25.328 installsqldir = c:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL
04/28/2007 03:00:25.328 lcid = 1033
04/28/2007 03:00:25.328 name = SQLEXPRESS
04/28/2007 03:00:25.328 productcode = {2AFFFDD7-ED85-4A90-8C52-5DA9EBDC9B8F}
04/28/2007 03:00:25.328 qfelevel = 1399
04/28/2007 03:00:25.328 servicename = MSSQL$SQLEXPRESS
04/28/2007 03:00:25.328 sku = EXPRESS
04/28/2007 03:00:25.328 sp = 0
04/28/2007 03:00:25.328 type = SQL Server Standalone Product
04/28/2007 03:00:25.328 vermajbld = 1399
04/28/2007 03:00:25.328 version = 9
04/28/2007 03:00:25.328
04/28/2007 03:00:25.328 Instance Details: SQLExpress
04/28/2007 03:00:25.328 clustername =
04/28/2007 03:00:25.328 expressrsstandalone = true
04/28/2007 03:00:25.328 features = Client_Components,Connectivity,SDK
04/28/2007 03:00:25.328 hiveregpath = Software\Microsoft\Microsoft SQL Server\90\Tools
04/28/2007 03:00:25.328 id =
04/28/2007 03:00:25.328 installsqldatadir =
04/28/2007 03:00:25.328 installsqldir = c:\Program Files\Microsoft SQL Server\90\Tools\
04/28/2007 03:00:25.343 lcid = 1033
04/28/2007 03:00:25.343 name =
04/28/2007 03:00:25.343 productcode = {2750B389-A2D2-4953-99CA-27C1F2A8E6FD}
04/28/2007 03:00:25.343 servicename = MSSQL$
04/28/2007 03:00:25.343 sku = EXPRESS
04/28/2007 03:00:25.343 sp = 0
04/28/2007 03:00:25.343 type = Tools Only
04/28/2007 03:00:25.343 vermajbld = 1399
04/28/2007 03:00:25.343 version = 9
04/28/2007 03:00:25.343
04/28/2007 03:00:25.375 Authenticating user using Windows Authentication
04/28/2007 03:00:25.375 SQL Service MSSQL$SQLEXPRESS was previously running, ready for authentication
04/28/2007 03:00:27.640 Registry: Opened registry key "System\CurrentControlSet\Control\Session Manager"
04/28/2007 03:00:27.640 Registry: Cannot read registry key value "PendingFileRenameOperations"
04/28/2007 03:00:27.640 Locked file: Checking for locked files
04/28/2007 03:00:27.640 Attempting to pause the 32 bit ngen queue
04/28/2007 03:00:28.390 Installing product: SQL9Express
04/28/2007 03:00:28.390 Installing instance: SQLEXPRESS
04/28/2007 03:00:28.406 Installing target: MyPcName
04/28/2007 03:00:28.437 Validating database connections using Windows Authentication
04/28/2007 03:00:28.578 Pre-script database connection check was successful - proceeding with script execution
04/28/2007 03:00:29.687 Received list of RANU pid's
04/28/2007 03:00:29.687 Validating database connections using Windows Authentication
04/28/2007 03:00:29.828 Pre-script database connection check was successful - proceeding with script execution
04/28/2007 03:00:29.843 Stopping service: MSSQL$SQLEXPRESS
04/28/2007 03:00:35.875 Stopped service: MSSQL$SQLEXPRESS
04/28/2007 03:00:35.890 Installing file: SQLEXPR.EXE
04/28/2007 03:00:35.890 Copy Engine: Creating MSI install log file at: C:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\LOG\Hotfix\SQL9Express_Hotfix_KB921896_SQLEXPR.EXE
04/28/2007 03:00:35.890 Registry: Cannot open registry key "Software\Policies\Microsoft\Windows\Installer"
04/28/2007 03:01:00.984 EXE returned 70095: *** Shared String ID 200095 Not Found ***
04/28/2007 03:01:00.984 Registry: Cannot open registry key "Software\Policies\Microsoft\Windows\Installer"
04/28/2007 03:01:01.031 Copy Engine: Error, unable to install EXE file: c:\3b642267874f8d43d14991c2\HotFixExpress\Files\SQLEXPR.EXE
04/28/2007 03:01:01.062 The following exception occurred: Unable to install Windows Installer MSI file Date: 04/28/2007 03:01:01.062 File: \depot\sqlvault\stable\setupmainl1\setup\sqlse\sqlsedll\copyengine.cpp Line: 1653
04/28/2007 03:01:01.703 Watson: Param1 = Unknown
04/28/2007 03:01:01.703 Watson: Param2 = 0x111cf
04/28/2007 03:01:01.718 Watson: Param3 = Unknown
04/28/2007 03:01:01.718 Watson: Param4 = 0x111cf
04/28/2007 03:01:01.734 Watson: Param5 = copyengine.cpp@.1653
04/28/2007 03:01:01.765 Watson: Param6 = Unknown
04/28/2007 03:01:01.765 Watson: Param7 = SQL9Express
04/28/2007 03:01:01.765 Watson: Param8 = @.
04/28/2007 03:01:01.781 Watson: Param9 = x86
04/28/2007 03:01:01.796 Watson: Param10 = 3042
04/28/2007 03:01:01.812 Installed product: SQL9Express
04/28/2007 03:01:01.828 Installing product: SQL9Express
04/28/2007 03:01:01.828 Installing instance: SQLExpress
04/28/2007 03:01:01.843 Installing target: MyPcName
04/28/2007 03:01:01.843 Installing file: SQLEXPR.EXE
04/28/2007 03:01:01.875 Copy Engine: Creating MSI install log file at: C:\Program Files\Microsoft SQL Server\90\Setup Bootstrap\LOG\Hotfix\SQL9Express_Hotfix_KB921896_SQLEXPR.EXE
04/28/2007 03:01:01.875 Registry: Cannot open registry key "Software\Policies\Microsoft\Windows\Installer"
04/28/2007 03:01:26.281 EXE returned 70095: *** Shared String ID 200095 Not Found ***
04/28/2007 03:01:26.312 Registry: Cannot open registry key "Software\Policies\Microsoft\Windows\Installer"
04/28/2007 03:01:26.328 Copy Engine: Error, unable to install EXE file: c:\3b642267874f8d43d14991c2\HotFixExpress\Files\SQLEXPR.EXE
04/28/2007 03:01:26.359 The following exception occurred: Unable to install Windows Installer MSI file Date: 04/28/2007 03:01:26.359 File: \depot\sqlvault\stable\setupmainl1\setup\sqlse\sqlsedll\copyengine.cpp Line: 1653
04/28/2007 03:01:26.968 Watson: Param1 = Unknown
04/28/2007 03:01:26.968 Watson: Param2 = 0x111cf
04/28/2007 03:01:26.968 Watson: Param3 = Unknown
04/28/2007 03:01:26.968 Watson: Param4 = 0x111cf
04/28/2007 03:01:26.984 Watson: Param5 = copyengine.cpp@.1653
04/28/2007 03:01:26.984 Watson: Param6 = Unknown
04/28/2007 03:01:26.984 Watson: Param7 = SQL9Express
04/28/2007 03:01:26.984 Watson: Param8 = @.
04/28/2007 03:01:26.984 Watson: Param9 = x86
04/28/2007 03:01:26.984 Watson: Param10 = 3042
04/28/2007 03:01:26.984 Installed product: SQL9Express
04/28/2007 03:01:26.984 Hotfix package completed
04/28/2007 03:01:27.000 Attempting to continue the 32 bit ngen queue

Hope this is the info you needed ?

|||

I had this problem

i backed up all my databases, uninstalled the whole sha-bang and started over. worked like a charm second time around. (this time my sql express is on the default instance also, the only thing different i can think of)

Saturday, February 25, 2012

Cannot install report server DB

Hi All,
I have installed VS.Net 2003, SQL Server 2000 with SQL Server 2000 sp3,
enabled Internet Information services, Frontpage server extensions.
However the Report Server database does not appear on my local server.
Is there something I am missing?
Thanks
SanjeevSQL Reporting Services has it's own seperate install. You need to aquire it
and run it on your server and on the client you wish to use the report
designer from in order to begin.
Peace,
Dan
"Sanjeev" <sanjeev@.microsoft.com> wrote in message
news:ON6nskJfFHA.3436@.tk2msftngp13.phx.gbl...
> Hi All,
> I have installed VS.Net 2003, SQL Server 2000 with SQL Server 2000 sp3,
> enabled Internet Information services, Frontpage server extensions.
> However the Report Server database does not appear on my local server.
> Is there something I am missing?
> Thanks
> Sanjeev
>|||Thanks Dan. I will try this.
"Dan Christjohn" <dchristjohn(removethis)@.directapps.com> wrote in message
news:OvNw$yMfFHA.2444@.tk2msftngp13.phx.gbl...
> SQL Reporting Services has it's own seperate install. You need to aquire
> it and run it on your server and on the client you wish to use the report
> designer from in order to begin.
> Peace,
> Dan
> "Sanjeev" <sanjeev@.microsoft.com> wrote in message
> news:ON6nskJfFHA.3436@.tk2msftngp13.phx.gbl...
>> Hi All,
>> I have installed VS.Net 2003, SQL Server 2000 with SQL Server 2000 sp3,
>> enabled Internet Information services, Frontpage server extensions.
>> However the Report Server database does not appear on my local server.
>> Is there something I am missing?
>> Thanks
>> Sanjeev
>

Thursday, February 16, 2012

Cannot get CREATE LOGIN from a Windows group to work

I have created a database fronted by an ASP.Net application. It's all nice and simple, and I only need a very simple level of security (and even that is only as a protection against accidents rather than maliciousness). My intention is that users connect using Windows impersonation (<identity="true">), with the database creator having full access and the public group (I'm talking SQL groups here) having specific premissions granted on specific tables.

If I set <identity="false"> on my XP box the application connects to the database as [MACHINE\ASPNET]. This is easy to set up access for - I simply do a

CREATE LOGIN [MACHINE\ASPNET] FROM WINDOWS

and then within the actual database do a

CREATE USER [MACHINE\ASPNET]

But as I said, I want to use Windows impersonation. When I set <identity="true">, the application correctly attempts to connect as the actual Windows user account (e.g. [MACHINE\testuser]). If that user is the user who installed the database, then all is well and it has full access. For anything else, I get a "cannot log on" error - this much I expect.

So I want to permit logins for all other users, and I want this to work regardless of whether the machine is a standalone machine whose "domain" is simply the machine's own name, whether it is in some form of traditional peer-to-peer workgroup, or whether the machine is connected to a real domain. I also want it to work on XP and Windows Server 2003 (and ideally Vista also, but that can wait). When I try the following:

CREATE LOGIN [MACHINE\Users] FROM WINDOWS

I get this error:

Msg 15401, Level 16, State 1, Server MACHINE\SQLEXPRESS, Line 1
Windows NT user or group 'MACHINE\Users' not found. Check the name again.

Nor does it work with [Everyone] (that one has no domain/folder listed against it in any permissions dialogs on my domainless development PC). So I'm stuck and confused. It's taken me ages just to get this far. Any suggestions anyone?

Thanks in advance.

Hi,

Ensure your windows users have grant access for that db.

Refer for adding windows user/group to sql server for work around.

http://msdn2.microsoft.com/en-gb/library/aa905177(sql.80).aspx

http://msdn2.microsoft.com/en-us/library/aa163753(office.10).aspx

http://www.databasedesign-resource.com/adding-users-in-sql-server.html

Hemantgiri S. Goswami

|||

Thanks, but that doesn't really help. One of these articles simply explains how to create Windows accounts, one explains how to use the sp_grantlogin storproc (which essentially issues the same SQL commands as I have listed above, and it gives exactly the same error messages), and the third tells you how to do it all manually, whereas I need to do it programmatically.

I should add that when I try to add a specific user account rather than the group account, the command works fine, so something is wrong with the attempt to add the group account. Does anyone know anything specific to groups?

|||I have found the answer. The issue is local versus global groups. CREATE LOGIN [domain\group] FROM WINDOWS works fine (i.e. a global group), but if you try it with a local group such as MACHINE\Users it will fail every time - this is a security feature of SQL Server. Which means that this approach will only work in a domain environment and not in a workgroup or on a shared single machine. The alternative is to use a nice GUI tool to manually add logins and users to SQL Express, but since SQL Express does not come with nice tools like Enterprise Manager, I may have to write my own and include it in the distribution. The group 'Everyone' fails also because it's what I would term a pseudo-group rather than either a local or a glocal group.|||

hi,

michael412 wrote:

I have found the answer. The issue is local versus global groups. CREATE LOGIN [domain\group] FROM WINDOWS works fine (i.e. a global group), but if you try it with a local group such as MACHINE\Users it will fail every time - this is a security feature of SQL Server. Which means that this approach will only work in a domain environment and not in a workgroup or on a shared single machine. The alternative is to use a nice GUI tool to manually add logins and users to SQL Express, but since SQL Express does not come with nice tools like Enterprise Manager, I may have to write my own and include it in the distribution. The group 'Everyone' fails also because it's what I would term a pseudo-group rather than either a local or a glocal group.

you can try defining your own local Windows group...
add a new Group via the "Computer Management" MMC snap-in, say you name it "MyMachineAllowedAccounts" and add the required windows accounts as members to that group...

then use the "nice ui tool" SQLExpress is provided with (yes, SQLEpress provides an official one ) and execute a standard
CREATE LOGIN [MACHINE_NAME\MyMachineAllowedAccounts] FROM WINDOWS;
and it will succed as expected..

regards

|||

The plot thickens. If I define a group MyGroup myself, then I can do CREATE LOGIN [MACHINE\MyGroup] FROM WINDOWS and it works. If I try to use one of the predefined groups such as MACHINE\Users, it fails. I don't at this point know whether this rule is constrained to local groups or whether it applies to global groups also. The group I added this morning in the office was a global group that we had created (i.e. it wasn't a predefined one), whereas the group that I failed to add was a predefined local group. I concluded that the important difference was whether the group was local or global, but now I realise that it could have been purely down to whether the group was predefined or created after installation. I don't see why SQL Server would want to prevent the use of predefined groups, and I've seen no mention of the importance of this distinction in any of the documentation. Can anyone throw any light on this?

Also, what is this GUI tool that is supposedly provided? I've looked through all the directories that were installed with SQL EXPRESS and haven't found one.

|||

hi Michael,

michael412 wrote:

The plot thickens. If I define a group MyGroup myself, then I can do CREATE LOGIN [MACHINE\MyGroup] FROM WINDOWS and it works. If I try to use one of the predefined groups such as MACHINE\Users, it fails.

it's only a "syntactical" problem as "how" you reference your predefined group's names...

CREATE LOGIN [BUILTIN\Users] FROM WINDOWS;

I don't at this point know whether this rule is constrained to local groups or whether it applies to global groups also. The group I added this morning in the office was a global group that we had created (i.e. it wasn't a predefined one), whereas the group that I failed to add was a predefined local group. I concluded that the important difference was whether the group was local or global, but now I realise that it could have been purely down to whether the group was predefined or created after installation. I don't see why SQL Server would want to prevent the use of predefined groups, and I've seen no mention of the importance of this distinction in any of the documentation. Can anyone throw any light on this?

check your syntax

CREATE LOGIN [BUILTIN\Users] FROM WINDOWS;

Also, what is this GUI tool that is supposedly provided? I've looked through all the directories that were installed with SQL EXPRESS and haven't found one.

SQL Server Management Studio Express is not installed as part of the "client components" of the "standard" package and must be manually and separately downloaded and installed.. on the contrary, SQL Server Express with Advanced Services includes it and the tool can be selected to be installed as part of the installation process..

regards

|||

Thanks Andrea - I think that's me sorted out now. Sorry to take so long to reply - I got tired and took a couple of days break from the PC.

Best regards,

Michael

Sunday, February 12, 2012

Cannot find column errors

Greetings!

I have a project that has been in production for a couple years now. It's a v1.1 ASP.NET web farm hitting a SQL database. The last couple weeks, the website has been erroring out on various pages for about 1-2 hours at a time twice a week. While the error messages are occurring, I cannot reproduce the errors myself.


Here are some of the error messages I recieve:

Cannot find column [ColumnName][ColumnName]is neither a DataColumn nor a DataRelation for table RESULT.[ColumnName] (Thisis a wierd one. The error message returned is just a column name)No record foundColumn '[ColumnName]' does not belong to table RESULT.

I come to a dead end when I follow the Stack Trace to find a programmatic error. I'm able to hit the same page with all the same form fields at the error occured on and I cannot reproduce.

The only consistentcy in these errors is that they come all at once and they are database related.

Anyone have an issue like this before?

Are you saying you can't replicate the problem "later" or on the same webserver at the same time as other users are having the problem?

|||

I cannot replicate the problem at either time.

I have the error messages emailed to me as they occur with information about the error and a link with URL parameters to the page. During the last incident, I was hitting pages where the error just occured moments before.


Any help is greatly appreciated... even if it's another question.

josh

|||

You must use column name from the ASP.net, not from Database.

For example, in my database, the column is [Closed Num]. But asp.net create the name [Closed_Num] for me. When you use filter expression, use [Close_Num] no problem. If you use the column name in the database, you will get the similar error!

Hope it is helpful.

MSVSBoy

Friday, February 10, 2012

Cannot find stored procedure

I developed a ASP.net web application with a MSDE database backend on my laptop(vs.net 2003 XP Pro), then I transferred the website onto a server(Windows Server 2003) and generated a SQL Server 2000 database from the scripts I exported from MSDE(web administrator). The problem I am having is that it can't find any stored procedures. I keep getting errors when logging on, 'Could not find stored procedure "_myProc" '.
Any one with any clues what might be the problem?
Yes I have changed the connection strings.
Thanks in advance
PPerhaps the owner of the SP is not what you expect? I have not used web_administrator, but perhaps it does not prefix SPs scripted with dbo., and so the SPs are owned by a different user.|||My Error, SP is case sensitive and somehow during the transfer of the site and DB one letter in SP name was changed to upper case. Buggered if I know how.
Have a great weekend Doug
Thanks for the help
Pete