Showing posts with label create. Show all posts
Showing posts with label create. Show all posts

Sunday, 25 March 2012

Connect To Oracle 10g 64 Bit using SQL Server Integration Services 2005 64 Bit

I am trying to create a oracle 10g connection in SSIS using connection manager and i am getting the following error,

Test Connection failed because of an error in initializing provider. Oracle client and networking

components were not found. These components are supplied by Oracle corporation and are part of the

Oracle version 7.3.3 or later client software installation.

Provider is unable to function until these components are installed.

Can someone please help.

Thanks.

If your operating System and VS2005 are 32bits then you need to download and install the Oracle 10g client for Windows 32bits, when I last downloaded it was more than 1gig install it and create your connection to the database make sure your TNS ORA works before adding SSIS connection to Oracle. The client tools are free but you need an Oracle Technet account which you can create for free. The Developer is also free it let you see Oracle tables and databases. If you are in an employer's network I find connecting with Named Pipes is easier than TCP/IP. One more thing watch the installer. Hope this helps.

http://www.oracle.com/technology/software/index.html

I forgot to add you must compile your code with AnyCPU.

|||

Thanks for your reply Caddre..

But.. i have MS 2003 64 bit OS.. i have installed oracle 10g 64 bit server.. i can successfully connect thru sqlplus.. no problem...

I am missing something on SQL 2005 and i am not sure what it is...

|||

So you are saying you have installed Oracle 10g 64bits client tools in the box? I know connecting through SQL plus does not solve development connection issue you need the client tools in your box this time 64bits. Another thing you are not missing anything but I think VS2005 unless you buy 64bits full version is 32bits that is not all your setup is 64bits, so you need to either make it all 64bits or develop in 32bits and deploy in 64bits because I read there are issues known issues.


|||

yes - as far as i know all are 64bit

I cannot connect thru both providers - OLEDB and Net Oracle client

|||

Try this recent Microsoft support article steps, I will still look for more info.

http://support.microsoft.com/kb/255084

|||

Hi Caddre,

Either you can have a look at summarized article here. or You may look for "Getting SSIS Packages To Run On A 64 Bit Box" in Sutha Thiru's Blog .

Thanks

Subhash Subramanyam

|||

thanks subash.. awesome..

those articles helped me to fix the issue...

appreciate yours and caddre help on this..

|||I am glad to see your problem is resolved and Subhash thanks for the articles much appreciated.

Tuesday, 20 March 2012

connect to a specific port on sql server/endpoint

