Showing posts with label sql2005. Show all posts
Showing posts with label sql2005. Show all posts

Wednesday, March 28, 2012

ok to install sql2005/2000,vs2005/2003 on same machine

Hi just wondering if anyone has run into any problems installing and running
vs2005 and sql 2005 prof with a machine that already has sql2000 and vs2003,
or if it will effect sql 2000 or vs2003 in any way, thanks.
--
Paul G
Software engineer.I run this configuration. It does work. I installed a certificate on my web
server and suddenly I couldn't connect to SQL 2000 anymore. Other than that
it was working well.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:A323C6DA-764B-4298-9CBB-3E751F55DD0F@.microsoft.com...
> Hi just wondering if anyone has run into any problems installing and
> running
> vs2005 and sql 2005 prof with a machine that already has sql2000 and
> vs2003,
> or if it will effect sql 2000 or vs2003 in any way, thanks.
> --
> Paul G
> Software engineer.|||thanks for the response. I think I am having problems with the installation
.
For components to install it lists SQL Server Database Services, Analysis
Services, Reporting Services, Integration Services, Workstations Components,
Books online and development tools. It seems to install without error but I
do not see SQL server management studio from the programs list.
--
Paul G
Software engineer.
"Hilary Cotter" wrote:

> I run this configuration. It does work. I installed a certificate on my we
b
> server and suddenly I couldn't connect to SQL 2000 anymore. Other than tha
t
> it was working well.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:A323C6DA-764B-4298-9CBB-3E751F55DD0F@.microsoft.com...
>
>|||Chances are this is because you installed SQL Express with Visual Studio
before you installed SQL Server 2005. This leaves you with the SQL Express
client utilities which don't include Management Studio. Try uninstalling
the client utilities and then reinstalling them from the full SQL Server
2005 release.
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:CB9FDA44-C306-4A28-B054-D3CA726A5936@.microsoft.com...[vbcol=seagreen]
> thanks for the response. I think I am having problems with the
> installation.
> For components to install it lists SQL Server Database Services, Analysis
> Services, Reporting Services, Integration Services, Workstations
> Components,
> Books online and development tools. It seems to install without error but
> I
> do not see SQL server management studio from the programs list.
> --
> Paul G
> Software engineer.
>
> "Hilary Cotter" wrote:
>|||ok thanks that seemed to work!
--
Paul G
Software engineer.
"Roger Wolter[MSFT]" wrote:

> Chances are this is because you installed SQL Express with Visual Studio
> before you installed SQL Server 2005. This leaves you with the SQL Expres
s
> client utilities which don't include Management Studio. Try uninstalling
> the client utilities and then reinstalling them from the full SQL Server
> 2005 release.
> --
> This posting is provided "AS IS" with no warranties, and confers no rights
.
> Use of included script samples are subject to the terms specified at
> http://www.microsoft.com/info/cpyright.htm
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:CB9FDA44-C306-4A28-B054-D3CA726A5936@.microsoft.com...
>
>sql

ok to install sql2005/2000,vs2005/2003 on same machine

