Connecting To An SQL Named Pipe Alias

Jul 26, 2007



Hi All , I have been racking my head on this for the last two days and really it should be a no brainier. Anyways I can only assume that I€™m missing something here but...



In a nut shell I am attempting to connect to a new SQL Alias that i have created by simply adding the following in the client network utility

Current SQL server name DASQL

Default instance



Alias Name: TASQL

Server Name: DASQL

Pipe Name: \DASQLpipesqlquery



I can connect the new alias via the local (server consol) yet when i attempt to connect remotely it times out as if it can't find the server.



Any Thought?

Thanks

View 5 Replies


ADVERTISEMENT

Linked Server With Named Pipe

Sep 29, 2007



Linked server is created as (from SQL 2005 to SQL 2000)


EXEC sp_addlinkedserver @server = @SPKServerName,

@srvproduct = '',

@provider = 'SQLOLEDB',

@datasrc = @SPKdatasrc //np:remoteservername


exec sp_serveroption @server = @SPKServerName

, @optname = 'rpc'

, @optvalue = 'on'

exec sp_serveroption @server = @SPKServerName

, @optname = 'rpc out'

, @optvalue = 'on'

exec sp_serveroption @server = @SPKServerName

, @optname = 'data access'

, @optvalue = 'on'


when asp.net applicaiton hits the Stored Procedure, it uses Linked server to get data from remote server. It fails with exception message

OLE DB provider "SQLNCLI" for linked server "ServerName" returned message "Login timeout expired".
OLE DB provider "SQLNCLI" for linked server "ServerName" returned message "An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections.".
Msg 5, Level 16, State 1, Line 0
Named Pipes Provider: Could not open a connection to SQL Server [5].


Any idea how to solve this?

Regards,

View 7 Replies View Related

Help!!!Cannot Connect To Remote Sql Server By Named Pipe

May 6, 2007

Hi, all,



I installed sql server 2005 express on a server with window server 2003 SP1 and tried to connect it from a remote computer with vista installed.

I have already enabled named pipe and tcp/ip protocol for instance SQLEXPRESS on the server, and started sql server browser as well. Of course, I also enabled local and remote connection using tcp/ip and named pipe by sql server surface area configuration tool.

In this senario, I can connect to server locally or remotely by tcp/ip and connect to server locally by named pipe(c>sqlcmd -S \192.168.1.100pipeMSSQL$SQLEXPRESSsqlquery -U * -P *), but I can not connect to server remotely using same command line.

According to some article from MSDN, it might be caused by firewall, but I already disabled my firewall. Moreover, I used tools like makepipe.exe and readpipe.exe, they didn't work too. Why the 2 computers can't create connection using named pipe protocol.



Thanks.



Johonson Chan



View 5 Replies View Related

Why Can I Nolonger Backup My Database To A Named Pipe?

Jan 22, 2008

Why can I no longer backup a database to a named pipe in SQL Server 2005? Named pipes are much easier to work with than VDI (and VDI is covered in obscurities). I really want the ability to dump a database to a named pipe reimplementation if it€™s been removed. I hate to think of the cost of redesigning our backup applications. Can I force a PIPE dump device into the sysdevices table? Any suggestions? (and DO NOT tell me to use VDI, as it is absurdly cumbersome and loaded with unnecessary dependencies)

BACKUP DATABASE <name> TO PIPE=\.pipeMyPipeName

View 6 Replies View Related

SqlServer Connection String For JDBC When Using Named Pipe

Apr 27, 2008

Hi!

I'm writing a java application that queries sqlserver 2005 (and 2000). In case the sql browser service is stopped I need to use the named pipe property or the port property, right?
But how could the program know at runtime what is the port and what is the pipe name? And how should a connection string to sqlserver 2005 (and 2000) that includes named pipe, look like?

Thanks!

View 4 Replies View Related

Named Pipe Provider/Linked Server Connection Error

Aug 21, 2007

Hello, everyone!

I'm currently having an issue with a linked server. Here's the surrounding information:

A) I have a clustered SQL Server 2005 Instance (A) and a SQL Server 2000 instance (B).
B) There is a linked server on A to B. When I set it up, I did run the fix to ensure A could talk to B (There was an issue with communication between 2005 and 2000 servers). It has been there since I installed A, and has worked fine.. Until last week.
C) This linked server uses static credentials to connect to B.
D) Named Pipes are enabled on both servers to listen to both connections on both A and B in cliconfg. So A has a named pipe listening for B, and B has a named pipe listening for A.
E) A has a view that looks at a table on B - It's a table view, very simple, just pulls in all the data from the table on B.


So, I go to do a select statement from the view, connected as a user other then 'sa'. I then get the error:

Named Pipes Provider: Could not open a connection to SQL Server Linked Server
Error Source: ncli Client (Paraphrasing, didn't copy that down, but it was the ODBC connector)

Well, that's odd. It's been working fine for months now..

I then go and connect as sa on A to query B. It works! Mind you, absolutely NO QUERY from A to B will run again until I run SOME kind of query has been run as sa on A.

Mind you, this is not a credential issue. Every user who connects to the linked server to B uses a stored credential that is DBO to the database on B. The same User Name and Password exists on both A and B.

Also of note, I check the activity monitor. There's a process that is "dormant" every time I run a query against the view. The details of this connection are:

sp_reset_connection;1

My question is, why is it resetting the connection on B when being queried from A? Why is it "all of a sudden" a problem? Are there any changes that coudl ahve been made that would cause this?

Any help with this confusing issue would be appreciated.

Thanks!

View 1 Replies View Related

JDBC Sample Code Using Named Pipe And SQLServer 2005 Driver?

Nov 22, 2006

Hi,

Does anybody have a working Java code sample that connects to an SQLServer 2005 database on a remote host, via the default named pipe, from a client using the SQLServer 2005 JDBC driver? Could you post it, or a pointer to it?

I've gotten java.sql DriverManager.getConnection() to work fine with TCP/IP connections before. But I'm a newbie with named pipes, and unclear on how the connection string/properties are different. I've tried to piece it together from multiple docs and threads, but haven't found sample code that quite fits my situation. I think a simple working example would best clarify the syntax.

The server is not using SQL Express. Most SQLServer configuration options are defaults; the named pipes protocol is enabled.

Thanks

View 3 Replies View Related

Named Pipes Under Alias

Feb 17, 2004

I have a SQLSERVER INSTANCE A, to which I want to connect from a Client as TEST, using the SQL Server alias functionality under the client network utility program. The alias is working fine with the TCPIP connection but it fails when I try to connect to the SQL Server using the named pipes. In my case I'm trying to connect to a named instance of SQL Server 2000 using the following pipe: \servernamepipemssql$instancenamesqlquery

Any help?

View 2 Replies View Related

Alias For SQL 2000 Named Instance

Aug 12, 2002

We have a two node activepassive SQL Server 2000 cluster SP2 running on Window 2000 advanced server SP2. Everything is working fine including failover. Today we migrated over our 7.0 databases to the SQL cluster and they attached fine and upgraded fine but we would like to shutdown the 7.0 server and bring up the clustered SQL Server under the old name. We will be running 3 instances of SQL Server 2000 on the Cluster so at least 2 of these will be named instances like this: "Virtual serverinstance". Is it possible to create an alias for this SQL Server so that we could access the server under the original name of the server???
Thanks!!!
Bruce

View 1 Replies View Related

Provider: Named Pipe Provider, Error: 40 - Could Not Open Connection To SQL Server

Apr 14, 2007

After I installed the various service packs via Windows Update, my WindowsForms application can no longer connect to the server.



The error message is:



provider: Named Pipe Provider, error: 40 - Could not open connection to SQL server.



However, the Reporting Services work just fine.



Please help.

View 1 Replies View Related

SQL 2012 :: Setup A Client Alias To Connect To A Named Instance On Another Server?

Jul 23, 2014

I am trying to setup a client alias to connect to a named instance on another server.

TITLE: Connect to Server
------------------------------
Cannot connect to fred.
------------------------------

ADDITIONAL INFORMATION:

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) (Microsoft SQL Server, Error: 53)