i have created a new tcp endpoint using the following:
CREATE ENDPOINT [CustomConnection1]
STATE = STARTED
AS TCP
(LISTENER_PORT = 1444, LISTENER_IP =ALL)
FOR TSQL() ;
And I got warning about permissions being revoked for the default tcp
endpoint, but I was okay with that since I really wanted all users to go
through this new endpoint I am creating.
I then granted connect pemissions to a sql login (called test) to connect to
this endpoint.
I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
I tried connecting to the sql server with the test login & it gave me a
login failed error 18456.
i then granted connect permissions to public to the default tcp port & tried
conecting with the test user & it connected successfully. So obviously it was
connecting with the default tcp port & not the new port i defined as the
endpoint. to be sure, i stopped the new endpoint & connected with the test
login again & it still worked.
So my question is - what am i doing wrong? i dont connections to go through
the default tcp port , i want them to go through the port i define in the
endpoint.
also, how can i connect to a specific port through management studio?
just fyi - i basically followed the instructions on this link:
http://msdn2.microsoft.com/en-us/library/ms189310.aspx
thanks in advance!Did you specify this new port in the connection string/server name?
It seems you just want to change the port, and for that you don't need to create a new endpoint. You
would just change the port in Server Configuration program.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"adba" <adba@.discussions.microsoft.com> wrote in message
news:04055949-5892-425E-8593-541612857169@.microsoft.com...
>i have created a new tcp endpoint using the following:
> CREATE ENDPOINT [CustomConnection1]
> STATE = STARTED
> AS TCP
> (LISTENER_PORT = 1444, LISTENER_IP =ALL)
> FOR TSQL() ;
> And I got warning about permissions being revoked for the default tcp
> endpoint, but I was okay with that since I really wanted all users to go
> through this new endpoint I am creating.
> I then granted connect pemissions to a sql login (called test) to connect to
> this endpoint.
> I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
> I tried connecting to the sql server with the test login & it gave me a
> login failed error 18456.
> i then granted connect permissions to public to the default tcp port & tried
> conecting with the test user & it connected successfully. So obviously it was
> connecting with the default tcp port & not the new port i defined as the
> endpoint. to be sure, i stopped the new endpoint & connected with the test
> login again & it still worked.
> So my question is - what am i doing wrong? i dont connections to go through
> the default tcp port , i want them to go through the port i define in the
> endpoint.
> also, how can i connect to a specific port through management studio?
> just fyi - i basically followed the instructions on this link:
> http://msdn2.microsoft.com/en-us/library/ms189310.aspx
> thanks in advance!
>|||No, I havenâ't specified this new port in my servername â' how do I do that in
management studio? Lets assume my server name is sqltest & the new port
number is 1443 & the endpoint is called custom1. should the servername be
sqltest:1443 ?
What I want to do is create different tcp endpoints for different
applications. That way the default port 1433 would be used only by admins
internally & other users outside the firewall will connect through another
port (new endpoint) than 1433. That way if security is compromised with one
application, I donâ't have to shut the entire server down, I should be able to
shut down that specific port â' does this idea make sense' Iâ'm not having
much luck implementing itâ?¦.
"Tibor Karaszi" wrote:
> Did you specify this new port in the connection string/server name?
> It seems you just want to change the port, and for that you don't need to create a new endpoint. You
> would just change the port in Server Configuration program.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "adba" <adba@.discussions.microsoft.com> wrote in message
> news:04055949-5892-425E-8593-541612857169@.microsoft.com...
> >i have created a new tcp endpoint using the following:
> > CREATE ENDPOINT [CustomConnection1]
> > STATE = STARTED
> > AS TCP
> > (LISTENER_PORT = 1444, LISTENER_IP =ALL)
> > FOR TSQL() ;
> > And I got warning about permissions being revoked for the default tcp
> > endpoint, but I was okay with that since I really wanted all users to go
> > through this new endpoint I am creating.
> > I then granted connect pemissions to a sql login (called test) to connect to
> > this endpoint.
> > I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
> > I tried connecting to the sql server with the test login & it gave me a
> > login failed error 18456.
> > i then granted connect permissions to public to the default tcp port & tried
> > conecting with the test user & it connected successfully. So obviously it was
> > connecting with the default tcp port & not the new port i defined as the
> > endpoint. to be sure, i stopped the new endpoint & connected with the test
> > login again & it still worked.
> > So my question is - what am i doing wrong? i dont connections to go through
> > the default tcp port , i want them to go through the port i define in the
> > endpoint.
> > also, how can i connect to a specific port through management studio?
> >
> > just fyi - i basically followed the instructions on this link:
> > http://msdn2.microsoft.com/en-us/library/ms189310.aspx
> >
> > thanks in advance!
> >
> >
>|||I understand about your usage scenario. Yes, that makes sense to me.
To connect to so something else than the "default" port, the client uses below syntax for the server
name. Note that you don't specify an instance name if it is a named instance:
SERVERNAME,PORT#
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"adba" <adba@.discussions.microsoft.com> wrote in message
news:C84D70CE-AEC4-48F3-B56E-86C264C85858@.microsoft.com...
> No, I havenâ't specified this new port in my servername â' how do I do that in
> management studio? Lets assume my server name is sqltest & the new port
> number is 1443 & the endpoint is called custom1. should the servername be
> sqltest:1443 ?
> What I want to do is create different tcp endpoints for different
> applications. That way the default port 1433 would be used only by admins
> internally & other users outside the firewall will connect through another
> port (new endpoint) than 1433. That way if security is compromised with one
> application, I donâ't have to shut the entire server down, I should be able to
> shut down that specific port â' does this idea make sense' Iâ'm not having
> much luck implementing itâ?¦.
>
> "Tibor Karaszi" wrote:
>> Did you specify this new port in the connection string/server name?
>> It seems you just want to change the port, and for that you don't need to create a new endpoint.
>> You
>> would just change the port in Server Configuration program.
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://sqlblog.com/blogs/tibor_karaszi
>>
>> "adba" <adba@.discussions.microsoft.com> wrote in message
>> news:04055949-5892-425E-8593-541612857169@.microsoft.com...
>> >i have created a new tcp endpoint using the following:
>> > CREATE ENDPOINT [CustomConnection1]
>> > STATE = STARTED
>> > AS TCP
>> > (LISTENER_PORT = 1444, LISTENER_IP =ALL)
>> > FOR TSQL() ;
>> > And I got warning about permissions being revoked for the default tcp
>> > endpoint, but I was okay with that since I really wanted all users to go
>> > through this new endpoint I am creating.
>> > I then granted connect pemissions to a sql login (called test) to connect to
>> > this endpoint.
>> > I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
>> > I tried connecting to the sql server with the test login & it gave me a
>> > login failed error 18456.
>> > i then granted connect permissions to public to the default tcp port & tried
>> > conecting with the test user & it connected successfully. So obviously it was
>> > connecting with the default tcp port & not the new port i defined as the
>> > endpoint. to be sure, i stopped the new endpoint & connected with the test
>> > login again & it still worked.
>> > So my question is - what am i doing wrong? i dont connections to go through
>> > the default tcp port , i want them to go through the port i define in the
>> > endpoint.
>> > also, how can i connect to a specific port through management studio?
>> >
>> > just fyi - i basically followed the instructions on this link:
>> > http://msdn2.microsoft.com/en-us/library/ms189310.aspx
>> >
>> > thanks in advance!
>> >
>> >
>>|||thanks. okay now i wa able to connect to a specific port through management
studio.
but my problem is that to be able to connect to that port, i have to have
connect permissions granted to public on the default tcp port. like when you
create a new endpointm it takes away the permissions on the deafult port. so
i i leave it like that, i cannot connect to the new endpoint i created. if i
grant permissions to public, it kind of defeats the purpose of creating new
endpoints for me.
so i guess my question is can we connect to a new endpoint without granting
connect permissions to public on the default tcp port?
"Tibor Karaszi" wrote:
> I understand about your usage scenario. Yes, that makes sense to me.
> To connect to so something else than the "default" port, the client uses below syntax for the server
> name. Note that you don't specify an instance name if it is a named instance:
> SERVERNAME,PORT#
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "adba" <adba@.discussions.microsoft.com> wrote in message
> news:C84D70CE-AEC4-48F3-B56E-86C264C85858@.microsoft.com...
> > No, I havenâ't specified this new port in my servername â' how do I do that in
> > management studio? Lets assume my server name is sqltest & the new port
> > number is 1443 & the endpoint is called custom1. should the servername be
> > sqltest:1443 ?
> >
> > What I want to do is create different tcp endpoints for different
> > applications. That way the default port 1433 would be used only by admins
> > internally & other users outside the firewall will connect through another
> > port (new endpoint) than 1433. That way if security is compromised with one
> > application, I donâ't have to shut the entire server down, I should be able to
> > shut down that specific port â' does this idea make sense' Iâ'm not having
> > much luck implementing itâ?¦.
> >
> >
> >
> > "Tibor Karaszi" wrote:
> >
> >> Did you specify this new port in the connection string/server name?
> >>
> >> It seems you just want to change the port, and for that you don't need to create a new endpoint.
> >> You
> >> would just change the port in Server Configuration program.
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://sqlblog.com/blogs/tibor_karaszi
> >>
> >>
> >> "adba" <adba@.discussions.microsoft.com> wrote in message
> >> news:04055949-5892-425E-8593-541612857169@.microsoft.com...
> >> >i have created a new tcp endpoint using the following:
> >> > CREATE ENDPOINT [CustomConnection1]
> >> > STATE = STARTED
> >> > AS TCP
> >> > (LISTENER_PORT = 1444, LISTENER_IP =ALL)
> >> > FOR TSQL() ;
> >> > And I got warning about permissions being revoked for the default tcp
> >> > endpoint, but I was okay with that since I really wanted all users to go
> >> > through this new endpoint I am creating.
> >> > I then granted connect pemissions to a sql login (called test) to connect to
> >> > this endpoint.
> >> > I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
> >> > I tried connecting to the sql server with the test login & it gave me a
> >> > login failed error 18456.
> >> > i then granted connect permissions to public to the default tcp port & tried
> >> > conecting with the test user & it connected successfully. So obviously it was
> >> > connecting with the default tcp port & not the new port i defined as the
> >> > endpoint. to be sure, i stopped the new endpoint & connected with the test
> >> > login again & it still worked.
> >> > So my question is - what am i doing wrong? i dont connections to go through
> >> > the default tcp port , i want them to go through the port i define in the
> >> > endpoint.
> >> > also, how can i connect to a specific port through management studio?
> >> >
> >> > just fyi - i basically followed the instructions on this link:
> >> > http://msdn2.microsoft.com/en-us/library/ms189310.aspx
> >> >
> >> > thanks in advance!
> >> >
> >> >
> >>
> >>
>|||> but my problem is that to be able to connect to that port, i have to have
> connect permissions granted to public on the default tcp port.
That is not what I'm seeing. Below is what I did, and result of my actions. I'm on sp2, btw:
CREATE LOGIN adba WITH PASSWORD = 'pwd'
CREATE ENDPOINT [CustomConnection1]
STATE = STARTED
AS TCP
(LISTENER_PORT = 1444, LISTENER_IP =ALL)
FOR TSQL() ;
GRANT CONNECT ON ENDPOINT::[CustomConnection1] to [public]
GRANT CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]
-- Added port 1444 in Network Server Utility, IPAll, TCP Port: 1433,1444
-- Restarted SQL Server
REVOKE CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]
--Login adba able to login on port 1444
--Login adba not able to login with only server name specified
--Login adba not able to login on port 1433
--Windows login able to login on port 1433
--Windows login able to login with only server name specified
--(my Windows account is a login member of syadmin)
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"adba" <adba@.discussions.microsoft.com> wrote in message
news:9AF19309-A371-4983-B788-95E67789552C@.microsoft.com...
> thanks. okay now i wa able to connect to a specific port through management
> studio.
> but my problem is that to be able to connect to that port, i have to have
> connect permissions granted to public on the default tcp port. like when you
> create a new endpointm it takes away the permissions on the deafult port. so
> i i leave it like that, i cannot connect to the new endpoint i created. if i
> grant permissions to public, it kind of defeats the purpose of creating new
> endpoints for me.
> so i guess my question is can we connect to a new endpoint without granting
> connect permissions to public on the default tcp port?
> "Tibor Karaszi" wrote:
>> I understand about your usage scenario. Yes, that makes sense to me.
>> To connect to so something else than the "default" port, the client uses below syntax for the
>> server
>> name. Note that you don't specify an instance name if it is a named instance:
>> SERVERNAME,PORT#
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://sqlblog.com/blogs/tibor_karaszi
>>
>> "adba" <adba@.discussions.microsoft.com> wrote in message
>> news:C84D70CE-AEC4-48F3-B56E-86C264C85858@.microsoft.com...
>> > No, I havenâ't specified this new port in my servername â' how do I do that in
>> > management studio? Lets assume my server name is sqltest & the new port
>> > number is 1443 & the endpoint is called custom1. should the servername be
>> > sqltest:1443 ?
>> >
>> > What I want to do is create different tcp endpoints for different
>> > applications. That way the default port 1433 would be used only by admins
>> > internally & other users outside the firewall will connect through another
>> > port (new endpoint) than 1433. That way if security is compromised with one
>> > application, I donâ't have to shut the entire server down, I should be able to
>> > shut down that specific port â' does this idea make sense' Iâ'm not having
>> > much luck implementing itâ?¦.
>> >
>> >
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> >> Did you specify this new port in the connection string/server name?
>> >>
>> >> It seems you just want to change the port, and for that you don't need to create a new
>> >> endpoint.
>> >> You
>> >> would just change the port in Server Configuration program.
>> >>
>> >> --
>> >> Tibor Karaszi, SQL Server MVP
>> >> http://www.karaszi.com/sqlserver/default.asp
>> >> http://sqlblog.com/blogs/tibor_karaszi
>> >>
>> >>
>> >> "adba" <adba@.discussions.microsoft.com> wrote in message
>> >> news:04055949-5892-425E-8593-541612857169@.microsoft.com...
>> >> >i have created a new tcp endpoint using the following:
>> >> > CREATE ENDPOINT [CustomConnection1]
>> >> > STATE = STARTED
>> >> > AS TCP
>> >> > (LISTENER_PORT = 1444, LISTENER_IP =ALL)
>> >> > FOR TSQL() ;
>> >> > And I got warning about permissions being revoked for the default tcp
>> >> > endpoint, but I was okay with that since I really wanted all users to go
>> >> > through this new endpoint I am creating.
>> >> > I then granted connect pemissions to a sql login (called test) to connect to
>> >> > this endpoint.
>> >> > I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
>> >> > I tried connecting to the sql server with the test login & it gave me a
>> >> > login failed error 18456.
>> >> > i then granted connect permissions to public to the default tcp port & tried
>> >> > conecting with the test user & it connected successfully. So obviously it was
>> >> > connecting with the default tcp port & not the new port i defined as the
>> >> > endpoint. to be sure, i stopped the new endpoint & connected with the test
>> >> > login again & it still worked.
>> >> > So my question is - what am i doing wrong? i dont connections to go through
>> >> > the default tcp port , i want them to go through the port i define in the
>> >> > endpoint.
>> >> > also, how can i connect to a specific port through management studio?
>> >> >
>> >> > just fyi - i basically followed the instructions on this link:
>> >> > http://msdn2.microsoft.com/en-us/library/ms189310.aspx
>> >> >
>> >> > thanks in advance!
>> >> >
>> >> >
>> >>
>> >>
>>|||ok i tried your steps like u mentioned them & all of them worked except for
"Login adba not able to login with only server name specified". The login
adba is still able to connect with the servername :(
Public has grant permissions to the following:
CustomConnection1
TSQL Default VIA
TSQL Local Machine
TSQL Named Pipes
So I'm guessing adba is able to connect usng one of the other protocols'
"Tibor Karaszi" wrote:
> > but my problem is that to be able to connect to that port, i have to have
> > connect permissions granted to public on the default tcp port.
> That is not what I'm seeing. Below is what I did, and result of my actions. I'm on sp2, btw:
> CREATE LOGIN adba WITH PASSWORD = 'pwd'
> CREATE ENDPOINT [CustomConnection1]
> STATE = STARTED
> AS TCP
> (LISTENER_PORT = 1444, LISTENER_IP =ALL)
> FOR TSQL() ;
> GRANT CONNECT ON ENDPOINT::[CustomConnection1] to [public]
> GRANT CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]
> -- Added port 1444 in Network Server Utility, IPAll, TCP Port: 1433,1444
> -- Restarted SQL Server
> REVOKE CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]
> --Login adba able to login on port 1444
> --Login adba not able to login with only server name specified
> --Login adba not able to login on port 1433
> --Windows login able to login on port 1433
> --Windows login able to login with only server name specified
> --(my Windows account is a login member of syadmin)
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "adba" <adba@.discussions.microsoft.com> wrote in message
> news:9AF19309-A371-4983-B788-95E67789552C@.microsoft.com...
> > thanks. okay now i wa able to connect to a specific port through management
> > studio.
> > but my problem is that to be able to connect to that port, i have to have
> > connect permissions granted to public on the default tcp port. like when you
> > create a new endpointm it takes away the permissions on the deafult port. so
> > i i leave it like that, i cannot connect to the new endpoint i created. if i
> > grant permissions to public, it kind of defeats the purpose of creating new
> > endpoints for me.
> > so i guess my question is can we connect to a new endpoint without granting
> > connect permissions to public on the default tcp port?
> >
> > "Tibor Karaszi" wrote:
> >
> >> I understand about your usage scenario. Yes, that makes sense to me.
> >> To connect to so something else than the "default" port, the client uses below syntax for the
> >> server
> >> name. Note that you don't specify an instance name if it is a named instance:
> >> SERVERNAME,PORT#
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://sqlblog.com/blogs/tibor_karaszi
> >>
> >>
> >> "adba" <adba@.discussions.microsoft.com> wrote in message
> >> news:C84D70CE-AEC4-48F3-B56E-86C264C85858@.microsoft.com...
> >> > No, I havenâ't specified this new port in my servername â' how do I do that in
> >> > management studio? Lets assume my server name is sqltest & the new port
> >> > number is 1443 & the endpoint is called custom1. should the servername be
> >> > sqltest:1443 ?
> >> >
> >> > What I want to do is create different tcp endpoints for different
> >> > applications. That way the default port 1433 would be used only by admins
> >> > internally & other users outside the firewall will connect through another
> >> > port (new endpoint) than 1433. That way if security is compromised with one
> >> > application, I donâ't have to shut the entire server down, I should be able to
> >> > shut down that specific port â' does this idea make sense' Iâ'm not having
> >> > much luck implementing itâ?¦.
> >> >
> >> >
> >> >
> >> > "Tibor Karaszi" wrote:
> >> >
> >> >> Did you specify this new port in the connection string/server name?
> >> >>
> >> >> It seems you just want to change the port, and for that you don't need to create a new
> >> >> endpoint.
> >> >> You
> >> >> would just change the port in Server Configuration program.
> >> >>
> >> >> --
> >> >> Tibor Karaszi, SQL Server MVP
> >> >> http://www.karaszi.com/sqlserver/default.asp
> >> >> http://sqlblog.com/blogs/tibor_karaszi
> >> >>
> >> >>
> >> >> "adba" <adba@.discussions.microsoft.com> wrote in message
> >> >> news:04055949-5892-425E-8593-541612857169@.microsoft.com...
> >> >> >i have created a new tcp endpoint using the following:
> >> >> > CREATE ENDPOINT [CustomConnection1]
> >> >> > STATE = STARTED
> >> >> > AS TCP
> >> >> > (LISTENER_PORT = 1444, LISTENER_IP =ALL)
> >> >> > FOR TSQL() ;
> >> >> > And I got warning about permissions being revoked for the default tcp
> >> >> > endpoint, but I was okay with that since I really wanted all users to go
> >> >> > through this new endpoint I am creating.
> >> >> > I then granted connect pemissions to a sql login (called test) to connect to
> >> >> > this endpoint.
> >> >> > I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
> >> >> > I tried connecting to the sql server with the test login & it gave me a
> >> >> > login failed error 18456.
> >> >> > i then granted connect permissions to public to the default tcp port & tried
> >> >> > conecting with the test user & it connected successfully. So obviously it was
> >> >> > connecting with the default tcp port & not the new port i defined as the
> >> >> > endpoint. to be sure, i stopped the new endpoint & connected with the test
> >> >> > login again & it still worked.
> >> >> > So my question is - what am i doing wrong? i dont connections to go through
> >> >> > the default tcp port , i want them to go through the port i define in the
> >> >> > endpoint.
> >> >> > also, how can i connect to a specific port through management studio?
> >> >> >
> >> >> > just fyi - i basically followed the instructions on this link:
> >> >> > http://msdn2.microsoft.com/en-us/library/ms189310.aspx
> >> >> >
> >> >> > thanks in advance!
> >> >> >
> >> >> >
> >> >>
> >> >>
> >>
> >>
>|||> So I'm guessing adba is able to connect usng one of the other protocols'
That seems to be the case. You can check what netlib a connection is using though the catalog views.
And you can disable netlibs using Configuration Manager. Note that the VIA is disabled by default
and Local Machine is only for local access, so the only one you would need to disable is Named
Pipes.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"adba" <adba@.discussions.microsoft.com> wrote in message
news:DF4D5051-2D13-4083-9A82-BCC4A597E071@.microsoft.com...
> ok i tried your steps like u mentioned them & all of them worked except for
> "Login adba not able to login with only server name specified". The login
> adba is still able to connect with the servername :(
> Public has grant permissions to the following:
> CustomConnection1
> TSQL Default VIA
> TSQL Local Machine
> TSQL Named Pipes
> So I'm guessing adba is able to connect usng one of the other protocols'
>
> "Tibor Karaszi" wrote:
>> > but my problem is that to be able to connect to that port, i have to have
>> > connect permissions granted to public on the default tcp port.
>> That is not what I'm seeing. Below is what I did, and result of my actions. I'm on sp2, btw:
>> CREATE LOGIN adba WITH PASSWORD = 'pwd'
>> CREATE ENDPOINT [CustomConnection1]
>> STATE = STARTED
>> AS TCP
>> (LISTENER_PORT = 1444, LISTENER_IP =ALL)
>> FOR TSQL() ;
>> GRANT CONNECT ON ENDPOINT::[CustomConnection1] to [public]
>> GRANT CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]
>> -- Added port 1444 in Network Server Utility, IPAll, TCP Port: 1433,1444
>> -- Restarted SQL Server
>> REVOKE CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]
>> --Login adba able to login on port 1444
>> --Login adba not able to login with only server name specified
>> --Login adba not able to login on port 1433
>> --Windows login able to login on port 1433
>> --Windows login able to login with only server name specified
>> --(my Windows account is a login member of syadmin)
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://sqlblog.com/blogs/tibor_karaszi
>>
>> "adba" <adba@.discussions.microsoft.com> wrote in message
>> news:9AF19309-A371-4983-B788-95E67789552C@.microsoft.com...
>> > thanks. okay now i wa able to connect to a specific port through management
>> > studio.
>> > but my problem is that to be able to connect to that port, i have to have
>> > connect permissions granted to public on the default tcp port. like when you
>> > create a new endpointm it takes away the permissions on the deafult port. so
>> > i i leave it like that, i cannot connect to the new endpoint i created. if i
>> > grant permissions to public, it kind of defeats the purpose of creating new
>> > endpoints for me.
>> > so i guess my question is can we connect to a new endpoint without granting
>> > connect permissions to public on the default tcp port?
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> >> I understand about your usage scenario. Yes, that makes sense to me.
>> >> To connect to so something else than the "default" port, the client uses below syntax for the
>> >> server
>> >> name. Note that you don't specify an instance name if it is a named instance:
>> >> SERVERNAME,PORT#
>> >>
>> >> --
>> >> Tibor Karaszi, SQL Server MVP
>> >> http://www.karaszi.com/sqlserver/default.asp
>> >> http://sqlblog.com/blogs/tibor_karaszi
>> >>
>> >>
>> >> "adba" <adba@.discussions.microsoft.com> wrote in message
>> >> news:C84D70CE-AEC4-48F3-B56E-86C264C85858@.microsoft.com...
>> >> > No, I havenâ't specified this new port in my servername â' how do I do that in
>> >> > management studio? Lets assume my server name is sqltest & the new port
>> >> > number is 1443 & the endpoint is called custom1. should the servername be
>> >> > sqltest:1443 ?
>> >> >
>> >> > What I want to do is create different tcp endpoints for different
>> >> > applications. That way the default port 1433 would be used only by admins
>> >> > internally & other users outside the firewall will connect through another
>> >> > port (new endpoint) than 1433. That way if security is compromised with one
>> >> > application, I donâ't have to shut the entire server down, I should be able to
>> >> > shut down that specific port â' does this idea make sense' Iâ'm not having
>> >> > much luck implementing itâ?¦.
>> >> >
>> >> >
>> >> >
>> >> > "Tibor Karaszi" wrote:
>> >> >
>> >> >> Did you specify this new port in the connection string/server name?
>> >> >>
>> >> >> It seems you just want to change the port, and for that you don't need to create a new
>> >> >> endpoint.
>> >> >> You
>> >> >> would just change the port in Server Configuration program.
>> >> >>
>> >> >> --
>> >> >> Tibor Karaszi, SQL Server MVP
>> >> >> http://www.karaszi.com/sqlserver/default.asp
>> >> >> http://sqlblog.com/blogs/tibor_karaszi
>> >> >>
>> >> >>
>> >> >> "adba" <adba@.discussions.microsoft.com> wrote in message
>> >> >> news:04055949-5892-425E-8593-541612857169@.microsoft.com...
>> >> >> >i have created a new tcp endpoint using the following:
>> >> >> > CREATE ENDPOINT [CustomConnection1]
>> >> >> > STATE = STARTED
>> >> >> > AS TCP
>> >> >> > (LISTENER_PORT = 1444, LISTENER_IP =ALL)
>> >> >> > FOR TSQL() ;
>> >> >> > And I got warning about permissions being revoked for the default tcp
>> >> >> > endpoint, but I was okay with that since I really wanted all users to go
>> >> >> > through this new endpoint I am creating.
>> >> >> > I then granted connect pemissions to a sql login (called test) to connect to
>> >> >> > this endpoint.
>> >> >> > I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
>> >> >> > I tried connecting to the sql server with the test login & it gave me a
>> >> >> > login failed error 18456.
>> >> >> > i then granted connect permissions to public to the default tcp port & tried
>> >> >> > conecting with the test user & it connected successfully. So obviously it was
>> >> >> > connecting with the default tcp port & not the new port i defined as the
>> >> >> > endpoint. to be sure, i stopped the new endpoint & connected with the test
>> >> >> > login again & it still worked.
>> >> >> > So my question is - what am i doing wrong? i dont connections to go through
>> >> >> > the default tcp port , i want them to go through the port i define in the
>> >> >> > endpoint.
>> >> >> > also, how can i connect to a specific port through management studio?
>> >> >> >
>> >> >> > just fyi - i basically followed the instructions on this link:
>> >> >> > http://msdn2.microsoft.com/en-us/library/ms189310.aspx
>> >> >> >
>> >> >> > thanks in advance!
>> >> >> >
>> >> >> >
>> >> >>
>> >> >>
>> >>
>> >>
>>|||That was it Tibor. Once I disabled the other protocols it couldnt connect.
Thanks so much for your help.
"Tibor Karaszi" wrote:
> > So I'm guessing adba is able to connect usng one of the other protocols'
> That seems to be the case. You can check what netlib a connection is using though the catalog views.
> And you can disable netlibs using Configuration Manager. Note that the VIA is disabled by default
> and Local Machine is only for local access, so the only one you would need to disable is Named
> Pipes.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "adba" <adba@.discussions.microsoft.com> wrote in message
> news:DF4D5051-2D13-4083-9A82-BCC4A597E071@.microsoft.com...
> > ok i tried your steps like u mentioned them & all of them worked except for
> >
> > "Login adba not able to login with only server name specified". The login
> > adba is still able to connect with the servername :(
> >
> > Public has grant permissions to the following:
> > CustomConnection1
> > TSQL Default VIA
> > TSQL Local Machine
> > TSQL Named Pipes
> >
> > So I'm guessing adba is able to connect usng one of the other protocols'
> >
> >
> > "Tibor Karaszi" wrote:
> >
> >> > but my problem is that to be able to connect to that port, i have to have
> >> > connect permissions granted to public on the default tcp port.
> >>
> >> That is not what I'm seeing. Below is what I did, and result of my actions. I'm on sp2, btw:
> >>
> >> CREATE LOGIN adba WITH PASSWORD = 'pwd'
> >>
> >> CREATE ENDPOINT [CustomConnection1]
> >> STATE = STARTED
> >> AS TCP
> >> (LISTENER_PORT = 1444, LISTENER_IP =ALL)
> >> FOR TSQL() ;
> >>
> >> GRANT CONNECT ON ENDPOINT::[CustomConnection1] to [public]
> >>
> >> GRANT CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]
> >>
> >> -- Added port 1444 in Network Server Utility, IPAll, TCP Port: 1433,1444
> >> -- Restarted SQL Server
> >>
> >> REVOKE CONNECT ON ENDPOINT::[TSQL Default TCP] to [public]
> >>
> >> --Login adba able to login on port 1444
> >> --Login adba not able to login with only server name specified
> >> --Login adba not able to login on port 1433
> >> --Windows login able to login on port 1433
> >> --Windows login able to login with only server name specified
> >> --(my Windows account is a login member of syadmin)
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://sqlblog.com/blogs/tibor_karaszi
> >>
> >>
> >> "adba" <adba@.discussions.microsoft.com> wrote in message
> >> news:9AF19309-A371-4983-B788-95E67789552C@.microsoft.com...
> >> > thanks. okay now i wa able to connect to a specific port through management
> >> > studio.
> >> > but my problem is that to be able to connect to that port, i have to have
> >> > connect permissions granted to public on the default tcp port. like when you
> >> > create a new endpointm it takes away the permissions on the deafult port. so
> >> > i i leave it like that, i cannot connect to the new endpoint i created. if i
> >> > grant permissions to public, it kind of defeats the purpose of creating new
> >> > endpoints for me.
> >> > so i guess my question is can we connect to a new endpoint without granting
> >> > connect permissions to public on the default tcp port?
> >> >
> >> > "Tibor Karaszi" wrote:
> >> >
> >> >> I understand about your usage scenario. Yes, that makes sense to me.
> >> >> To connect to so something else than the "default" port, the client uses below syntax for the
> >> >> server
> >> >> name. Note that you don't specify an instance name if it is a named instance:
> >> >> SERVERNAME,PORT#
> >> >>
> >> >> --
> >> >> Tibor Karaszi, SQL Server MVP
> >> >> http://www.karaszi.com/sqlserver/default.asp
> >> >> http://sqlblog.com/blogs/tibor_karaszi
> >> >>
> >> >>
> >> >> "adba" <adba@.discussions.microsoft.com> wrote in message
> >> >> news:C84D70CE-AEC4-48F3-B56E-86C264C85858@.microsoft.com...
> >> >> > No, I havenâ't specified this new port in my servername â' how do I do that in
> >> >> > management studio? Lets assume my server name is sqltest & the new port
> >> >> > number is 1443 & the endpoint is called custom1. should the servername be
> >> >> > sqltest:1443 ?
> >> >> >
> >> >> > What I want to do is create different tcp endpoints for different
> >> >> > applications. That way the default port 1433 would be used only by admins
> >> >> > internally & other users outside the firewall will connect through another
> >> >> > port (new endpoint) than 1433. That way if security is compromised with one
> >> >> > application, I donâ't have to shut the entire server down, I should be able to
> >> >> > shut down that specific port â' does this idea make sense' Iâ'm not having
> >> >> > much luck implementing itâ?¦.
> >> >> >
> >> >> >
> >> >> >
> >> >> > "Tibor Karaszi" wrote:
> >> >> >
> >> >> >> Did you specify this new port in the connection string/server name?
> >> >> >>
> >> >> >> It seems you just want to change the port, and for that you don't need to create a new
> >> >> >> endpoint.
> >> >> >> You
> >> >> >> would just change the port in Server Configuration program.
> >> >> >>
> >> >> >> --
> >> >> >> Tibor Karaszi, SQL Server MVP
> >> >> >> http://www.karaszi.com/sqlserver/default.asp
> >> >> >> http://sqlblog.com/blogs/tibor_karaszi
> >> >> >>
> >> >> >>
> >> >> >> "adba" <adba@.discussions.microsoft.com> wrote in message
> >> >> >> news:04055949-5892-425E-8593-541612857169@.microsoft.com...
> >> >> >> >i have created a new tcp endpoint using the following:
> >> >> >> > CREATE ENDPOINT [CustomConnection1]
> >> >> >> > STATE = STARTED
> >> >> >> > AS TCP
> >> >> >> > (LISTENER_PORT = 1444, LISTENER_IP =ALL)
> >> >> >> > FOR TSQL() ;
> >> >> >> > And I got warning about permissions being revoked for the default tcp
> >> >> >> > endpoint, but I was okay with that since I really wanted all users to go
> >> >> >> > through this new endpoint I am creating.
> >> >> >> > I then granted connect pemissions to a sql login (called test) to connect to
> >> >> >> > this endpoint.
> >> >> >> > I added the tcp port 1444 to the IPALL TCP Port list & restarted SQL.
> >> >> >> > I tried connecting to the sql server with the test login & it gave me a
> >> >> >> > login failed error 18456.
> >> >> >> > i then granted connect permissions to public to the default tcp port & tried
> >> >> >> > conecting with the test user & it connected successfully. So obviously it was
> >> >> >> > connecting with the default tcp port & not the new port i defined as the
> >> >> >> > endpoint. to be sure, i stopped the new endpoint & connected with the test
> >> >> >> > login again & it still worked.
> >> >> >> > So my question is - what am i doing wrong? i dont connections to go through
> >> >> >> > the default tcp port , i want them to go through the port i define in the
> >> >> >> > endpoint.
> >> >> >> > also, how can i connect to a specific port through management studio?
> >> >> >> >
> >> >> >> > just fyi - i basically followed the instructions on this link:
> >> >> >> > http://msdn2.microsoft.com/en-us/library/ms189310.aspx
> >> >> >> >
> >> >> >> > thanks in advance!
> >> >> >> >
> >> >> >> >
> >> >> >>
> >> >> >>
> >> >>
> >> >>
> >>
> >>
>

