Showing posts with label network. Show all posts
Showing posts with label network. Show all posts

Thursday, March 29, 2012

Determine what User Account SQL Server is running under

(MS SQL 2000)
Is there a way to determine what network user account SQL Server is
installed and running under? More importantly, can I easily change it?
Thanks!
If you have permissions to the server have a look in Control Panel /
Services / MSSQLServer / Logon Tab
It can be easily changed but you do need to stop/start the services for it
to take effect
HTH. Ryan
"D. Shane Fowlkes" <shanefowlkes@.h-o-t-m-a-i-l.com> wrote in message
news:uLoxF9TEGHA.1508@.TK2MSFTNGP15.phx.gbl...
> (MS SQL 2000)
> Is there a way to determine what network user account SQL Server is
> installed and running under? More importantly, can I easily change it?
> Thanks!
>
|||Thanks! That was pretty easy.
"Ryan" <Ryan_Waight@.nospam.hotmail.com> wrote in message
news:%23zgi8AUEGHA.2724@.TK2MSFTNGP12.phx.gbl...
> If you have permissions to the server have a look in Control Panel /
> Services / MSSQLServer / Logon Tab
> It can be easily changed but you do need to stop/start the services for it
> to take effect
> --
> HTH. Ryan
>
> "D. Shane Fowlkes" <shanefowlkes@.h-o-t-m-a-i-l.com> wrote in message
> news:uLoxF9TEGHA.1508@.TK2MSFTNGP15.phx.gbl...
>
|||Hi,
The proper method to change the account is via the Enterprise Manager or you
have to grant the new account some additional permissions on the server. I do
not remember all of the permissions, but they include 'act as part of os',
'run as service', etc.
If the account is changed via the EM, all of the required permisions are
automatically granted.
hth
DeeJay Puar
MCDBA
"D. Shane Fowlkes" wrote:

> Thanks! That was pretty easy.
>
> "Ryan" <Ryan_Waight@.nospam.hotmail.com> wrote in message
> news:%23zgi8AUEGHA.2724@.TK2MSFTNGP12.phx.gbl...
>
>
|||Thanks again.
"DeeJay Puar" <DeeJayPuar@.discussions.microsoft.com> wrote in message
news:5881C956-4A72-4868-A3BC-1E3907C3667E@.microsoft.com...[vbcol=seagreen]
> Hi,
> The proper method to change the account is via the Enterprise Manager or
> you
> have to grant the new account some additional permissions on the server. I
> do
> not remember all of the permissions, but they include 'act as part of os',
> 'run as service', etc.
> If the account is changed via the EM, all of the required permisions are
> automatically granted.
> hth
> DeeJay Puar
> MCDBA
> "D. Shane Fowlkes" wrote:

Determine what User Account SQL Server is running under

(MS SQL 2000)
Is there a way to determine what network user account SQL Server is
installed and running under? More importantly, can I easily change it?
Thanks!If you have permissions to the server have a look in Control Panel /
Services / MSSQLServer / Logon Tab
It can be easily changed but you do need to stop/start the services for it
to take effect
HTH. Ryan
"D. Shane Fowlkes" <shanefowlkes@.h-o-t-m-a-i-l.com> wrote in message
news:uLoxF9TEGHA.1508@.TK2MSFTNGP15.phx.gbl...
> (MS SQL 2000)
> Is there a way to determine what network user account SQL Server is
> installed and running under? More importantly, can I easily change it?
> Thanks!
>|||Thanks! That was pretty easy.
"Ryan" <Ryan_Waight@.nospam.hotmail.com> wrote in message
news:%23zgi8AUEGHA.2724@.TK2MSFTNGP12.phx.gbl...
> If you have permissions to the server have a look in Control Panel /
> Services / MSSQLServer / Logon Tab
> It can be easily changed but you do need to stop/start the services for it
> to take effect
> --
> HTH. Ryan
>
> "D. Shane Fowlkes" <shanefowlkes@.h-o-t-m-a-i-l.com> wrote in message
> news:uLoxF9TEGHA.1508@.TK2MSFTNGP15.phx.gbl...
>|||Hi,
The proper method to change the account is via the Enterprise Manager or you
have to grant the new account some additional permissions on the server. I d
o
not remember all of the permissions, but they include 'act as part of os',
'run as service', etc.
If the account is changed via the EM, all of the required permisions are
automatically granted.
hth
DeeJay Puar
MCDBA
"D. Shane Fowlkes" wrote:

> Thanks! That was pretty easy.
>
> "Ryan" <Ryan_Waight@.nospam.hotmail.com> wrote in message
> news:%23zgi8AUEGHA.2724@.TK2MSFTNGP12.phx.gbl...
>
>|||Thanks again.
"DeeJay Puar" <DeeJayPuar@.discussions.microsoft.com> wrote in message
news:5881C956-4A72-4868-A3BC-1E3907C3667E@.microsoft.com...[vbcol=seagreen]
> Hi,
> The proper method to change the account is via the Enterprise Manager or
> you
> have to grant the new account some additional permissions on the server. I
> do
> not remember all of the permissions, but they include 'act as part of os',
> 'run as service', etc.
> If the account is changed via the EM, all of the required permisions are
> automatically granted.
> hth
> DeeJay Puar
> MCDBA
> "D. Shane Fowlkes" wrote:
>

Determine what User Account SQL Server is running under

(MS SQL 2000)
Is there a way to determine what network user account SQL Server is
installed and running under? More importantly, can I easily change it?
Thanks!If you have permissions to the server have a look in Control Panel /
Services / MSSQLServer / Logon Tab
It can be easily changed but you do need to stop/start the services for it
to take effect
--
HTH. Ryan
"D. Shane Fowlkes" <shanefowlkes@.h-o-t-m-a-i-l.com> wrote in message
news:uLoxF9TEGHA.1508@.TK2MSFTNGP15.phx.gbl...
> (MS SQL 2000)
> Is there a way to determine what network user account SQL Server is
> installed and running under? More importantly, can I easily change it?
> Thanks!
>|||Thanks! That was pretty easy.
"Ryan" <Ryan_Waight@.nospam.hotmail.com> wrote in message
news:%23zgi8AUEGHA.2724@.TK2MSFTNGP12.phx.gbl...
> If you have permissions to the server have a look in Control Panel /
> Services / MSSQLServer / Logon Tab
> It can be easily changed but you do need to stop/start the services for it
> to take effect
> --
> HTH. Ryan
>
> "D. Shane Fowlkes" <shanefowlkes@.h-o-t-m-a-i-l.com> wrote in message
> news:uLoxF9TEGHA.1508@.TK2MSFTNGP15.phx.gbl...
>> (MS SQL 2000)
>> Is there a way to determine what network user account SQL Server is
>> installed and running under? More importantly, can I easily change it?
>> Thanks!
>>
>|||Hi,
The proper method to change the account is via the Enterprise Manager or you
have to grant the new account some additional permissions on the server. I do
not remember all of the permissions, but they include 'act as part of os',
'run as service', etc.
If the account is changed via the EM, all of the required permisions are
automatically granted.
hth
DeeJay Puar
MCDBA
"D. Shane Fowlkes" wrote:
> Thanks! That was pretty easy.
>
> "Ryan" <Ryan_Waight@.nospam.hotmail.com> wrote in message
> news:%23zgi8AUEGHA.2724@.TK2MSFTNGP12.phx.gbl...
> > If you have permissions to the server have a look in Control Panel /
> > Services / MSSQLServer / Logon Tab
> >
> > It can be easily changed but you do need to stop/start the services for it
> > to take effect
> >
> > --
> > HTH. Ryan
> >
> >
> > "D. Shane Fowlkes" <shanefowlkes@.h-o-t-m-a-i-l.com> wrote in message
> > news:uLoxF9TEGHA.1508@.TK2MSFTNGP15.phx.gbl...
> >> (MS SQL 2000)
> >>
> >> Is there a way to determine what network user account SQL Server is
> >> installed and running under? More importantly, can I easily change it?
> >>
> >> Thanks!
> >>
> >>
> >
> >
>
>|||Thanks again.
"DeeJay Puar" <DeeJayPuar@.discussions.microsoft.com> wrote in message
news:5881C956-4A72-4868-A3BC-1E3907C3667E@.microsoft.com...
> Hi,
> The proper method to change the account is via the Enterprise Manager or
> you
> have to grant the new account some additional permissions on the server. I
> do
> not remember all of the permissions, but they include 'act as part of os',
> 'run as service', etc.
> If the account is changed via the EM, all of the required permisions are
> automatically granted.
> hth
> DeeJay Puar
> MCDBA
> "D. Shane Fowlkes" wrote:
>> Thanks! That was pretty easy.
>>
>> "Ryan" <Ryan_Waight@.nospam.hotmail.com> wrote in message
>> news:%23zgi8AUEGHA.2724@.TK2MSFTNGP12.phx.gbl...
>> > If you have permissions to the server have a look in Control Panel /
>> > Services / MSSQLServer / Logon Tab
>> >
>> > It can be easily changed but you do need to stop/start the services for
>> > it
>> > to take effect
>> >
>> > --
>> > HTH. Ryan
>> >
>> >
>> > "D. Shane Fowlkes" <shanefowlkes@.h-o-t-m-a-i-l.com> wrote in message
>> > news:uLoxF9TEGHA.1508@.TK2MSFTNGP15.phx.gbl...
>> >> (MS SQL 2000)
>> >>
>> >> Is there a way to determine what network user account SQL Server is
>> >> installed and running under? More importantly, can I easily change
>> >> it?
>> >>
>> >> Thanks!
>> >>
>> >>
>> >
>> >
>>