[URL]

The network path was not found

------------------------------
BUTTONS:
OK
------------------------------

I have set up the alias on the server and as expected it works. On the client side I have used the SQL Server Client Network Utility to configure the client side alias but no luck

I am using TCP/IP with a specific port ..

By the way the SQL is SQL Server 2012 Ent and the O/S is Windows 2012 R2 minshell

View 9 Replies View Related

Connecting To SQLServer 2000 Using DNS Alias

Jul 20, 2005

Hi all,I have to move my SQlServer 2000 instance from one server'actual_server' to another server 'new_server'.But, the different applications connecting to the actual server can'teasily change their connections address. i.e it connect to'actual_server' server only.Is there a risk to declare a DNS alias 'actual_server' pointing to'new_server' ?So I could move my databases from 'actual_server' to 'new_server'.Is the modification transparent to the client ?I especially thinking about wins...TYIACordiallyRJP

View 2 Replies View Related

SQL 2012 :: Can't Access Linked Server When Connecting Via Alias

May 27, 2014

As a database developer, I have so many databases that I "own" scattered across various servers that it''s getting difficult to remember where all of my databases reside. It doesn't work that the DBAs have taken to some very hard to remember server naming conventions.

I was going to create aliases via the configuration manager, but it turns out the DBAs overwrite my entries each night with THEIR aliases and they won't add any for my use.

So I decided to simply add some records to my host file so that instead of having to connect to "SERVER-AD_DADF-DAFDASS" I can just use "CustomerA".

This solution seems to work until I tried to access a linked server. If I connect to the main server via it's actual name, I can hit the remote/linked server with no issue. However, if I connect to the main server using it's alias, connection to the remote/linked server fails with: Login failed for user 'NT AUTHORITYANONYMOUS LOGON'.

The linked server is set up to use current security context and I'm not logging into the alias any differently that I do when using the actual server name.

View 9 Replies View Related

Connecting To Named Instance

Jan 3, 2004

Hi,

How can i connect to Named Instance of MSDE on remote server from Enterprice Manager in my local computer ?

Instance name is Helm

I can connect inside server like

osql -S -E .Helm

But how i access from remote machine using Enterprice Manager ?

Regards,

Yujin Boby

View 1 Replies View Related

Connecting To Named Instance Of SQL Server

Jun 16, 2008

We have installed SQL 2000 SP4 on Windows 2000 Server. We created named instances on the SQL server.
When trying to connect to named instances from a remote sql client which is on windows 2000 and windows 2003, its throwing an error message saying that remote connections are disabled.
But, remote connections are enabled on the SQL server.
After changing the component services settings on windows 2003 where sql client is installed, we are able to connect to named instances.
But, after applying the same settings on another windows 2003 machine, we are unable to connect to the same instances.


We have another machine where we installed SQL 2005 on windows 2003 SP1. When trying to connect to named instances from any remote client, its throwing an error message saying that remote connections are disabled. But, remote connections are enabled in SQL server settings. We tried connecting to the instances by changing the component services settings but still we are facing the same issues.


Can you please help me on above issues?

View 3 Replies View Related

Odd Issue Connecting To A Named Instance.

Aug 16, 2006

Hi everyone,



Please forgive me for the newbie question, I've done almost all of my DBA work on Oracle(on UNIX so I'm learning alot of AD stuff too) and am new to MS SQL Server.

I've got a SQL 2005 standard server that I'm trying to get to act as a publisher for a SQL 2005 Express instance, and I think I've narrowed down my problem to a connection issue.

(FYI, the Publisher works fine with another 2005 Standard server)

When I try to connect from the standard server to the express server using 'XYZSQLEXRESS' as my server name, it fails stating that it couldn't find the service, but I can connect just fine if I use 'XYZ' as the server name.

I think this is why I'm having trouble getting replication going as the replication wizard tells me that I have to connect via 'XYZSQLEXPRESS' in order to run the replication scripts.

Can anyone point me to the correct documentation to resolve this problem? Everything was easy-mode DBA work until we tried to add SQL Express to the mix, and I'm sort of running out of time on this one.



Thanks for any help!





View 5 Replies View Related

Data Warehousing :: How To Skip PIPE (comes As Data) In PIPE Delimited Flat File

May 13, 2015

I have a problem with a PIPE "|" delimited flat file. I have a column "Description" in which we get a string in which we have PIPE "|" as data. How we can skip this and load it as a data into the column Description.

View 7 Replies View Related

Connecting To SQL Server 2000 Named Instances

Aug 29, 2006

I have the following problem;

I fully understand that to connect to a named instance of SQL Server you need to use the ServerNameSQLInstanceName. The problem I have is that I have a SQL Server in a different zone. I can connect to the Default instance by IP Address or the ServerName.zone.domain.org. (e.g. MySQLServer.zone1.mydomain.org).

However, the same thing does not work for the Named Instance. It seems to be named instance or nothing.

How can I connect to this named instance across network zones?:S