Sunday, 11 March 2012

Connect from sql query via IP adress - is i possible?

Does anybody really know is it possible? We don't want to create a linked
database, but we need to make some steps on the remote database, gather some
data and then send this data to our main server via IP connection, setting
the connection every time when the remote server wants to transfer the data.
Is it possible at all if we don't create a linked database or whatever, just
from sql script? If yes, then how?
Dmitri.You can do ad-hoc/pass through query via openrowset or opendatasource.
http://msdn.microsoft.com/library/e..._oa-oz_78z8.asp
http://msdn.microsoft.com/library/e...asp?frame=true
"Just D." <no@.spam.please> wrote in message
news:FkSOc.18891$1o.215@.fed1read06...
> Does anybody really know is it possible? We don't want to create a linked
> database, but we need to make some steps on the remote database, gather so
me
> data and then send this data to our main server via IP connection, setting
> the connection every time when the remote server wants to transfer the dat
a.
> Is it possible at all if we don't create a linked database or whatever, ju
st
> from sql script? If yes, then how?
> Dmitri.
>|||Thanks for the answer.
"oj" <nospam_ojngo@.home.com> wrote in message
news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
> You can do ad-hoc/pass through query via openrowset or opendatasource.
> http://msdn.microsoft.com/library/e..._oa-oz_78z8.asp
>
http://msdn.microsoft.com/library/e...asp?frame=true[vbcol=seagreen]
linked[vbcol=seagreen]
some[vbcol=seagreen]
setting[vbcol=seagreen]
data.[vbcol=seagreen]
just[vbcol=seagreen]
Another one idea - if I create ODBC and it's tested and works fine is it
possible to use that for the same purpose setting a remote database name via
ODBC? In other words, is it possible to use a database alias that works via
ODBC to set a connection from sql query without a linked database?
Maybe it's easier...
Dmitri.|||Thanks for the answer.
"oj" <nospam_ojngo@.home.com> wrote in message
news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
> You can do ad-hoc/pass through query via openrowset or opendatasource.
> http://msdn.microsoft.com/library/e..._oa-oz_78z8.asp
>
http://msdn.microsoft.com/library/e...asp?frame=true[vbcol=seagreen]
linked[vbcol=seagreen]
some[vbcol=seagreen]
setting[vbcol=seagreen]
data.[vbcol=seagreen]
just[vbcol=seagreen]
Another one idea - if I create ODBC and it's tested and works fine is it
possible to use that for the same purpose setting a remote database name via
ODBC? In other words, is it possible to use a database alias that works via
ODBC to set a connection from sql query without a linked database?
Maybe it's easier...
Dmitri.|||Look at Appendix F of the Analysis Services Operations Guide
http://www.microsoft.com/technet/pr...n/anservog.mspx
It has a nice example of how you do this.
Dave Wickert [MSFT]
dwickert@.online.microsoft.com
Program Manager
BI SystemsTeam
SQL BI Product Unit (Analysis Services)
--
This posting is provided "AS IS" with no warranties, and confers no rights.
"Just D." <no@.spam.please> wrote in message
news:xpTOc.19314$1o.15882@.fed1read06...
> Thanks for the answer.
> "oj" <nospam_ojngo@.home.com> wrote in message
> news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
>
http://msdn.microsoft.com/library/e...asp?frame=true
> linked
gather[vbcol=seagreen]
> some
> setting
> data.
whatever,[vbcol=seagreen]
> just
> Another one idea - if I create ODBC and it's tested and works fine is it
> possible to use that for the same purpose setting a remote database name
via
> ODBC? In other words, is it possible to use a database alias that works
via
> ODBC to set a connection from sql query without a linked database?
> Maybe it's easier...
> Dmitri.
>