Hi just wondering if anyone has run into any problems installing and running
vs2005 and sql 2005 prof with a machine that already has sql2000 and vs2003,
or if it will effect sql 2000 or vs2003 in any way, thanks.
--
Paul G
Software engineer.I run this configuration. It does work. I installed a certificate on my web
server and suddenly I couldn't connect to SQL 2000 anymore. Other than that
it was working well.
--
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:A323C6DA-764B-4298-9CBB-3E751F55DD0F@.microsoft.com...
> Hi just wondering if anyone has run into any problems installing and
> running
> vs2005 and sql 2005 prof with a machine that already has sql2000 and
> vs2003,
> or if it will effect sql 2000 or vs2003 in any way, thanks.
> --
> Paul G
> Software engineer.|||thanks for the response. I think I am having problems with the installation.
For components to install it lists SQL Server Database Services, Analysis
Services, Reporting Services, Integration Services, Workstations Components,
Books online and development tools. It seems to install without error but I
do not see SQL server management studio from the programs list.
--
Paul G
Software engineer.
"Hilary Cotter" wrote:
> I run this configuration. It does work. I installed a certificate on my web
> server and suddenly I couldn't connect to SQL 2000 anymore. Other than that
> it was working well.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:A323C6DA-764B-4298-9CBB-3E751F55DD0F@.microsoft.com...
> > Hi just wondering if anyone has run into any problems installing and
> > running
> > vs2005 and sql 2005 prof with a machine that already has sql2000 and
> > vs2003,
> > or if it will effect sql 2000 or vs2003 in any way, thanks.
> > --
> > Paul G
> > Software engineer.
>
>|||Chances are this is because you installed SQL Express with Visual Studio
before you installed SQL Server 2005. This leaves you with the SQL Express
client utilities which don't include Management Studio. Try uninstalling
the client utilities and then reinstalling them from the full SQL Server
2005 release.
--
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:CB9FDA44-C306-4A28-B054-D3CA726A5936@.microsoft.com...
> thanks for the response. I think I am having problems with the
> installation.
> For components to install it lists SQL Server Database Services, Analysis
> Services, Reporting Services, Integration Services, Workstations
> Components,
> Books online and development tools. It seems to install without error but
> I
> do not see SQL server management studio from the programs list.
> --
> Paul G
> Software engineer.
>
> "Hilary Cotter" wrote:
>> I run this configuration. It does work. I installed a certificate on my
>> web
>> server and suddenly I couldn't connect to SQL 2000 anymore. Other than
>> that
>> it was working well.
>> --
>> Hilary Cotter
>> Looking for a SQL Server replication book?
>> http://www.nwsu.com/0974973602.html
>> Looking for a FAQ on Indexing Services/SQL FTS
>> http://www.indexserverfaq.com
>> "Paul" <Paul@.discussions.microsoft.com> wrote in message
>> news:A323C6DA-764B-4298-9CBB-3E751F55DD0F@.microsoft.com...
>> > Hi just wondering if anyone has run into any problems installing and
>> > running
>> > vs2005 and sql 2005 prof with a machine that already has sql2000 and
>> > vs2003,
>> > or if it will effect sql 2000 or vs2003 in any way, thanks.
>> > --
>> > Paul G
>> > Software engineer.
>>|||ok thanks that seemed to work!
--
Paul G
Software engineer.
"Roger Wolter[MSFT]" wrote:
> Chances are this is because you installed SQL Express with Visual Studio
> before you installed SQL Server 2005. This leaves you with the SQL Express
> client utilities which don't include Management Studio. Try uninstalling
> the client utilities and then reinstalling them from the full SQL Server
> 2005 release.
> --
> This posting is provided "AS IS" with no warranties, and confers no rights.
> Use of included script samples are subject to the terms specified at
> http://www.microsoft.com/info/cpyright.htm
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:CB9FDA44-C306-4A28-B054-D3CA726A5936@.microsoft.com...
> > thanks for the response. I think I am having problems with the
> > installation.
> > For components to install it lists SQL Server Database Services, Analysis
> > Services, Reporting Services, Integration Services, Workstations
> > Components,
> > Books online and development tools. It seems to install without error but
> > I
> > do not see SQL server management studio from the programs list.
> > --
> > Paul G
> > Software engineer.
> >
> >
> > "Hilary Cotter" wrote:
> >
> >> I run this configuration. It does work. I installed a certificate on my
> >> web
> >> server and suddenly I couldn't connect to SQL 2000 anymore. Other than
> >> that
> >> it was working well.
> >>
> >> --
> >> Hilary Cotter
> >> Looking for a SQL Server replication book?
> >> http://www.nwsu.com/0974973602.html
> >>
> >> Looking for a FAQ on Indexing Services/SQL FTS
> >> http://www.indexserverfaq.com
> >>
> >> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> >> news:A323C6DA-764B-4298-9CBB-3E751F55DD0F@.microsoft.com...
> >> > Hi just wondering if anyone has run into any problems installing and
> >> > running
> >> > vs2005 and sql 2005 prof with a machine that already has sql2000 and
> >> > vs2003,
> >> > or if it will effect sql 2000 or vs2003 in any way, thanks.
> >> > --
> >> > Paul G
> >> > Software engineer.
> >>
> >>
> >>
>
>

Wednesday, March 21, 2012

odd issue with NOT IN statement

Some info

We recently moved a database to SQL2005 (start of year) a program I wrote is having a small issue(not rejecting unmatched orders) and I narrowed it to one command statement (that I tried directly in the management studio)

I have two databases on the server (a live and a test DB) on the test DB (same tables and views as live but the data is a bit different) side there is no issue, while on the live side it is not working.

the command is

update wip set haserr=[order xref] where [order xref] not in (select [order xref] from m_orders)

on the test database if I add in the wip table a bad order number [order xref] it won't find it and it flags the haserr column and a reject statement is created for that order.

On the live database the haserr is not changed and so the filling of the order is not rejected when it needs to. It looks to be an issue with the "not in" command

PS at first I thought it was an update issue, but if I do

select * form wip where [order xref] not in (select [order xref] from m_orders)

edit: did some more testing

update wip set haserr=[order xref] where [order xref] in (select [order xref] from m_orders)

works

update wip set haserr=[order xref] where [order xref] not in (select [order xref] from m_orders)

does not

I get null

My knee-jerk reaction to this is to change NOT IN syntax into NOT EXISTS syntax.