View 2 Replies View Related

Connecting To SQL Server 2000 Named Instances

Jan 9, 2007

We are having all kinds of issues with named instances for SQL 2000.

I am trying to connect to a SQL Server 2000 named instance on a different subnet and get an error. I cannot connect with ODBC or our web app.

I am using the port number for the alias that I created in the SQL Client Utility. We can connect to default instances without a problem, but not the named instances.

The SQL Server is 2000 build 2040 (Service pack 4 with a hot fix.) The server is listening on port 1223. In the ODBC connection I click on the Network Config and create an alias with the named instance such as SQLVSNSQLNI and specify port 1223. I have also tried adding the port to the connection string in the ASP include file (SQLVSNSQLNI,1223). If I do the same thing with a default instance on the network, both the app and ODBC work fine. It is only when I use a named instance.

Very frustrated. Thanks for any help you can provide

View 2 Replies View Related

SQL Server 2008 :: Named Instance And Specified Port Not Connecting?

Feb 14, 2013

I have opened up a port on a remote SQL instance and can see that the port is LISTENING when using the PortQry tool. I have also set the TCP port in the TCP/IP properties in the IPAll section for that instance, yet I am unable to connect and get an error of

Connection Timeout Expired. The timeout period elapsed while attempting to consume the pre-login handshake acknowledgement. This could be because the pre-login handshake failed or the server was unable to respond back in time. The duration spent while attempting to connect to this server was - [Pre-Login] initialization=1; handshake=14998; (.Net SqlClient Data Provider)

I have done this on other instances, although they were default instances, and it has always worked fine.

View 9 Replies View Related

IP Works But Not Named Pipes, Connecting To SQL 2005 (SQL Auth)

Jul 29, 2007

I have SQL 2005 Std Edition, Mixed Security, and remotely connecting by TCP/IP works great.

Named Pipes (and the SQL Native Client) is the only issue.


The problem _appears_ to be that I'm not authenticated under the SQL Machine; however, I'm not attempting to use Windows Authentication, I'm strictly using SQL, so I do not understand why I'm having a problem.


My reasoning for the above conclusion, is that the command "net use \[server_name]ipc$" will allow me to connect to the server, and Named Pipes will begin working. Again, remember that I'm only trying to access named pipes using SQL Authentication.


I've read through everything on the forum and tried everything I could find. Below are the answers from the most common suggestions posted here:

------------------------------------------------------------------------
Version: SQL Server 2005 - 9.00.1399.06 (Intel X86)
This is the Default & Only Instance of SQL 2005, named: MSSQLSERVER
------------------------------------------------------------------------

1. The error message with the SQL Native driver (v 9.00.3042):
Error 1326, SQL State 08001
[Microsoft][SQL Native Client]Named Pipes Provider: Could not open a connection to SQL Server [1326]


2. The error messgae with the ODBC SQL driver (v 03.85.1117):

Error 1326, SQL State 01000
[Microsoft][ODBC SQL Server Driver][Named Pipes]Connection Open (Connect())

Connection Failed: SQL Error 17, State 08001
[Microsoft][ODBC SQL Server Driver][Named Pipes]SQL Server does not exist or access denied.


3. Local Connection on Win2003 Server works fine for IP & Named Pipes


4. Remote Connection using SQL Authentication
WORKS for IP, does not work for Named Pipes


5. Absolutely *no firewalls* or blocked ports are being used on either machine


6. Configuration Manager & Surface Area Config -- both enabled TCP/IP & Named Pipes
Currently listening on ALL IP's. The LOG reports:

Server is listening on [ 'any' <ipv4> 1433].
Server named pipe provider is ready to accept connection on [ \.pipesqlquery ].
Server is listening on [ 127.0.0.1 <ipv4> 1434].
Dedicated admin connection support was established for listening locally on port 1434.


7. Can telnet to server on 1433


8. Status of NETSTAT on server:

C:...>netstat -ano|findstr 1433
TCP 0.0.0.0:1433 0.0.0.0:0 LISTENING 656
C:...>netstat -ano|findstr 1434
TCP 127.0.0.1:1434 0.0.0.0:0 LISTENING 656
UDP 0.0.0.0:1434 *:* 2544