Connect from sql query via IP adress - is i possible?

Does anybody really know is it possible? We don't want to create a linked
database, but we need to make some steps on the remote database, gather some
data and then send this data to our main server via IP connection, setting
the connection every time when the remote server wants to transfer the data.
Is it possible at all if we don't create a linked database or whatever, just
from sql script? If yes, then how?
Dmitri.
You can do ad-hoc/pass through query via openrowset or opendatasource.
http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
http://msdn.microsoft.com/library/en...asp?frame=true
"Just D." <no@.spam.please> wrote in message
news:FkSOc.18891$1o.215@.fed1read06...
> Does anybody really know is it possible? We don't want to create a linked
> database, but we need to make some steps on the remote database, gather some
> data and then send this data to our main server via IP connection, setting
> the connection every time when the remote server wants to transfer the data.
> Is it possible at all if we don't create a linked database or whatever, just
> from sql script? If yes, then how?
> Dmitri.
>
|||Thanks for the answer.
"oj" <nospam_ojngo@.home.com> wrote in message
news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
> You can do ad-hoc/pass through query via openrowset or opendatasource.
> http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
linked[vbcol=seagreen]
some[vbcol=seagreen]
setting[vbcol=seagreen]
data.[vbcol=seagreen]
just[vbcol=seagreen]
Another one idea - if I create ODBC and it's tested and works fine is it
possible to use that for the same purpose setting a remote database name via
ODBC? In other words, is it possible to use a database alias that works via
ODBC to set a connection from sql query without a linked database?
Maybe it's easier...
Dmitri.
|||Thanks for the answer.
"oj" <nospam_ojngo@.home.com> wrote in message
news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
> You can do ad-hoc/pass through query via openrowset or opendatasource.
> http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
linked[vbcol=seagreen]
some[vbcol=seagreen]
setting[vbcol=seagreen]
data.[vbcol=seagreen]
just[vbcol=seagreen]
Another one idea - if I create ODBC and it's tested and works fine is it
possible to use that for the same purpose setting a remote database name via
ODBC? In other words, is it possible to use a database alias that works via
ODBC to set a connection from sql query without a linked database?
Maybe it's easier...
Dmitri.
|||Look at Appendix F of the Analysis Services Operations Guide
http://www.microsoft.com/technet/pro.../anservog.mspx
It has a nice example of how you do this.
Dave Wickert [MSFT]
dwickert@.online.microsoft.com
Program Manager
BI SystemsTeam
SQL BI Product Unit (Analysis Services)
This posting is provided "AS IS" with no warranties, and confers no rights.
"Just D." <no@.spam.please> wrote in message
news:xpTOc.19314$1o.15882@.fed1read06...
> Thanks for the answer.
> "oj" <nospam_ojngo@.home.com> wrote in message
> news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
> linked
gather[vbcol=seagreen]
> some
> setting
> data.
whatever,
> just
> Another one idea - if I create ODBC and it's tested and works fine is it
> possible to use that for the same purpose setting a remote database name
via
> ODBC? In other words, is it possible to use a database alias that works
via
> ODBC to set a connection from sql query without a linked database?
> Maybe it's easier...
> Dmitri.
>