Thursday, March 22, 2012

Detecting the network UserID

Hey guys,
I would like to determine the network id of the current user so that I can
pass that value to a stored procedure that the report references.
I tried add the following code in the Code tab of the Report Properties tab:
Function GetUserID() AS String
Return System.Environment.UserName
End Function
I then referenced this function as the default value for the @.vcUserId
argument that the stored procedure wants by assigning =Code.GetUserID() as
the Non-queried default value for the report parameter.
This approach works well when I preview the report in Visual Studio.
Unfortunately, it fails when I deploy the report to the server.
Can anyone offer some suggestions on how to approach this issue?
Thanks in advance,
-JimI'd guess that the reason this doesn't work is because when you run it
in VS.net the application is running as you or some other acceptable
local user
(http://msdn2.microsoft.com/en-us/library/system.environment.username.aspx).
When it runs online it probably can't execute or it returns the
ASP.NET worker process's user or something similar and not useful. I
know for ASP.NET you can call HttpContext.User.Idenity.Name (or
something similar, I'm working from memory mostly) to see who the
logged in user is, this might work better in report services. Or there
might be a separate way to get the current user from the report manager
that I'm not aware of.|||Use the global variable User!UserID.value
You can get to this with the expression builder. It returns domain\username,
if you don't want the domain then you will need to strip it off.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Terence Tirella" <ttirella@.literate.com> wrote in message
news:1141851303.988200.237700@.u72g2000cwu.googlegroups.com...
> I'd guess that the reason this doesn't work is because when you run it
> in VS.net the application is running as you or some other acceptable
> local user
> (http://msdn2.microsoft.com/en-us/library/system.environment.username.aspx).
> When it runs online it probably can't execute or it returns the
> ASP.NET worker process's user or something similar and not useful. I
> know for ASP.NET you can call HttpContext.User.Idenity.Name (or
> something similar, I'm working from memory mostly) to see who the
> logged in user is, this might work better in report services. Or there
> might be a separate way to get the current user from the report manager
> that I'm not aware of.
>sql

Detecting SQL Servers on a network

I need to show a list of detected SQL Server 2000 instances installed on a L
AN. I would like to know if anyone knows how to list the servers, similar t
o what Enterprise Manager does with its Server Registration Wizard.
ThanksHi,
From command prompt execute,
ISQL -L
Thanks
Hari
MCDBA
"Mike" <anonymous@.discussions.microsoft.com> wrote in message
news:983A2E30-10E0-4E3A-BF35-AD0DA6FC7E7A@.microsoft.com...
> I need to show a list of detected SQL Server 2000 instances installed on a
LAN. I would like to know if anyone knows how to list the servers, similar
to what Enterprise Manager does with its Server Registration Wizard.
> Thanks|||Thanks,
Do you have a method that can be done programmatically, rather than from the
command prompt? I need to build this capability into an application for our
developers.
Mike|||SQLDMO
>--Original Message--
>Thanks,
>Do you have a method that can be done programmatically,
rather than from the command prompt? I need to build this
capability into an application for our developers.
>Mike
>.
>|||I believe Enterprise Manager uses the SQLBrowseConnect ODBC function to
enumerate the SQL Servers on a network.
Rand
This posting is provided "as is" with no warranties and confers no rights.|||Hi Mike
It would help a great deal if you can supply me with the programming
language that you want this done in.
Regards
Wimpie
"Mike" <anonymous@.discussions.microsoft.com> wrote in message
news:983A2E30-10E0-4E3A-BF35-AD0DA6FC7E7A@.microsoft.com...
> I need to show a list of detected SQL Server 2000 instances installed on a
LAN. I would like to know if anyone knows how to list the servers, similar
to what Enterprise Manager does with its Server Registration Wizard.
> Thanks|||Me again...
I include the source of one of my VB .Net projects that does this. The is
no need to include any SQL objects in the project since the software
emulates the SQLDMO object in broadcasting a request for identification on
the network.
Hope it helps
Wimpie
----
---
Public Structure ServerInfo
Friend ServerName As String
Friend InstanceName As String
Friend IsClustered As Boolean
Friend Version As String
Friend TCPPort As Long
Friend IPAddress As String
End Structure
Public Sub Start()
Dim objSQLServers() As ServerInfo = EnumSQLServer()
End Sub
Friend Function EnumSQLServer() As ServerInfo()
Dim objUDPClient As New System.Net.Sockets.UdpClient
Dim objRemoteIP As System.Net.IPEndPoint
Dim objAllServers() As ServerInfo
Dim bytData() As Byte = {2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0}
Dim bytReceived() As Byte
Dim strInfo() As String
Dim strHostHeaders() As String
Dim booDone As Boolean = False
Dim i As Long
Dim x As Int16
ReDim strHostHeaders(0)
objUDPClient.Send(bytData, 18, "255.255.255.255", "1434")
While booDone = False
Try
bytReceived = objUDPClient.Receive(objRemoteIP)
Catch
booDone = True
Exit While
End Try
If strHostHeaders(strHostHeaders.Length - 1) <> "" Then
ReDim Preserve strHostHeaders(strHostHeaders.Length)
End If
strHostHeaders(strHostHeaders.Length - 1) =
Mid(System.Text.ASCIIEncoding.ASCII.GetString(bytReceived), 4)
strHostHeaders(strHostHeaders.Length - 1) &= ";IPADDRESS;" &
objRemoteIP.Serialize.Item(4).ToString & "." &
objRemoteIP.Serialize.Item(5).ToString & "." &
objRemoteIP.Serialize.Item(6).ToString & "." &
objRemoteIP.Serialize.Item(7).ToString
If strHostHeaders.Length > 1 Then
If strHostHeaders(strHostHeaders.Length - 1) =
strHostHeaders(strHostHeaders.Length - 2) Then ReDim Preserve
strHostHeaders(strHostHeaders.Length - 2)
End If
End While
objUDPClient.Close()
objUDPClient = Nothing
ReDim objAllServers(strHostHeaders.Length - 1)
For i = 0 To strHostHeaders.Length - 1
strInfo = Split(strHostHeaders(i), ";")
For x = 0 To strInfo.Length - 1
Select Case LCase(strInfo(x))
Case "servername"
objAllServers(i).ServerName = strInfo(x + 1)
Case "instancename"
objAllServers(i).InstanceName = strInfo(x + 1)
Case "isclustered"
objAllServers(i).IsClustered = IIf(LCase(strInfo(x +
1)) = "no", False, True)
Case "version"
objAllServers(i).Version = strInfo(x + 1)
Case "tcp"
objAllServers(i).TCPPort = CLng(strInfo(x + 1))
Case "ipaddress"
objAllServers(i).IPAddress = strInfo(x + 1)
End Select
Next
Next
Return objAllServers
End Function

Wednesday, March 21, 2012

Detect servers on the network?

I'm wondering how to detect SQL servers on the network, the way Enterprise
Manager locates servers when it populates combo boxes or list boxes with
active servers on the network. Can anybody give me a hint? Some C# code
would be a plus. Thanks!
Hi,
Execute the below command from command prompt:-
ISQL -L
Thanks
Hari
SQL Server MVP
"William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
> I'm wondering how to detect SQL servers on the network, the way Enterprise
> Manager locates servers when it populates combo boxes or list boxes with
> active servers on the network. Can anybody give me a hint? Some C# code
> would be a plus. Thanks!
|||Sorry, I meant progmatically, not at the command line. The idea being that I
detect available servers on the network in order to populate a combo box with
their names. Thanks!
"Hari Prasad" wrote:

> Hi,
> Execute the below command from command prompt:-
> ISQL -L
>
> --
> Thanks
> Hari
> SQL Server MVP
>
>
> "William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
> message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
>
>
|||Try using COM interop and the SQLDMO ( SQL Server Distributed Management
Objects ).
Heres a sample in C#
http://www.csharphelp.com/archives2/archive342.html
"William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
> I'm wondering how to detect SQL servers on the network, the way Enterprise
> Manager locates servers when it populates combo boxes or list boxes with
> active servers on the network. Can anybody give me a hint? Some C# code
> would be a plus. Thanks!
|||Yes, quite. That's the ticket! Thanks much!
"Darren" wrote:

> Try using COM interop and the SQLDMO ( SQL Server Distributed Management
> Objects ).
> Heres a sample in C#
> http://www.csharphelp.com/archives2/archive342.html
>
> "William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
> message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
>
>
|||Hello,
I tried this. but i am getting the following error ' QueryInterface for
interface SQLDMO.NameList failed.' I have reference SQLDMO.dll file in my
project.
here is my code--
Dim sqlapp As SQLDMO.Application
sqlapp = New SQLDMO.ApplicationClass
Dim sqlservers As SQLDMO.NameList
sqlservers = sqlapp.ListAvailableSQLServers
Dim i As Integer
Dim srv As Object
For i = 0 To sqlservers.Count
srv = sqlservers.Item(i + 1)
cboServers.Items.Add(srv)
Next
Thanks,
"Darren" wrote:

> Try using COM interop and the SQLDMO ( SQL Server Distributed Management
> Objects ).
> Heres a sample in C#
> http://www.csharphelp.com/archives2/archive342.html
>
> "William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
> message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
>
>

Detect servers on the network?

I'm wondering how to detect SQL servers on the network, the way Enterprise
Manager locates servers when it populates combo boxes or list boxes with
active servers on the network. Can anybody give me a hint? Some C# code
would be a plus. Thanks!Hi,
Execute the below command from command prompt:-
ISQL -L
Thanks
Hari
SQL Server MVP
"William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
> I'm wondering how to detect SQL servers on the network, the way Enterprise
> Manager locates servers when it populates combo boxes or list boxes with
> active servers on the network. Can anybody give me a hint? Some C# code
> would be a plus. Thanks!|||Sorry, I meant progmatically, not at the command line. The idea being that
I
detect available servers on the network in order to populate a combo box wit
h
their names. Thanks!
"Hari Prasad" wrote:

> Hi,
> Execute the below command from command prompt:-
> ISQL -L
>
> --
> Thanks
> Hari
> SQL Server MVP
>
>
> "William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
> message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
>
>|||Try using COM interop and the SQLDMO ( SQL Server Distributed Management
Objects ).
Heres a sample in C#
http://www.csharphelp.com/archives2/archive342.html
"William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
> I'm wondering how to detect SQL servers on the network, the way Enterprise
> Manager locates servers when it populates combo boxes or list boxes with
> active servers on the network. Can anybody give me a hint? Some C# code
> would be a plus. Thanks!|||Yes, quite. That's the ticket! Thanks much!
"Darren" wrote:

> Try using COM interop and the SQLDMO ( SQL Server Distributed Management
> Objects ).
> Heres a sample in C#
> http://www.csharphelp.com/archives2/archive342.html
>
> "William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
> message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
>
>|||Hello,
I tried this. but i am getting the following error ' QueryInterface for
interface SQLDMO.NameList failed.' I have reference SQLDMO.dll file in my
project.
here is my code--
Dim sqlapp As SQLDMO.Application
sqlapp = New SQLDMO.ApplicationClass
Dim sqlservers As SQLDMO.NameList
sqlservers = sqlapp.ListAvailableSQLServers
Dim i As Integer
Dim srv As Object
For i = 0 To sqlservers.Count
srv = sqlservers.Item(i + 1)
cboServers.Items.Add(srv)
Next
Thanks,
"Darren" wrote:

> Try using COM interop and the SQLDMO ( SQL Server Distributed Management
> Objects ).
> Heres a sample in C#
> http://www.csharphelp.com/archives2/archive342.html
>
> "William Sullivan" <WilliamSullivan@.discussions.microsoft.com> wrote in
> message news:570D002D-3661-4E08-9F22-DC8B62DE2CBE@.microsoft.com...
>
>

Friday, March 9, 2012

Detach replicated DB?

Trying to detach a DB from the publisher/distributer via EM from another PC
on the network. The detach box has the message: ATTENTION: The database
cannot be detached while it is being replicated. And the OK button is
disabled. I took this as you cannot detach during replication. But it is
not being replicated now. Does this mean a DB set up as a publisher can't be
detached at all?
Thanks,
Steve
After reading further, it appears that I can't do this. So I have deleted
the publications. But I still get the ATTENTION message and can't detach.
"SteveInBeloit" wrote:

> Trying to detach a DB from the publisher/distributer via EM from another PC
> on the network. The detach box has the message: ATTENTION: The database
> cannot be detached while it is being replicated. And the OK button is
> disabled. I took this as you cannot detach during replication. But it is
> not being replicated now. Does this mean a DB set up as a publisher can't be
> detached at all?
> Thanks,
> Steve
|||From another post I read,
You will be unable to detach replicated databases. You have to script out
the publications, edit them for the new server, remove all job names, and
then drop the publications, unpublish the databases and detach them.
I have deleted the publications, but what is mean't by unpublish the database?
"SteveInBeloit" wrote:
[vbcol=seagreen]
> After reading further, it appears that I can't do this. So I have deleted
> the publications. But I still get the ATTENTION message and can't detach.
> "SteveInBeloit" wrote:
|||In EM, connect with your SQL Server, select Tools, Replication, Configure
Distributor, Publishers and subscribers, Click on the Published databases
tab, and uncheck the check marks for transactional or merge if the database
is published.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"SteveInBeloit" <SteveInBeloit@.discussions.microsoft.com> wrote in message
news:182E9763-9D45-4EB7-8C60-AB9F7F4F7ABD@.microsoft.com...
> From another post I read,
> You will be unable to detach replicated databases. You have to script out
> the publications, edit them for the new server, remove all job names, and
> then drop the publications, unpublish the databases and detach them.
> I have deleted the publications, but what is mean't by unpublish the
database?[vbcol=seagreen]
>
> "SteveInBeloit" wrote:
deleted[vbcol=seagreen]
detach.[vbcol=seagreen]
another PC[vbcol=seagreen]
database[vbcol=seagreen]
it is[vbcol=seagreen]
can't be[vbcol=seagreen]
|||Thank you!
"Hilary Cotter" wrote:

> In EM, connect with your SQL Server, select Tools, Replication, Configure
> Distributor, Publishers and subscribers, Click on the Published databases
> tab, and uncheck the check marks for transactional or merge if the database
> is published.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "SteveInBeloit" <SteveInBeloit@.discussions.microsoft.com> wrote in message
> news:182E9763-9D45-4EB7-8C60-AB9F7F4F7ABD@.microsoft.com...
> database?
> deleted
> detach.
> another PC
> database
> it is
> can't be
>
>
|||Hilary,
If you delete the publisher and the subscriber to detach the published
database, how do you reinstae the publisher and the subscriber? I hope I do
not have to do the replication all over from the beginning.
Thanks,
George Gopie
"Hilary Cotter" wrote:

> In EM, connect with your SQL Server, select Tools, Replication, Configure
> Distributor, Publishers and subscribers, Click on the Published databases
> tab, and uncheck the check marks for transactional or merge if the database
> is published.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "SteveInBeloit" <SteveInBeloit@.discussions.microsoft.com> wrote in message
> news:182E9763-9D45-4EB7-8C60-AB9F7F4F7ABD@.microsoft.com...
> database?
> deleted
> detach.
> another PC
> database
> it is
> can't be
>
>

Tuesday, February 14, 2012

Design Help – Access SQL Database behind a firewall from ASP .NET pages.

Hi,

I am new to internet development and would like some advice on the technology used to access a SQL database that sits on a network behind a firewall.

** ASP .NET Page ** -> ** Web Server ** -> ** FIREWALL ** -> ** SQL **

So to give an example; from an ASP .NET page on the internet, I would like to populate a DataGrid with the contents of a single table from a SQL database. The SQL database is sitting on our company network behind a firewall.

Could someone please explain / point me in the right direction in how the ASP .NET page / Web Server can securely access the SQL database.

Thanking you in advance
ScottThe firewall needs to allow SQL access between the WebServer and the SQL server. This is usually port 1433. Only requests initiated by the webservers IP should be allowed to get to the db server.

You could also put together some web services on SQL server to send back datasets through the firewall (assuming its running iis and the .net framework).

Then you would just need to open port 80 between the webserver and the sql server. The webservices we run on our db server required an encrypted key as part of all method calls to insure that only we can run them.

No matter which way you do it, your opening a hole in your firewall for communication to occurr between the two boxes.|||Mbanavige – thanks for your reply. Can I confirm my understanding??

Option 1.
The firewall opens port 1433 with an additional rule to only allow the IP address of the web server to communicate on port 1433. As such this allows web server code to create a connection string to SQL? How would I fully qualifying the connection string server property - <SQL Server NetBIOS Name><domain>??

Option 2.
Have a second web server (internal) running on the same box as the SQL server. The internal web server will host web services, which can be called from the external web server. This requires the opening of port 80. Further security is added with the use of an encrypted key required for all method calls. How is the encrypted key implemented?

Is there an industry preferred solution?

Is option 2 more secure against SQL attacks since SQL access is further controlled through the use of web services?

Thanking you again in advance for your replies.
Scott

Design a Database for Daily News Network website

Hello..

I want to upgrade my website to asp.net 2.0 and I want to add a Daily news to website.
and 10 to 15 news will be added daily , so after a year we have almost 4000 entry in the database.

For designing this DB what is your advice on how to store news in database?
Is it better to create same tables for each year ? for example
tblNews_2005
tblNews_2006

Or just to make one table and have all news stored in that ? its gonna be huge after years , isnt that make any problems?

Thanks
Regards.

Nah, just use a simple table... SQL server is highly optimized for large tables. I suppose, however, that you will have a primary key there. Moreover, you should add good indexes in the tableSmile

|||

Thanks, I wonder , how large the table could be ? I have an archive of 40,000 records until now and it will be bigger every year.. Regards|||

I've seen sql server responding with the speed of lightStick out tongue to one million recordsBig Smile

And I've seen it responding poorly in 5000 rows (somebody had forgotten to use indexes...)

It's all to good database design, my friend!Smile

|||

Thanks, so the size doesnt matter :D

The point is in a good design :)