9. Tried both named instance and unnamed instance (although I'm not sure
if I'm passing the 'named' instance properly):

Tested: \MYSERVERpipesqlquery
Tested: \MYSERVERpipeMSSQL$MSSQLSERVERsqlquery
(although the named instance doesn't work on the server either)


10.I've setup an alias for the named pipe connection. This was based on a suggestion
posted here, but didn't work.


11.I've removed the shared-memory protocol, on another suggestion here, but no luck.


12.If I execute "net use \[server_name]ipc$" it asks for credentials and if I
enter the server credentials I have no problem with executing that command.
In other words the logged-on user is not an authenticated member of the server;
however, I'm not attempting to use windows authentication, I'm using
SQL Authentication.

------------------------------------------------------------------------

Thank you in advance for any suggestions,
Rusten

View 5 Replies View Related

Problem Connecting To SS2K5 Named Instance Using Client Tools

Aug 9, 2007

Hi,

The problem I have is this:


I have installed SQL Server 2005 Enterprise Edition on a W2K3 server that already has a SQL Server 2000 default instance installed. The installation appears to be a success. The problem is that having installed the client tools, and trying to connect, I get the following error message in a dialog:


"Cannot connect server SERVERNAMEINSTANCENAME
An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating
Server/Instance Specified)(Microsoft SQL Server)"


The funny thing is that I can connect to the SQL Server 2000 default instance that is on that server.
So it's obviously not a connection problem per se at my end i.e. bad dns etc which might stop me resolving the server name.


Googling for this error text gives the following advice on various web sites:


1. Check that the remote server allows connections.


It does, as other colleagues in my team have successfully installed the tools and can connect with no problems.


2. Check that the SQL Browser service is running.


It is, as without this running, my colleagues would not be able to connect either.


3. Open SQL Server Configuration Manager. Select "SQL Server 2005 Network Configuration | Protocols for MSSQLSERVER" then enable the protocols you need.


The required protocol (TCP/IP) is enabled. Named pipes is also enabled, although I don't think that we're using that. And shared memory is also enabled by default.


4. Open the firewall and add exceptions for sqlbrowser.exe or UDP port
1434


There is no firewall running at either end of the connection and as mentioned I can connect to the SS2K default instance.


5. Make sure that the server machine is reachable.



I can connect to the SS2K default instance so it must be reachable. I can't see that I would need to change any configuration settings as my colleagues are using exactly the same default settings for their connections and they work fine.


The only thing that I have done differently is that I originally installed the client tools using someone else's privileged account as I didn't have admin rights on my box. The client tools didn't work, so I got admin rights to my box, uninstalled the client tools and then reinstalled them using my account. Still no luck. Not sure if something is still hanging around after the uninstallation that would cause me a problem.

To help, I've also filled out the following questionnaire:

[1] Client side:
> What is the connection string in you app or DSN?
There isn't one. I'm trying to connect from the SQL Server Management Studio | 'Connect to Server' dialog.
> If client fails to connect, what is the client error messages?
"Cannot connect server Y
An error has occurred while establishing a connection to the server. When connecting to SQL Server
2005, this failure may be caused by the fact that under the default settings SQL Server does not
allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating
Server/Instance Specified)(Microsoft SQL Server)"
Is the client remote or local to the SQL server machine? Remote
Can you ping your server? YES
Can you telnet to your SQL Server? YES
What is your client database provider? [SNAC | MDAC | ADO.NET1.0 | ADO.NET2.0| other (please specify] N/A
What is your client application? SQL Management Studio
Is your client computer in the same domain as the Server computer? Different domains
What protocol the client enabled? [Shared Memory | TCPIP | Named Pipes]. All 3 protocols are enabled
Do you have aliases configured that match the server name portion of your connection string? No
Do you select force encryption on server and/or client? No

[2] Server side:
What is the MS SQL version? SQL Server 2005
What is the SKU of MS SQL? Enterprise
What is the SQL Server Protocol enabled? [Shared Memory | TCPIP | Named Pipes ]. All 3
Does the server start successfully? YES. Other people can connect to the same instance.
If SQL Server is a named instance, is the SQL browser enabled? YES
What is the account that the SQL Server is running under? Domain Account
Do you make firewall exception for your SQL server TCP port if you want connect remotely through TCP provider? N/A. Firewall not running.
Do you make firewall exception for SQL Browser UDP port 1434? N/A. Firewall not running.
What tool or Application are you using to connect to SQL Server SQL Server Management Studio

[3] Platform:
What is the OS version? Windows 2003 (Server side), Windows XP Pro Version 2002 SP 2
Do you have third party antivirus, anti-spareware software installed? Symantec AntiVirus

[4] Misc:
If you have certificate configuration issue: N/A


Has anybody else come across this problem, as I've run out of ideas.


Many thanks,

View 1 Replies View Related

Intermittent Login/General Network Error Connecting To A Named Instance Of SQL 2000

Mar 27, 2008

Greetings,

I have a VB 2003 .NET application that I wrote for a customer that connects to a named instance of SQL 2000. Until recently it has been working fine. Lately the program either pops a timeout failure within a few seconds or a general network error. I've increased the connection timeout settings to 90 seconds but the error still pops within a few seconds. I'm thinking something has changed in the environment that prevents a clean connection to the named instance of SQL server.

How should this issue be troubleshoot to determine the problem and what areas need to be looked at?

Thanks

View 3 Replies View Related

Can Create Alias Server1DBInstance1 On Server3DBInstance3 And Assign Objects To That Alias

Nov 24, 2015

We will be moving 2 different databases (SS2005 & SS2008) to a new SS2014 SQL Server.  Currently our codes looks something like Server1DBInstance1... & Server2DBInstance2... Is it possible to move the objects from these 2 instances to Server3DBInstance3 and then use an alias to reference the objects?  Or does Server3 need to have DBInstance1 & DBIstance2?  Basically, is the alias just for the database or for the instance too?  Can I create an alias "Server1DBInstance1' on Server3DBInstance3 and assign objects to that alias?

View 16 Replies View Related

An Error Has Occurred While Establishing A Connection To The Server. When Connecting To SQL Server 2005, This Failure May Be Caused By The Fact That Under The Default Settings SQL Server Does Not Allow Remote Connections. (provider: Named Pipes Provide

Jan 24, 2008

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider,

View 2 Replies View Related

An Error Has Occurred While Establishing A Connection To The Server. When Connecting To SQL Server 2005, This Failure May Be Caused By The Fact That Under The Default Settings SQL Server Does Not Allow Remote Connections. (provider: Named Pipes Provide

Apr 10, 2008

Hi,I have SQL Server Express Edition. I tried working out some ASP.NET Labs in my local system. Here is the link of the Virtual Lab which I tried. http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?EventID=1032286906&EventCategory=3&culture=en-US&CountryCode=USI recieve this error in my local system. An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)I tried working out solutions from various websites. But the no solution is effective. Could anyone help me in solving this issue.  

View 1 Replies View Related

SQL Express - When Connecting To SQL Server 2005, This Failure May Be Caused By The Fact That Under The Default Settings SQL Server Does Not Allow Remote Connections. (provider: Named Pipes Provider, Error: 40 - Could Not Open A Connection To SQL Serve

Apr 10, 2008

Hi,I have SQL Server Express Edition. I tried working out some ASP.NET Labs in my local system. Here is the link of the Virtual Lab which I tried. http://msevents.microsoft.com/CUI/WebCastEventDetails.aspx?EventID=1032286906&EventCategory=3&culture=en-US&CountryCode=USI recieve this error in my local system. An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)I tried working out solutions from various websites. But the no solution is effective. Could anyone help me in solving this issue.  

View 3 Replies View Related

Connecting To Sql Server 2000 On Godaddy Error: (provider: Named Pipes Provider, Error: 40 - Could Not Open A Connection To SQL Server)

Mar 5, 2007

Facts:1. I am using my account on Godaddy trying to connect to my sql server db.2. I can get into my db using user id and password.3. Godaddy's help file shows this for a connection string: connectstr = "Driver={SQL Server};SERVER=" & db_server & ";DATABASE="
&db_name & ";UID=" & db_username & ";PWD=" &
db_userpassword4. My connection string: "Server=whsql-v09.prod.mesa1.secureserver.net;uid=dbasolutions;pwd=***;database=DB_87972;"  & _                    "Trusted_Connection=False providerName=System.Data.SqlClient"{password **** out}5. Get error message  An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) I tried to email Godaddy's help desk with this information. There first response: We do not allow remote connections to our sql server database.There second response was to read the help file!Does anybody have any suggestions?  Thanks in advance,bswanson     

View 1 Replies View Related

No Process Is On The Other End Of The Pipe

Apr 9, 2007

Hello all, I have question regarding the error message that I'm getting above. I have a program written in .NET that is suppose to traverse through a database and retrieve various records and then write a summary record. The code worked without issue. The database the used to hold the data was a SQL 7.0. However, recently I moved the server over to SQL 2005. Since that time I have been getting the following error:

Description: [Microsoft][SQL Native Client]Named Pipes Provider: No process is on the other end of the pipe.

ramdomly throughout the execution of the program. It doesn't happen on record and is intermittent when it occurs.

Here is the code that is having issues any help would be appreciated.

Thanks
Mike Gisonda



Dim mreleaseqty As Double
Dim mmakeqty As Double
Dim k As Integer
Dim mbackorderqty As Double
Dim mOnOrder As Double
Dim mOnHand As Double
Dim mMaximumqty As Double
Dim mMinimumQty As Double
Dim muomfactor As Double
Dim mSafetyStockQty As Double
Dim mQtyInTransit As Double
Dim mQtyAllocatedWip As Double
Dim mQtyAllocated As Double

Dim cnLean As New ADODB.Connection
Dim cnSyspro As New ADODB.Connection
Dim cnLean2 As New ADODB.Connection


Dim cmdPullItems As New ADODB.Command 'command to retrieve pull items
Dim cmdWHTotals As New ADODB.Command 'command to get combined warehouse totals
Dim cmdUpdatePull As New ADODB.Command
Dim cmdBkOrd As New ADODB.Command
Dim cmdInvMst As New ADODB.Command
Dim cmdInitPull As New ADODB.Command 'command to clean our old pull data

Dim prmStockCode As New ADODB.Parameter 'parameter to supply stockcode.

Dim rsPullItems As New ADODB.Recordset 'recordset to hold pull items.
Dim rsWHTotals As New ADODB.Recordset 'recordset to hold warehouse records
Dim rsBkOrd As New ADODB.Recordset
Dim rsInvMst As New ADODB.Recordset
Dim rsSalesOrders As New ADODB.Recordset
Dim rsWipMaster As New ADODB.Recordset



Dim mPullSQL As String
Dim mWHSql As String
Dim mBackOrderStr As String
Dim mInvSQL As String
Dim mStockCode As String
Dim mSalesSQL As String
Dim aBackOrderRec As Array
Dim mReqDate
Dim mShipDate As Date
Dim mcol As Integer
Dim mNewVal As Double
Dim mWipSql As String
Dim mAdjAmt As Double
Dim mStockStatus As Integer
Dim mBackOrder As Double
Dim mBackLate1 As Double
Dim mBackLate2 As Double
Dim mBackLate3 As Double
Dim mBackLate4 As Double
Dim mWeeklyStDev As Double
Dim mWeeklyUsage As Double

Dim mBackLog1 As Double
Dim mBackLog2 As Double
Dim mBackLog3 As Double
Dim mBackLog4 As Double
Dim mBackLog5 As Double
Dim mBackLog6 As Double
Dim mBackLog7 As Double
Dim mBackLog8 As Double
Dim mBackLog9 As Double
Dim mBackLog10 As Double
Dim mBackLog11 As Double
Dim mBackLog12 As Double

Dim mLEAN_BACKORDER_BFLAG As Integer
Dim mLEAN_LATE1_BFLAG As Integer
Dim mLEAN_LATE2_BFLAG As Integer
Dim mLEAN_LATE3_BFLAG As Integer
Dim mLEAN_LATE4_BFLAG As Integer
Dim mLEAN_BACKLOG1_BFLAG As Integer
Dim mLEAN_BACKLOG2_BFLAG As Integer
Dim mLEAN_BACKLOG3_BFLAG As Integer
Dim mLEAN_BACKLOG4_BFLAG As Integer
Dim mLEAN_BACKLOG5_BFLAG As Integer
Dim mLEAN_BACKLOG6_BFLAG As Integer
Dim mLEAN_BACKLOG7_BFLAG As Integer
Dim mLEAN_BACKLOG8_BFLAG As Integer
Dim mLEAN_BACKLOG9_BFLAG As Integer
Dim mLEAN_BACKLOG10_BFLAG As Integer
Dim mLEAN_BACKLOG11_BFLAG As Integer
Dim mLEAN_BACKLOG12_BFLAG As Integer

Dim mBFlagValue As Integer
Dim mFileNum As Integer
Dim mTrnFileNum As Integer
Dim mtest As String
Dim mCountOfRecords As Long
Dim mPullCount As String
Dim rsPullcount As ADODB.Recordset
Dim mCurRecordCount As Long

Dim mWipAllSQL As String
Dim rsWipAll As New ADODB.Recordset


'On Error GoTo ehbtnUpdateLean_Click
'open connection to springdesign
With cnLean
.ConnectionString = "DSN=SPRINGDESIGN;UID=sa;PWD="
.Open()
End With
With cnLean2
.ConnectionString = "DSN=SPRINGDESIGN;UID=sa;PWD="
.Open()
End With

'open connection to syspro
With cnSyspro
.ConnectionString = "DSN=COMPANYM;UID=sa;pwd="
.CommandTimeout = 300
.Open()
End With
btnUpdateLean.Enabled = False
Me.Cursor = Cursors.WaitCursor

**
Bunch of code to set up commands and select statements
**
'Initial command that will update the pull records as they are being processed.
With cmdUpdatePull
.let_ActiveConnection(cnLean)
.CommandType = ADODB.CommandTypeEnum.adCmdStoredProc
.CommandText = "sp_MX_Daily_UpdateMRPData"
.CommandTimeout = 300
.Parameters.Refresh()
End With

**
More Code
**

Try
rsPullItems.CursorLocation = ADODB.CursorLocationEnum.adUseClient
'Get all the pull items.
'rsPullItems = cmdPullItems.Execute
rsPullItems.Open(mPullSQL, cnLean2)
rsPullItems.ActiveConnection = Nothing

Catch ex As Exception
mtest = "Exception Message: " & ex.Message & vbCrLf & "SQLStatement: " & cmdPullItems.CommandText
LogError("", mtest)
rsPullItems = Nothing

End Try

Try
'Initialize debugging and transaction files.
mFileNum = FreeFile()
FileOpen(mFileNum, "MXtestdebug.txt", OpenMode.Output, OpenAccess.Default, OpenShare.Shared)
PrintLine(mFileNum, "Start " + Format(Now, "hh:mms"))
mTrnFileNum = FreeFile()
FileOpen(mTrnFileNum, "MXTrndebug.txt", OpenMode.Output, OpenAccess.Default, OpenShare.Shared)
Catch ex As Exception
End Try


mCurRecordCount = 0
'Start working.
If IsNothing(rsPullItems) = False Then
Do While rsPullItems.EOF = False
mCurRecordCount += 1


'Initialize parameter values
cmdUpdatePull.Parameters("@stock_code").Value = mStockCode
cmdUpdatePull.Parameters("@MINIMUM_QTY").Value = 0
cmdUpdatePull.Parameters("@MAXIMUM_QTY").Value = 0
cmdUpdatePull.Parameters("@SAFETYSTOCKQTY").Value = 0

cmdUpdatePull.Parameters("@ON_HAND").Value = 0
cmdUpdatePull.Parameters("@ON_ORDER").Value = 0
cmdUpdatePull.Parameters("@BACKORDER_QTY").Value = 0
cmdUpdatePull.Parameters("@MAKE_QTY").Value = 0
cmdUpdatePull.Parameters("@RELEASE_QTY").Value = 0

cmdUpdatePull.Parameters("@LEAN_BACKORDER").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_LATE1").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_LATE2").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_LATE3").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_LATE4").Value = 0.0