Connect from sql query via IP adress - is i possible?

Does anybody really know is it possible? We don't want to create a linked
database, but we need to make some steps on the remote database, gather some
data and then send this data to our main server via IP connection, setting
the connection every time when the remote server wants to transfer the data.
Is it possible at all if we don't create a linked database or whatever, just
from sql script? If yes, then how?
Dmitri.
You can do ad-hoc/pass through query via openrowset or opendatasource.
http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
http://msdn.microsoft.com/library/en...asp?frame=true
"Just D." <no@.spam.please> wrote in message
news:FkSOc.18891$1o.215@.fed1read06...
> Does anybody really know is it possible? We don't want to create a linked
> database, but we need to make some steps on the remote database, gather some
> data and then send this data to our main server via IP connection, setting
> the connection every time when the remote server wants to transfer the data.
> Is it possible at all if we don't create a linked database or whatever, just
> from sql script? If yes, then how?
> Dmitri.
>
|||Thanks for the answer.
"oj" <nospam_ojngo@.home.com> wrote in message
news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
> You can do ad-hoc/pass through query via openrowset or opendatasource.
> http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
linked[vbcol=seagreen]
some[vbcol=seagreen]
setting[vbcol=seagreen]
data.[vbcol=seagreen]
just[vbcol=seagreen]
Another one idea - if I create ODBC and it's tested and works fine is it
possible to use that for the same purpose setting a remote database name via
ODBC? In other words, is it possible to use a database alias that works via
ODBC to set a connection from sql query without a linked database?
Maybe it's easier...
Dmitri.
|||Thanks for the answer.
"oj" <nospam_ojngo@.home.com> wrote in message
news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
> You can do ad-hoc/pass through query via openrowset or opendatasource.
> http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
linked[vbcol=seagreen]
some[vbcol=seagreen]
setting[vbcol=seagreen]
data.[vbcol=seagreen]
just[vbcol=seagreen]
Another one idea - if I create ODBC and it's tested and works fine is it
possible to use that for the same purpose setting a remote database name via
ODBC? In other words, is it possible to use a database alias that works via
ODBC to set a connection from sql query without a linked database?
Maybe it's easier...
Dmitri.
|||Look at Appendix F of the Analysis Services Operations Guide
http://www.microsoft.com/technet/pro.../anservog.mspx
It has a nice example of how you do this.
Dave Wickert [MSFT]
dwickert@.online.microsoft.com
Program Manager
BI SystemsTeam
SQL BI Product Unit (Analysis Services)
This posting is provided "AS IS" with no warranties, and confers no rights.
"Just D." <no@.spam.please> wrote in message
news:xpTOc.19314$1o.15882@.fed1read06...
> Thanks for the answer.
> "oj" <nospam_ojngo@.home.com> wrote in message
> news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
> linked
gather[vbcol=seagreen]
> some
> setting
> data.
whatever,
> just
> Another one idea - if I create ODBC and it's tested and works fine is it
> possible to use that for the same purpose setting a remote database name
via
> ODBC? In other words, is it possible to use a database alias that works
via
> ODBC to set a connection from sql query without a linked database?
> Maybe it's easier...
> Dmitri.
>

