1

Topic: Access error at connection attempt of a file of a DB in the project

Kind time of days, children!
I try to connect a DB to the project. I connect through the Observer of servers:
To add connection - Data source - Files of DB MS a SQL Server, I specify a full path to a DB file (he suggests to select it from the drop down list), an error - "It is refused access".
Thus application is opened with the rights of the manager, and at a folder which stores a DB of any restrictions is not present in properties.
Prompt what to do?

2

Re: Access error at connection attempt of a file of a DB in the project

It is necessary to be connected not to a database FILE, and to the DATABASE SERVER. This file, judging by a way, is under control of your local MSSQL-server, here to it and be connected

3

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro, but the project ASP.NET after all should have direct access to a DB (to files), how to me then this condition to fulfill?

4

Re: Access error at connection attempt of a file of a DB in the project

Vlad __ i __ mir wrote:

should have

to whom should? From what you solved it?
If you want to use operation with DB files, without using the DB server MSSQLServer to you does not approach because it is the SERVER!

5

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro so it is good.
It turns out to store not mandatory DB files in a project folder, it is possible to provide to them access and through MSSQLServer.
Prompt please why it then to me produces  an error:
"At establishment of connection with a SQL Server there was an error connected to a network or with a certain copy. The server is not found or inaccessible. Be convinced that the instance name is specified correctly and that on a SQL Server remote connections are resolved. (provider: SQL Network Interfaces, error: 26 - an error at detection of the specified server or a copy)"

6

Re: Access error at connection attempt of a file of a DB in the project

Vlad __ i __ mir wrote:

It turns out to store not mandatory DB files in a project folder, it is possible to provide to them access and through MSSQLServer.

It is possible for a miscellaneous. As it is necessary to you?

7

Re: Access error at connection attempt of a file of a DB in the project

Vlad __ i __ mir wrote:

It turns out to store not mandatory DB files in a project folder, it is possible to provide to them access and through MSSQLServer.

It is possible to store, it is possible not to store
It is possible through, it is possible not through
That is total four variants (from the offered cases)

Vlad __ i __ mir wrote:

Prompt please why it then to me produces  an error:

you asked a question to a parallel branch, to you answered. That Mahlo, in the error report small letters explicitly enough paint the possible reasons. Thus you even did not show a line of connection, not to mention other particulars

8

Re: Access error at connection attempt of a file of a DB in the project

skyANA wrote:

it is passed...
It is possible for a miscellaneous. As it is necessary to you?

In general which as, but a problem with this error solved. It was necessary to connect the data through an observer of servers, then to download a packet "Linq to SQL", to create a class of the given type, and to transfer in opened an observer one of tables. Then VS itself creates
Connection adjustments, including a line of connection also registers them in file Web.config.
But here there is a problem that if I will transfer the project on other machine at me anything will not work.
Whether probably to make so, what I could control the given DB through a SQL Server, but thus given DB (files) were stored at me in the project?
Whether can ASP.NET a copy what do a DB and store it in the project?

9

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro, I am sorry, but I set this point in question here still before to me answered in the previous branch. So it turned out.

10

Re: Access error at connection attempt of a file of a DB in the project

Vlad __ i __ mir wrote:

to control the given DB through a SQL Server, but thus given DB (files) were stored at me in the project?

Is not present. And whether is mandatory to control through SQLServer? Than other DBMS, for example SQLite does not arrange? She allows to work with a local file.

11

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro wrote:

Is not present.

Well that is that did not carp at my answer - it is possible to use localdb but then to transfer the project on other machine it will be possible only on that where costs SQLExpress, on a hosting of it most likely will not be.
Still it is possible to use SQLCompact is a restricted transferable version of server MSSQL, but it is not supported and condemned by participants of the given community)

12

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro wrote:

it is passed...
No. And whether is mandatory to control through SQLServer? Than other DBMS, for example SQLite does not arrange? She allows to work with a local file.

If I use SQLite that will launch my DB in the project by other machine at an application launch?
If SQLite I will need to install on new machine SQLite and to connect to it files of the DB which are in the project?

13

Re: Access error at connection attempt of a file of a DB in the project

Vlad __ i __ mir;
And how you generally will launch the web application under ASP.NET by other machine?
It will be necessary IIS (Internet Information Services), it will be necessary to a SQL Server.
And to put them it will be necessary hands, or scripts. As well basis to tear.
To me here it is curious, why you with us consider it, instead of with the teacher?
You will show it to it, instead of us. Here also ask, where it will be necessary to install that there already is.

14

Re: Access error at connection attempt of a file of a DB in the project

Vlad __ i __ mir wrote:

that will launch my DB

And what means "to launch a DB"? The DB is an information warehouse. With the same success it is possible to speak about text file start.

Vlad __ i __ mir wrote:

If SQLite I will need to install on new machine SQLite and to connect to it files of the DB which are in the project?

is not present

15

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro wrote:

it is passed...
And what means "to launch a DB"? The DB is an information warehouse. With the same success it is possible to speak about text file start.
it is passed...
Is not present

Application will work from a DB without SQLite and a SQL Server?

16

Re: Access error at connection attempt of a file of a DB in the project

skyANA, I know that there will be there a SQL Server 2008, therefore am afraid that my DB made on a SQL Server 2017 there does not go

17

Re: Access error at connection attempt of a file of a DB in the project

Vlad __ i __ mir wrote:

Application will work from a DB without SQLite

it really so difficult - to open Wikipedia on SQLite and to read literally some first lines?

Vlad __ i __ mir wrote:

and a SQL Server?

Vlad __ i __ mir wrote:

my DB made on a SQL Server 2017

That at you there such heaped up, what it is impossible to transfer in SQLite and even in SQLServer2008?

18

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro;

wrote:

That at you there such heaped up, what it is impossible to transfer in SQLite and even in SQLServer2008?

Yes I do not say that it is impossible, simply thought that there is a method which would allow to transfer simply files of a DB without creating anew a DB on the new server. Well, also is still given with type Geography, I do not know as they myself move on other server.

19

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro;

wrote:

it is valid so difficult - to open Wikipedia on SQLite and to read literally some first lines?

I not up to the end understood the main phrase:

wrote:

the Word "built in" (embedded) means that SQLite does not use a paradigm a client - server, that is engine SQLite is not separately operating process with which the program interacts, and represents library with which the program is arranged, and the engine becomes a program component.

What program "is arranged" with library SQLite? That that is written by the user?
How it is arranged? In C# the library is connected?
Where there is a DB? In VS?

20

Re: Access error at connection attempt of a file of a DB in the project

Vlad __ i __ mir wrote:

What program "is arranged" with library SQLite? That that is written by the user?
How it is arranged? In C# the library is connected?

yes, yes

Vlad __ i __ mir wrote:

Where there is a DB? In VS?

in the end of article there is a link to the self-instruction manual where first of all forms by a DB, well and so generally, I think, is both plug-ins for VS and any visual managers

Vlad __ i __ mir wrote:

Well, also is still given with type Geography, I do not know as they myself move on other server.

and, well for it I will not prompt, did not work with them
Well besides,  it was necessary not from DB creation, and from hosting requirement analysis where application will be torn.

21

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro;
it is necessary to hand over operation for the second year, and you to it about SQLite, a hosting:-Q

22

Re: Access error at connection attempt of a file of a DB in the project

skyANA wrote:

  it is necessary to hand over operation for the second year, and you to it about SQLite:-Q

Well it though something does a hosting, it is necessary to encourage it:-Q
: you of that to me you-kaesh?))

23

Re: Access error at connection attempt of a file of a DB in the project

Shocker. Pro, thanks for clarification!