cmdUpdatePull.Parameters("@LEAN_BACKLOG1").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG2").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG3").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG4").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG5").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG6").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG7").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG8").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG9").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG10").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG11").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG12").Value = 0.0

'Initial flags used to determine if the individual sales order dates are
'before or after the request date.
cmdUpdatePull.Parameters("@LEAN_BACKORDER_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_LATE1_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_LATE2_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_LATE3_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_LATE4_BFLAG").Value = 0

cmdUpdatePull.Parameters("@LEAN_BACKLOG1_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG2_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG3_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG4_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG5_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG6_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG7_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG8_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG9_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG10_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG11_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG12_BFLAG").Value = 0


cmdUpdatePull.Parameters("@LEANMFG_STOCKSTATUS").Value = 0

**
**
Try
'Get warehouse totals
rsWHTotals = New ADODB.Recordset
rsWHTotals = cmdWHTotals.Execute
Catch ex As Exception
mtest = "Exception Message: " & ex.Message & vbCrLf & "SQLStatement: " & cmdWHTotals.CommandText
LogError(mStockCode, mtest)
rsWHTotals = Nothing

End Try

**
**
If IsNothing(rsWHTotals) = False Then
If rsWHTotals.EOF = False Then 'If there are values in the warehouse query.
**
BUNCH MORE CODE
**
cmdUpdatePull.Parameters("@stock_code").Value = mStockCode
cmdUpdatePull.Parameters("@MINIMUM_QTY").Value = mMinimumQty
cmdUpdatePull.Parameters("@MAXIMUM_QTY").Value = mMaximumqty
cmdUpdatePull.Parameters("@SAFETYSTOCKQTY").Value = mSafetyStockQty