Connect from sql query via IP adress - is i possible?

Does anybody really know is it possible? We don't want to create a linked
database, but we need to make some steps on the remote database, gather some
data and then send this data to our main server via IP connection, setting
the connection every time when the remote server wants to transfer the data.
Is it possible at all if we don't create a linked database or whatever, just
from sql script? If yes, then how?
Dmitri.
You can do ad-hoc/pass through query via openrowset or opendatasource.
http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
http://msdn.microsoft.com/library/en...asp?frame=true
"Just D." <no@.spam.please> wrote in message
news:FkSOc.18891$1o.215@.fed1read06...
> Does anybody really know is it possible? We don't want to create a linked
> database, but we need to make some steps on the remote database, gather some
> data and then send this data to our main server via IP connection, setting
> the connection every time when the remote server wants to transfer the data.
> Is it possible at all if we don't create a linked database or whatever, just
> from sql script? If yes, then how?
> Dmitri.
>
|||Thanks for the answer.
"oj" <nospam_ojngo@.home.com> wrote in message
news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
> You can do ad-hoc/pass through query via openrowset or opendatasource.
> http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
linked[vbcol=seagreen]
some[vbcol=seagreen]
setting[vbcol=seagreen]
data.[vbcol=seagreen]
just[vbcol=seagreen]
Another one idea - if I create ODBC and it's tested and works fine is it
possible to use that for the same purpose setting a remote database name via
ODBC? In other words, is it possible to use a database alias that works via
ODBC to set a connection from sql query without a linked database?
Maybe it's easier...
Dmitri.
|||Thanks for the answer.
"oj" <nospam_ojngo@.home.com> wrote in message
news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
> You can do ad-hoc/pass through query via openrowset or opendatasource.
> http://msdn.microsoft.com/library/en...oa-oz_78z8.asp
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
linked[vbcol=seagreen]
some[vbcol=seagreen]
setting[vbcol=seagreen]
data.[vbcol=seagreen]
just[vbcol=seagreen]
Another one idea - if I create ODBC and it's tested and works fine is it
possible to use that for the same purpose setting a remote database name via
ODBC? In other words, is it possible to use a database alias that works via
ODBC to set a connection from sql query without a linked database?
Maybe it's easier...
Dmitri.
|||Look at Appendix F of the Analysis Services Operations Guide
http://www.microsoft.com/technet/pro.../anservog.mspx
It has a nice example of how you do this.
Dave Wickert [MSFT]
dwickert@.online.microsoft.com
Program Manager
BI SystemsTeam
SQL BI Product Unit (Analysis Services)
This posting is provided "AS IS" with no warranties, and confers no rights.
"Just D." <no@.spam.please> wrote in message
news:xpTOc.19314$1o.15882@.fed1read06...
> Thanks for the answer.
> "oj" <nospam_ojngo@.home.com> wrote in message
> news:ui9sqkzdEHA.4048@.TK2MSFTNGP12.phx.gbl...
>
http://msdn.microsoft.com/library/en...asp?frame=true[vbcol=seagreen]
> linked
gather[vbcol=seagreen]
> some
> setting
> data.
whatever,
> just
> Another one idea - if I create ODBC and it's tested and works fine is it
> possible to use that for the same purpose setting a remote database name
via
> ODBC? In other words, is it possible to use a database alias that works
via
> ODBC to set a connection from sql query without a linked database?
> Maybe it's easier...
> Dmitri.
>

Connect from Databases in 1st Instance to Databases in 2nd Instance

This is the scenario. Is it possible to create views or something (like Oracle DB Links) in a database in Instance 1 which can show data from another database in 2nd Instance ?
I want to do this to create reports.you want to create a linked server with sp_addlinkedserver|||thanks. it worked.

Connect Delphi 2006 to MS SQL Express

I use Delphi 2006 to connect MS SQL Express 2005. When I save record, it shows the following error message:

Database Server Error : Cannot create new transaction because capacity was exceeded.

Does anyone know what happen and how to solve?

Thanks!

A quick MSN Search finds http://bdn.borland.com/article/0,1410,32020,00.html with the following solution:

When using dbExpress MSSQL and TClientDataSet.ApplyUpdates,
you may encounter either of the following errors while
applying updates, due to a SQLOLEDB.DLL limitation:

"Cannot create new transaction because capacity was exceeded."

"Cannot create new connection because in manual or
distributed transaction mode."

To resolve the errors, use one of the following workarounds:

- On the DataSetProvider Options property, make sure
poFetchBlobsOnDemand and poFetchDetailsOnDemand are False.

- Use a BeforeApplyUpdates event to either call CloseDataSets
or Close the connection:

procedure TForm1.DataSetProvider1BeforeApplyUpdates(Sender: TObject;
var OwnerData: OleVariant);
begin
SQLConnection1.CloseDataSets;
// SQLConnection1.Close;
end;