update wip

set haserr=[order xref]

from wip a

inner join m_orders b

on a.[order xref] = b.[order xref]

There are issues with NOT IN when your field is null that can cause the results to be different than the way you might intuitively expect. When the result is a NULL it cannot be determined whether the record is IN or NOT IN the set because the NULL means unknown. There have been previous threads that discuss this; I will try to find a couple.

Here are a couple of posts:

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

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

It is bcs of your null value on m_orders table..

(Ex)

Select * From MYTable Where Id in (1,3,4,null)

Will return 1,3,4

Select * From MyTable Where Id not in (1,3,4,null)

will not return any value

Why?

The not in (1,3,4,null) = not (Id =1 or Id =3 or Id=4 or Id=null)

= id <> 1 and Id <> 3 and Id <> 4 And id <> null

= True And True And True And NULL

= True And NULL

= FALSE

ie, ALWAYS FALSE

The in (1,3,4) = (Id =1 or Id =3 or Id=4 or Id=null)

= True or False Or null

= True Or NULL

= True

So change your query as follow as,

update wip set haserr=[order xref] where [order xref] not in (select [order xref] from m_orders Where [order xref] is NOT NULL)

|||NULL fails it, NULL values cant be compared.........sql

Tuesday, March 20, 2012

odd issue with IN statement

Some info

We recently moved a database to SQL2005 (start of year) a program I wrote is having a small issue(not rejecting unmatched orders) and I narrowed it to one command statement (that I tried directly in the management studio)

I have two databases on the server (a live and a test DB) on the test DB (same tables and views as live but the data is a bit different) side there is no issue, while on the live side it is not working.

the command is

update wip set haserr=[order xref] where [order xref] not in (select [order xref] from m_orders)

on the test database if I add in the wip table a bad order number [order xref] it won't find it and it flags the haserr column and a reject statement is created for that order.

On the live database the haserr is not changed and so the filling of the order is not rejected when it needs to. It looks to be an issue with the "not in" command

PS at first I thought it was an update issue, but if I do

select * form wip where [order xref] not in (select [order xref] from m_orders)

edit: did some more testing

update wip set haserr=[order xref] where [order xref] in (select [order xref] from m_orders)

works

update wip set haserr=[order xref] where [order xref] not in (select [order xref] from m_orders)

does not

I get null

My knee-jerk reaction to this is to change NOT IN syntax into NOT EXISTS syntax.

update wip

set haserr=[order xref]

from wip a

inner join m_orders b

on a.[order xref] = b.[order xref]

There are issues with NOT IN when your field is null that can cause the results to be different than the way you might intuitively expect. When the result is a NULL it cannot be determined whether the record is IN or NOT IN the set because the NULL means unknown. There have been previous threads that discuss this; I will try to find a couple.

Here are a couple of posts:

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

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

It is bcs of your null value on m_orders table..

(Ex)

Select * From MYTable Where Id in (1,3,4,null)

Will return 1,3,4

Select * From MyTable Where Id not in (1,3,4,null)

will not return any value

Why?

The not in (1,3,4,null) = not (Id =1 or Id =3 or Id=4 or Id=null)

= id <> 1 and Id <> 3 and Id <> 4 And id <> null

= True And True And True And NULL

= True And NULL

= FALSE

ie, ALWAYS FALSE

The in (1,3,4) = (Id =1 or Id =3 or Id=4 or Id=null)

= True or False Or null

= True Or NULL

= True

So change your query as follow as,

update wip set haserr=[order xref] where [order xref] not in (select [order xref] from m_orders Where [order xref] is NOT NULL)

|||NULL fails it, NULL values cant be compared.........

Saturday, February 25, 2012

ODBC on SQL 2005

Hi,
I need to set up an ODBC Connection to a Navision DB. Under SQL 2000 I used
the regular ODBC driver and it worked fine.
With SQL2005 I just can select ".net Framework Data Provider for ODBC" and I
can't get the connection up and running. Does there exist any other ODBC
drivers which work on SQL2005 ?
Hope anyone can help !
Thanks
AxelWhat errors are you getting? Have you went to the surface area configuratio
n
tool in SQL 2005 and made sure remote connections are enabled?
MeanOldDBA
derrickleggett@.hotmail.com
http://weblogs.sqlteam.com/derrickl
When life gives you a lemon, fire the DBA.
"Axel" wrote:

> Hi,
> I need to set up an ODBC Connection to a Navision DB. Under SQL 2000 I use
d
> the regular ODBC driver and it worked fine.
> With SQL2005 I just can select ".net Framework Data Provider for ODBC" and
I
> can't get the connection up and running. Does there exist any other ODBC
> drivers which work on SQL2005 ?
> Hope anyone can help !
> Thanks
> Axel
>
>