cmdUpdatePull.Parameters("@ON_HAND").Value = mOnHand
cmdUpdatePull.Parameters("@ON_ORDER").Value = mOnOrder
**
cmdUpdatePull.Parameters("@BACKORDER_QTY").Value = mbackorderqty
mmakeqty = (mMaximumqty - mOnHand)
If mmakeqty > 0 Then
cmdUpdatePull.Parameters("@MAKE_QTY").Value = mmakeqty
Else
cmdUpdatePull.Parameters("@MAKE_QTY").Value = 0
End If



'init varables.

cmdUpdatePull.Parameters("@LEAN_BACKORDER").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_LATE1").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_LATE2").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_LATE3").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_LATE4").Value = 0.0

cmdUpdatePull.Parameters("@LEAN_BACKLOG1").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG2").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG3").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG4").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG5").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG6").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG7").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG8").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG9").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG10").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG11").Value = 0.0
cmdUpdatePull.Parameters("@LEAN_BACKLOG12").Value = 0.0
mBackOrder = 0.0
mBackLate1 = 0.0
mBackLate2 = 0.0
mBackLate3 = 0.0
mBackLate4 = 0.0
mBackLog1 = 0.0
mBackLog2 = 0.0
mBackLog3 = 0.0
mBackLog4 = 0.0
mBackLog5 = 0.0
mBackLog6 = 0.0
mBackLog7 = 0.0
mBackLog8 = 0.0
mBackLog9 = 0.0
mBackLog10 = 0.0
mBackLog11 = 0.0
mBackLog12 = 0.0

'Initiale Binary flags that represent if the ship date is
'before or after the request date.
cmdUpdatePull.Parameters("@LEAN_BACKORDER_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_LATE1_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_LATE2_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_LATE3_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_LATE4_BFLAG").Value = 0

cmdUpdatePull.Parameters("@LEAN_BACKLOG1_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG2_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG3_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG4_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG5_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG6_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG7_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG8_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG9_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG10_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG11_BFLAG").Value = 0
cmdUpdatePull.Parameters("@LEAN_BACKLOG12_BFLAG").Value = 0

mBackOrder = 0.0
mBackLate1 = 0.0
mBackLate2 = 0.0
mBackLate3 = 0.0
mBackLate4 = 0.0
mBackLog1 = 0.0
mBackLog2 = 0.0
mBackLog3 = 0.0
mBackLog4 = 0.0
mBackLog5 = 0.0
mBackLog6 = 0.0
mBackLog7 = 0.0
mBackLog8 = 0.0
mBackLog9 = 0.0
mBackLog10 = 0.0
mBackLog11 = 0.0
mBackLog12 = 0.0

mLEAN_BACKORDER_BFLAG = 0
mLEAN_LATE1_BFLAG = 0
mLEAN_LATE2_BFLAG = 0
mLEAN_LATE3_BFLAG = 0
mLEAN_LATE4_BFLAG = 0
mLEAN_BACKLOG1_BFLAG = 0
mLEAN_BACKLOG2_BFLAG = 0
mLEAN_BACKLOG3_BFLAG = 0
mLEAN_BACKLOG4_BFLAG = 0
mLEAN_BACKLOG5_BFLAG = 0
mLEAN_BACKLOG6_BFLAG = 0
mLEAN_BACKLOG7_BFLAG = 0
mLEAN_BACKLOG8_BFLAG = 0
mLEAN_BACKLOG9_BFLAG = 0
mLEAN_BACKLOG10_BFLAG = 0
mLEAN_BACKLOG11_BFLAG = 0
mLEAN_BACKLOG12_BFLAG = 0

mBFlagValue = 0