Regards,

Mike Wachal
SQL Express team

-
Check out my tips for getting your answer faster and how to ask a good question: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=307712&SiteID=1

connect by DSN

Hi,

how can i connect MSSQL through System DSN. i know how to create DSN. but i don't know how to code the connection string.

regards,

SeeConnectionStrings.com.

Ryan

Thursday, 8 March 2012

Connect Access to SQL Server AND Local ODBC Connection

I have a customer that wants me to create a database and use a back end of
SQL Server (hosted on the Internet for his site). This would normally be
easy to create the front end with an ADP and continue life as normal. But,
in order to connect his accounting program to this program that I am
creating, I also need the ADP/MDB to connect to his local ODBC Link
(Business Vision Connect!) This is the software that is installed on the
local machine to speak to the accounting software. I can get Connect! to
work when it isn't in an ADP. I can get SQL Server to work in an ADP. So,
at this point, I can get one or the other to work...
Does anyone know of a way to get SQL Server to work with an MDB without
asking for the SQLServer Password OR a way to get his Connect (Regular ODBC
System DSN) to work in an ADP? I have also tried creating a file DSN (for
Connect!) which looks like it could work with an ADP, but since the
Connect! is rather old, it doesn't seem to like to be put into a FileDSN.
Any ideas would be great!!!
Thanks,
Shawn
You can connect an mdb to SQL Server by creating linked tables or by
using pass-through queries. You supply the connection string in code.
From the MDB, create a DAO TableDef object for the linked tables, and
QueryDef objects for the pass-through queries (which return read-only
result sets). HTH,
Mary
On Wed, 16 Jun 2004 20:27:05 -0400, "Shawn Oatley"
<notmyemail@.address.com> wrote:

>I have a customer that wants me to create a database and use a back end of
>SQL Server (hosted on the Internet for his site). This would normally be
>easy to create the front end with an ADP and continue life as normal. But,
>in order to connect his accounting program to this program that I am
>creating, I also need the ADP/MDB to connect to his local ODBC Link
>(Business Vision Connect!) This is the software that is installed on the
>local machine to speak to the accounting software. I can get Connect! to
>work when it isn't in an ADP. I can get SQL Server to work in an ADP. So,
>at this point, I can get one or the other to work...
>Does anyone know of a way to get SQL Server to work with an MDB without
>asking for the SQLServer Password OR a way to get his Connect (Regular ODBC
>System DSN) to work in an ADP? I have also tried creating a file DSN (for
>Connect!) which looks like it could work with an ADP, but since the
>Connect! is rather old, it doesn't seem to like to be put into a FileDSN.
>Any ideas would be great!!!
>Thanks,
>Shawn
>
|||Shawn,
Find a way to make the ADP work. Linked tables with mdb are a nightmare. Modifying pass through queries on the fly bloats your database and are much harder to maintain than sprocs. Linked tables create excessive connection/locking which leads to DEADLO
CKS. Linked tables should *not be even considered*when the database is accesses through the internet.
Here is a link to a site with numereous connections string examples. http://www.able-consulting.com/ADO_Conn.htm
"Shawn Oatley" wrote:

> I have a customer that wants me to create a database and use a back end of
> SQL Server (hosted on the Internet for his site). This would normally be
> easy to create the front end with an ADP and continue life as normal. But,
> in order to connect his accounting program to this program that I am
> creating, I also need the ADP/MDB to connect to his local ODBC Link
> (Business Vision Connect!) This is the software that is installed on the
> local machine to speak to the accounting software. I can get Connect! to
> work when it isn't in an ADP. I can get SQL Server to work in an ADP. So,
> at this point, I can get one or the other to work...
> Does anyone know of a way to get SQL Server to work with an MDB without
> asking for the SQLServer Password OR a way to get his Connect (Regular ODBC
> System DSN) to work in an ADP? I have also tried creating a file DSN (for
> Connect!) which looks like it could work with an ADP, but since the
> Connect! is rather old, it doesn't seem to like to be put into a FileDSN.
> Any ideas would be great!!!
> Thanks,
> Shawn
>
>

Connect Access to SQL Server AND Local ODBC Connection

I have a customer that wants me to create a database and use a back end of
SQL Server (hosted on the Internet for his site). This would normally be
easy to create the front end with an ADP and continue life as normal. But,
in order to connect his accounting program to this program that I am
creating, I also need the ADP/MDB to connect to his local ODBC Link
(Business Vision Connect!) This is the software that is installed on the
local machine to speak to the accounting software. I can get Connect! to
work when it isn't in an ADP. I can get SQL Server to work in an ADP. So,
at this point, I can get one or the other to work...
Does anyone know of a way to get SQL Server to work with an MDB without
asking for the SQLServer Password OR a way to get his Connect (Regular ODBC
System DSN) to work in an ADP? I have also tried creating a file DSN (for
Connect!) which looks like it could work with an ADP, but since the
Connect! is rather old, it doesn't seem to like to be put into a FileDSN.
Any ideas would be great!!!
Thanks,
ShawnYou can connect an mdb to SQL Server by creating linked tables or by
using pass-through queries. You supply the connection string in code.
From the MDB, create a DAO TableDef object for the linked tables, and
QueryDef objects for the pass-through queries (which return read-only
result sets). HTH,
Mary
On Wed, 16 Jun 2004 20:27:05 -0400, "Shawn Oatley"
<notmyemail@.address.com> wrote:

>I have a customer that wants me to create a database and use a back end of
>SQL Server (hosted on the Internet for his site). This would normally be
>easy to create the front end with an ADP and continue life as normal. But,
>in order to connect his accounting program to this program that I am
>creating, I also need the ADP/MDB to connect to his local ODBC Link
>(Business Vision Connect!) This is the software that is installed on the
>local machine to speak to the accounting software. I can get Connect! to
>work when it isn't in an ADP. I can get SQL Server to work in an ADP. So,
>at this point, I can get one or the other to work...
>Does anyone know of a way to get SQL Server to work with an MDB without
>asking for the SQLServer Password OR a way to get his Connect (Regular ODBC
>System DSN) to work in an ADP? I have also tried creating a file DSN (for
>Connect!) which looks like it could work with an ADP, but since the
>Connect! is rather old, it doesn't seem to like to be put into a FileDSN.
>Any ideas would be great!!!
>Thanks,
>Shawn
>|||Shawn,
Find a way to make the ADP work. Linked tables with mdb are a nightmare. M
odifying pass through queries on the fly bloats your database and are much h
arder to maintain than sprocs. Linked tables create excessive connection/lo
cking which leads to DEADLO
CKS. Linked tables should *not be even considered*when the database is acce
sses through the internet.
Here is a link to a site with numereous connections string examples. .able-consulting.com/ADO_Conn.htm" target="_blank">http://www
.able-consulting.com/ADO_Conn.htm
"Shawn Oatley" wrote:

> I have a customer that wants me to create a database and use a back end of
> SQL Server (hosted on the Internet for his site). This would normally be
> easy to create the front end with an ADP and continue life as normal. But
,
> in order to connect his accounting program to this program that I am
> creating, I also need the ADP/MDB to connect to his local ODBC Link
> (Business Vision Connect!) This is the software that is installed on the
> local machine to speak to the accounting software. I can get Connect! to
> work when it isn't in an ADP. I can get SQL Server to work in an ADP. So,
> at this point, I can get one or the other to work...
> Does anyone know of a way to get SQL Server to work with an MDB without
> asking for the SQLServer Password OR a way to get his Connect (Regular ODB
C
> System DSN) to work in an ADP? I have also tried creating a file DSN (fo
r
> Connect!) which looks like it could work with an ADP, but since the
> Connect! is rather old, it doesn't seem to like to be put into a FileDSN.
> Any ideas would be great!!!
> Thanks,
> Shawn
>
>

Conn Obj

Hi All -

Prior to ASP .Net I use to create a connection object for SQL Server in my global.asa file and I would reference the obj whenever needed. how can I do the same in asp .net.

Here is my old asp sample:

Global.asa file:

Sub Session_OnStart

set session("conn") = createobject("adodb.connection")
session("conn").Open "PROVIDER=MSDASQL;DRIVER={SQL Server};SERVER=xxx.xxx.xxx.xxx;DATABASE=xxxxx_db;UID=xx;PWD=xxxxxxxx;"

End Sub


Call from Other Pages:

sqlstr = "select * from members WHERE memberid = '" & session("mbr_memberno") & "'"
set objRS = session("conn").Execute(sqlstr)

... How can I do this in .net?

rich

You can do a similar thing in ASP.NET using the global.asax file.Though, I would caution against it: check out this article for somereasons why you want to avoid this:
http://www.codeproject.com/asp/dbobjects.asp
Jason

|||

So is it better to just set session variables for servername, uid and pass so if it changes its in one file rather than shifting through tons of code replacing sql server names. Also if I do create a session var of these items can I call them in the vb.net portion of the code?

rich

|||web.config is the place to do it...there's an article on my blog on how to do it..check it out.|||The proper way to do it is to store the connection string itself in theweb.config (as the previous post suggests -- though others say thatstoring usernames and passwords in an unecrypted format is a bad idea-- trusted connections are better they say) and instantiate theconnection object and close the connection object on each page.
Jason
|||

You can encrypt the connection string and put it in the web config. There's a good example of doing so here:http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetsec/html/SecNetHT08.asp

Conlidate databases for multiple installations

1. install a SQL Express instance such as myexpress;

2. create some databases with tables such as db1 and db2;

3. Reinstall SQL Express with the same instance name "myexpress". I assume we need reinstall SQL Express myexpress again becuase of bad operations.

4. Open the myexpress by management tool but I can not see db1 and db2 databases but the datafiles and logfiles are in the data directory.

The question is what I need to do so I can consolidate exited databases so they can be seen in "myexpress" instance by management tool?

Hmmm it seems it has nothing to do with Team System, I would recommend you to ask this in the SQL Server forums, in which you will get more help for sure, sorry and good luck.

I also think the step you are not doing is an attach of the databases.

Confusion with date attributes and member name / value

Hi,

I'm just wondering about how the best approach is to create a date member... The member name has to be a string, so there seams to be no way that a client application can decide how to display a date (by it's regional settings). You have to do the formatting in the DSV. You can use some formatting with the member value but this isn't used by client applications by default (is there any application using it out there, yet?).

So what's the best approach here?

Thanks,

Hi Thomas,

Could Translations help you (i.e defining different captions for a given date, by locale)?

|||

Deepak,

yes that might be a solution... However this might be a problem with other datatypes as well... I just think about an attribute "Size" which might be formatted in differently in different regions (with a comma or point as decimal seperator, ...). So everything has to be done with translations? Not a very good approach...

Thanks anyway...

Friday, 24 February 2012

Conflict tables

Hello,
We are creating merge replication.
Is there any way to make the conflict tables to be create
in another database then the publisher database?
or to move them after creation.
Many Thanks for reply.No, I don't think the conflict tables can be moved.
--
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"DIRYU" <anonymous@.discussions.microsoft.com> wrote in message
news:653f01c49336$0acd99e0$a301280a@.phx.gbl...
> Hello,
> We are creating merge replication.
> Is there any way to make the conflict tables to be create
> in another database then the publisher database?
> or to move them after creation.
>
> Many Thanks for reply.

Conflict Resolution: Is defining local subscription enough: How to get log of lost record.

Publisher always wins is the default, so you don't need
to do anything to achieve this.
To get notification of a conflict, you could create a
polling routine (there's no alert that I know of).
HTH,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
hi Paul,
Thanks for you reply, I have few more queries
1. Where is this conflict information specially the losing row information is stored, at the publisher side or at the subscriber side? if losing row information is maintained at the publisher side is there any way so that we can store this information at the publisher side.
2. As you talked about creating a polling routine to get notification of conflict, in my implementation I just want a log file which contain information about the losing row nothing else, will the polling routine you are referring to can do the same and alsoI have not much information about how to write polling routine can you throw some light on it?
regards.
Ruchir.

Quote:

Originally posted by Paul Ibison
Publisher always wins is the default, so you don't need
to do anything to achieve this.
To get notification of a conflict, you could create a
polling routine (there's no alert that I know of).
HTH,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)

|||Have a look at the tables
conflict_<PublicationName>_<ArticleName>_usertable name
and
MSmerge_delete_conflicts
at the publisher.
The polling routine would be not much more than a job
that runs regularly and does a select from this table,
then sends the results in an email as an attachment. The
origin_datasource column could be used to determine the
correct recipient.
HTH,
Paul Ibison SQL Server MVP, www.replicationanswers.com
(recommended sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)

conflict between (cascade) DELETE Trigger and Foreign Key Constrain

I'm trying to create relational database with some triggers in SQL Server 7.0, but it doesn't work as expected. Let's say that I have 'Office' database with two tables, 'Users' and 'UserRights' (userRights table should have much more rights, but that's not relevant for this problem):

CREATE TABLE [Users] (
[FS_Username] [nvarchar] (8) NOT NULL ,
[FS_Password] [nvarchar] (32) NOT NULL ,
CONSTRAINT [PK_Users] PRIMARY KEY NONCLUSTERED
(
[FS_Username]
) ON [PRIMARY]
) ON [PRIMARY]
GO

CREATE TABLE [UserRights] (
[FS_Username] [nvarchar] (8) NOT NULL ,
[FI_UserType] [int] NOT NULL CONSTRAINT [DF_UserRights_FI_UserType] DEFAULT (1),
[FI_AllowLogin] [int] NOT NULL CONSTRAINT [DF_UserRights_FI_AllowLogin] DEFAULT (1),
CONSTRAINT [PK_UserRights] PRIMARY KEY NONCLUSTERED
(
[FS_Username]
) ON [PRIMARY] ,
CONSTRAINT [FK_UserRights_Users] FOREIGN KEY
(
[FS_Username]
) REFERENCES [Users] (
[FS_Username]
)
) ON [PRIMARY]
GO

Foreign Key CONSTRAIN above is created by adding both tables to the diagram and defining relationship between these two tables FS_Username field, where 'Enable relationship for INSERT and UPDATE' option is turned ON. You can easily see this if you create diagram youself and insert these two tables in it.
Next to this, I created two triggers that should handle inserting/deleting rows in UserRights table as consequence of inserting/deleting rows in Users table:

CREATE TRIGGER InsertUserRights ON Users
FOR INSERT
AS
BEGIN
INSERT INTO UserRights (FS_Username) (SELECT FS_Username FROM Inserted)
END

CREATE TRIGGER DeleteUserRights ON Users
FOR DELETE
AS
BEGIN
DELETE UserRights WHERE FS_Username IN
(SELECT FS_Username FROM Users)
END

Now, when (manually) I insert row in Users table, UserRights table gets updated accordingly. HOWEVER, when I try to delete one or more entries from Users table, I get error report. For example, if you try to execute following two commands:

Insert Into Users (FS_Username, FS_Password) VALUES ('John', 's')

Delete from Users

... first command will succede, but second one will fail with message:

DELETE statement conflicted with COLUMN REFERENCE constraint 'FK_UserRights_Users'. The conflict occurred in database 'Office', table 'UserRights', column 'FS_Username'.
The statement has been terminated.

Does anyone know how to resolve this problem without loosing constrains and triggers ? (If I turn off 'Enable relationship for INSERT and UPDATE' option for relationship, things will work fine, but than I can make inconsistent data in UserRights table).

tnx a lot,
DejanSorry, second trigger should be:

CREATE TRIGGER DeleteUserRights ON Users
FOR DELETE
AS
BEGIN
DELETE UserRights WHERE FS_Username IN
(SELECT FS_Username FROM deleted)
END

This is just the correct trigger, it doesn't solve the problem in hand...

Dejan

Sunday, 19 February 2012

Confirming the right hyperlink

Hi,
We create rdl files which contains <Hyperlink> elements. The
value for hyperlink is an expression build using report parameters,
field parameters etc and also contains calls to custom assemblies
eg : <Hyperlink>=Parameters!Param1.Value + CustomAssemblyCall + Fields!
someField.Value<Hyperlink>
When this report is rendered by HTML Rendering extension(by specifying
HTML4.0 in the format string passed to render() method) this
<Hyperlink> element is converted to href attribute of the <a> tag.
We have a scenario where we want to test whether this href url
generated is correct or no without deploying the rdl file on the
report server.
Is there any way to pass the xml file and find out what would be href
value when the <Hyperlink>
element is parsed by the report server ?
Any report server dll's which can directly be used ?
Thanks in advance,Can anyone guide me on this

Friday, 10 February 2012

Configure SQL Server Email

Hello, everyone:

I want to create a stored procedure to execute validation and send results to clients. When I did testing to send email by:

EXEC master..xp_sendmail
@.recipients='you@.you.com',
@.message = 'Validation Finished',
@.subject = 'foo was fired.'

I got error loke:

Server: Msg 18030, Level 16, State 1, Line 0
xp_sendmail: Either there is no default mail client or the current mail client cannot fulfill the messaging request. Please run Microsoft Outlook and set it as the default mail client.

How to configure Outlook and SQL Server Email next?

Thanks

ZYTI have better luck with the following:

http://sqldev.net/xp/xpsmtp.htm

It doesn't require mapi, and doesn't Outlook to be installed or configured on the server. Just install and use.

Bill