**
more Code
**
Try
rsSalesOrders = New ADODB.Recordset
rsSalesOrders.Open(mSalesSQL, cnSyspro)
Catch ex As Exception
mtest = "Exception Message: " & ex.Message & vbCrLf & "SQLStatement: " & mSalesSQL
LogError(mStockCode, mtest)
rsSalesOrders = Nothing
End Try


If IsNothing(rsSalesOrders) = False Then
Do While rsSalesOrders.EOF = False
**
More Code
**
Select Case mcol
Case Is <= -5
cmdUpdatePull.Parameters("@LEAN_BACKORDER").Value = cmdUpdatePull.Parameters("@LEAN_BACKORDER").Value + mNewVal
'Check to see if the bit is marked. If not then mark it.
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKORDER_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKORDER_BFLAG").Value = cmdUpdatePull.Parameters("@LEAN_BACKORDER_BFLAG").Value + mBFlagValue
End If

mBackOrder = mBackOrder + mNewVal

Case Is = -4
cmdUpdatePull.Parameters("@LEAN_LATE4").Value = cmdUpdatePull.Parameters("@LEAN_LATE4").Value + mNewVal
'Check to see if the bit is marked. If not then mark it.
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_LATE4_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_LATE4_BFLAG").Value = cmdUpdatePull.Parameters("@LEAN_LATE4_BFLAG").Value + mBFlagValue
End If

mBackLate4 = mBackLate4 + mNewVal

Case Is = -3
cmdUpdatePull.Parameters("@LEAN_LATE3").Value = cmdUpdatePull.Parameters("@LEAN_LATE3").Value + mNewVal
'Check to see if the bit is marked. If not then mark it.
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_LATE3_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_LATE3_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_LATE3_BFLAG").Value + mBFlagValue)
End If

mBackLate3 = mBackLate3 + mNewVal

Case Is = -2
cmdUpdatePull.Parameters("@LEAN_LATE2").Value = cmdUpdatePull.Parameters("@LEAN_LATE2").Value + mNewVal
'Check to see if the bit is marked. If not then mark it.
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_LATE2_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_LATE2_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_LATE2_BFLAG").Value + mBFlagValue)
End If

mBackLate2 = mBackLate2 + mNewVal

Case -1 To 0
cmdUpdatePull.Parameters("@LEAN_LATE1").Value = cmdUpdatePull.Parameters("@LEAN_LATE1").Value + mNewVal
'Check to see if the bit is marked. If not then mark it.
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_LATE1_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_LATE1_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_LATE1_BFLAG").Value + mBFlagValue)
End If

mBackLate1 = mBackLate1 + mNewVal

Case Is = 1
cmdUpdatePull.Parameters("@LEAN_BACKLOG1").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG1").Value + mNewVal
'Check to see if the bit is marked. If not then mark it.
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG1_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG1_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG1_BFLAG").Value + mBFlagValue)
End If

mBackLog1 = mBackLog1 + mNewVal
Case Is = 2
cmdUpdatePull.Parameters("@LEAN_BACKLOG2").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG2").Value + mNewVal
'Check to see if the bit is marked. If not then mark it.
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG2_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG2_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG2_BFLAG").Value + mBFlagValue)
End If

mBackLog2 = mBackLog2 + mNewVal

Case Is = 3
cmdUpdatePull.Parameters("@LEAN_BACKLOG3").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG3").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG3_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG3_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG3_BFLAG").Value + mBFlagValue)
End If

mBackLog3 = mBackLog3 + mNewVal

Case Is = 4
cmdUpdatePull.Parameters("@LEAN_BACKLOG4").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG4").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG4_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG4_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG4_BFLAG").Value + mBFlagValue)
End If

mBackLog4 = mBackLog4 + mNewVal

Case Is = 5
cmdUpdatePull.Parameters("@LEAN_BACKLOG5").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG5").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG5_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG5_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG5_BFLAG").Value + mBFlagValue)
End If

mBackLog5 = mBackLog5 + mNewVal

Case Is = 6
cmdUpdatePull.Parameters("@LEAN_BACKLOG6").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG6").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG6_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG6_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG6_BFLAG").Value + mBFlagValue)
End If

mBackLog6 = mBackLog6 + mNewVal

Case Is = 7
cmdUpdatePull.Parameters("@LEAN_BACKLOG7").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG7").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG7_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG7_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG7_BFLAG").Value + mBFlagValue)
End If

mBackLog7 = mBackLog7 + mNewVal

Case Is = 8
cmdUpdatePull.Parameters("@LEAN_BACKLOG8").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG8").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG8_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG8_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG8_BFLAG").Value + mBFlagValue)
End If

mBackLog8 = mBackLog8 + mNewVal

Case Is = 9
cmdUpdatePull.Parameters("@LEAN_BACKLOG9").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG9").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG9_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG9_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG9_BFLAG").Value + mBFlagValue)
End If

mBackLog9 = mBackLog9 + mNewVal

Case Is = 10
cmdUpdatePull.Parameters("@LEAN_BACKLOG10").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG10").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG10_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG10_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG10_BFLAG").Value + mBFlagValue)
End If

mBackLog10 = mBackLog10 + mNewVal

Case Is = 11
cmdUpdatePull.Parameters("@LEAN_BACKLOG11").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG11").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG11_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG11_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG11_BFLAG").Value + mBFlagValue)
End If

mBackLog11 = mBackLog11 + mNewVal

Case Is = 12
cmdUpdatePull.Parameters("@LEAN_BACKLOG12").Value = cmdUpdatePull.Parameters("@LEAN_BACKLOG12").Value + mNewVal
If mBFlagValue <> (cmdUpdatePull.Parameters("@LEAN_BACKLOG12_BFLAG").Value And mBFlagValue) Then
cmdUpdatePull.Parameters("@LEAN_BACKLOG12_BFLAG").Value = (cmdUpdatePull.Parameters("@LEAN_BACKLOG12_BFLAG").Value + mBFlagValue)
End If

mBackLog12 = mBackLog12 + mNewVal


End Select
End If
rsSalesOrders.MoveNext()
Loop
rsSalesOrders.Close()
rsSalesOrders = Nothing
End If

**
More Code
**




cmdUpdatePull.Parameters("@LEANMFG_STOCKSTATUS").Value = mStockStatus


**
More Code
**

Else
cmdUpdatePull.Parameters("@stock_code").Value = mStockCode
End If
rsWHTotals.Close()
rsWHTotals = Nothing
Else 'rswhtotal is nothing
cmdUpdatePull.Parameters("@stock_code").Value = mStockCode
End If 'rswhtotal is nothing


'Update the record in DesignLean
Try
*********
This is where it fails
*********
cmdUpdatePull.Execute()

Catch ex As Exception
mtest = "ERROR executing cmdupdatepull" & vbCrLf & "Exception Message: " & ex.Message & vbCrLf
LogError(mStockCode, mtest)
PrintLine(mTrnFileNum, mtest)

End Try

PrintLine(mTrnFileNum, "Finished to update cmdUpdatePull")


'Move to next record
rsPullItems.MoveNext()
PrintLine(mTrnFileNum, "Moving to next rsPullItems")

Loop
rsPullItems.Close()
rsPullItems = Nothing
cmdUpdatePull = Nothing
rsSalesOrders = Nothing
rsWipMaster = Nothing
End If

PrintLine(mTrnFileNum, "End of Pull Items LOOP")
FileClose(mTrnFileNum)


PrintLine(mFileNum, "ending" + Format(Now, "hh:mms"))
FileClose(mFileNum)
ProgressBar1.Value = mCountOfRecords + 100
btnUpdateLean.Enabled = True
Me.Cursor = Cursors.Default

MsgBox("done", MsgBoxStyle.OKOnly, "MXLean Calculation Status")




End

Exit Sub

View 3 Replies View Related

No Processes On The End Of PIPE

Mar 3, 2006

I had to move my developed software onto another computer in order to demo this. The new computer has IIS installed as well as VS2005 and SQL Server 2005. When I try to execute I get this error.



A connection was successfully established with the server, but then an error occurred during the login process. (provider: Shared Memory Provider, error: 0 - No process is on the other end of the pipe.)

I have worked on this problem for two days now and have to demo it first thing Monday. Any help would be appreciated.

View 9 Replies View Related

SQL String Split With | Pipe

Dec 15, 2006

I've got a dilemma here. I'm currently reading records into EasyListBox (ELB) dropdownlist. The criteria in the dropdownlist is based on the select from another ELB dropdownlist. The problem is that the data contains rows with pipes that serve as separters. For example, one of the options that comes back now might be 123 | 456 | 789. I need to be able to make each of them its own row in the dropdownlist. Can anyone advice? Most records don't have any pipes and come throught fine, but some dont.
My code below: 
Dim sAT As String = Replace(elbAttribute.SelectedValue, "'", "''") 
Dim adapter As New SQLDataAdapter("Select Feature_Type As Attribute_Name, FEATURE_TEXT_VALUE as Attribute_Value, (select distinct FILTER_FAMILY_FEATURE_EXCLUDED.FEATURE_TYPE_ID from FILTER_PROFILES, FILTER_FAMILY_FEATURE_EXCLUDED, FAMILY_ALLOWED_FEATURE_TYPES, SHARED_FEATURE_TYPES, SHARED_FEATURE_VALUES where FILTER_PROFILES.FILTER_PROFILE_NAME = 'MAQ' And FILTER_PROFILES.FILTER_PROFILE_ID = FILTER_FAMILY_FEATURE_EXCLUDED.FILTER_PROFILE_ID And FAMILY_ALLOWED_FEATURE_TYPES.FAMILY_ID = FILTER_FAMILY_FEATURE_EXCLUDED.FAMILY_ID And FILTER_FAMILY_FEATURE_EXCLUDED.FEATURE_TYPE_ID = SHARED_FEATURE_TYPES.FEATURE_TYPE_ID And (SHARED_FEATURE_TYPES.Feature_Type_ID = SHARED_FEATURE_VALUES.Feature_Type_ID And left(FEATURE_TYPE, 4) <> 'CPLV' And Feature_Type = '" & sAT & "')) As ExclusionFlag From SHARED_FEATURE_TYPES, SHARED_FEATURE_VALUES, PRODUCT_FEATURE_VALUES Where PRODUCT_FEATURE_VALUES.FEATURE_VALUE_ID = SHARED_FEATURE_VALUES.Feature_Value_ID And SHARED_FEATURE_TYPES.Feature_Type_ID = SHARED_FEATURE_VALUES.Feature_Type_ID And left(FEATURE_TYPE, 4) <> 'CPLV' And Feature_Type = '" & sAT & "' UNION Select distinct Column_Name As Attribute_Name, SMALL_TEXT_VALUE As Attribute_Value, (select FILTER_ATTRIBUTES_EXCLUDED.EXT_ATT_ID from FILTER_PROFILES, FILTER_ATTRIBUTES_EXCLUDED where FILTER_PROFILES.FILTER_PROFILE_NAME = 'MAQ' And FILTER_PROFILES.FILTER_PROFILE_ID = FILTER_ATTRIBUTES_EXCLUDED.FILTER_PROFILE_ID And FILTER_ATTRIBUTES_EXCLUDED.EXT_ATT_ID = EXTENDED_ATTRIBUTES.EXT_ATT_ID) As ExclusionFlag From EXTENDED_ATTRIBUTE_VALUES, EXTENDED_ATTRIBUTES, PRODUCTS Where PRODUCTS.PRODUCT_ID = EXTENDED_ATTRIBUTE_VALUES.PRODUCT_ID And not SMALL_TEXT_VALUE is null And EXTENDED_ATTRIBUTE_VALUES.EXT_ATT_ID > 1499 And EXTENDED_ATTRIBUTE_VALUES.EXT_ATT_ID = EXTENDED_ATTRIBUTES.EXT_ATT_ID And Column_Name = '" & sAT & "'", myConnection) Dim dt As New DataTable()    adapter.Fill(dt) elbValue.DataSource = dt    elbValue.DataBind() 

View 12 Replies View Related

Size Of Pipe To Network

May 24, 2000

My group has recently begun ramping up #of users from 5-10 to 50 concurrent. I'm currently using a 10Mb/s Ethernet but am not sure if there is a fiber
or multiplexing solution that I could use to increase output. Basically, we're looking at up to 50 heavy duty data pulls (50MB+) at any one time.

Thanx,

Joe

View 1 Replies View Related

T-SQL (SS2K8) :: Pipe Row To Column

Mar 4, 2014

Sample Data

MemberID Codes
00000123 012|222|123|333
00000233 012|222|332
00000244 012|211
00000332 012

I am trying to get it so as following:

MemberID Code1, Code2, Code3, Code4

I tried using the XML method but in working with an example, I actually got stuck on one of the declare fields and cant seem to work around it.

Failed Attempt:
DECLARE @x xml;
DECLARE @line VARCHAR(MAX);
SET @x = Cast(
'<field>'
+ replace(@line, '|', '</field><field>')
+ '</field>' AS XML);

[code]...

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved