Showing posts with label local. Show all posts
Showing posts with label local. Show all posts

Monday, March 26, 2012

easy questions related with A-P cluster

Hi everyone,

I'm just a newbie with clustering.

We've got a 64-bit A-P cluster running with Sql25k 64-bit too.

Each node own two local network adapters. One of them (the one currently is Active) own three IP and the another one only one.

Why? From CLUADMIN I see as one of these three is set as Cluster IP Address in Active Resources. So I see the following configuration for the Active node:

Adapter 1: IP public for Active Directory

Adapter2:IP1 (reserved or ?)

IP2 (used as SQL IP Address 1 in Active Resources)

IP3 (used as Cluster IP Address in Active Resources)

Passive node:

Adapter 1: IP public for Active Directory

Adapter2:IP (only have one ?)

Is this correct/necessary? Does anyone have similar configuration?

Thanks for your time,

Does anyone have any idea?|||

This issue has already solved.

Ip1: physical node

Ip2: virtual cluster

Ip3: virtual Sql

sql

easy questions related with A-P cluster

Hi everyone,

I'm just a newbie with clustering.

We've got a 64-bit A-P cluster running with Sql25k 64-bit too.

Each node own two local network adapters. One of them (the one currently is Active) own three IP and the another one only one.

Why? From CLUADMIN I see as one of these three is set as Cluster IP Address in Active Resources. So I see the following configuration for the Active node:

Adapter 1: IP public for Active Directory

Adapter2:IP1 (reserved or ?)

IP2 (used as SQL IP Address 1 in Active Resources)

IP3 (used as Cluster IP Address in Active Resources)

Passive node:

Adapter 1: IP public for Active Directory

Adapter2:IP (only have one ?)

Is this correct/necessary? Does anyone have similar configuration?

Thanks for your time,

Does anyone have any idea?|||

This issue has already solved.

Ip1: physical node

Ip2: virtual cluster

Ip3: virtual Sql

Thursday, March 22, 2012

Easiest way to determine if only client tools are installed?

Hi all,
I've been trying to register my local sql server in enterprise manager
without any success - I can see my remote sql server, but it just wont
connect to the local one on the laptop - I think I may have only install
"client tools" in the past because I thought I'd only want to connect to the
remote server - is there an easy to way to determine whether this is the
case? I've just checked under Add/Remove Programs and there's a SQL Server
entry for about 70mb...
Any info appreciated..
Regards
RobRob Meade (ten.bewdoowsgnik@.edaem.bbor) writes:
> I've been trying to register my local sql server in enterprise manager
> without any success - I can see my remote sql server, but it just wont
> connect to the local one on the laptop - I think I may have only install
> "client tools" in the past because I thought I'd only want to connect to
> the remote server - is there an easy to way to determine whether this is
> the case? I've just checked under Add/Remove Programs and there's a SQL
> Server entry for about 70mb...
Start->Programs->SQL Server. Do you see a Server Network Utility? If you
don't, you don't have the server installed. If you do, you have it
installed. If you also have a Service Manager, start it, and then find
the SQL Server service, and make sure it's running.
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspxsql

Friday, February 24, 2012

Dynamic Table Name creation...

Hi there,

I am trying to generate tables names on the fly depending on another table. So i am creating a local variable containing the table names as required. I am storing the tables in a local variable called

@.TABLENAME VARCHAR(16)

and when i say SELECT * FROM @.TABLENAME

it is giving me an error and I think I cannot declare @.TABLENAME as a table variable because I do not want to create a temp table of sorts.

I hope I am clear.

thanks,

Murthy here

can you post the error generated by SQL server

and the code for generation of tables names , I am curious to see how we can achieve it :)

|||

Are you looking for something like this:

Declare @.tempTable table (
TableName varchar(16)
)

Insert into @.tempTable
Select 'Apples'
union
Select 'Pears'

Select * from @.tempTable

Results:
TableName
------
Apples
Pears

|||

Hi there,

I am posting a portion of my code:

SET @.TABLENAME = 'FISCURRENT.dbo.DC67TRANSCYR' + '0' + CAST((CAST((SUBSTRING(@.FISCALYEAR1,3,2)) AS INT) - 1) AS VARCHAR) + SUBSTRING(@.FISCALYEAR1,3,2)

SELECT DESCRIPTION, TRANSTYPE , BE, CATEGORY, FID , OCA, '67' + ORGL2L5 , EO, AMOUNT, GL, TRANSDATE, MACHINEDATE, 'N' AS BMS, THEYEAR
FROM @.TABLENAME
WHERE ((TRANSTYPE = '20') AND (GL = '92200')) OR
((TRANSTYPE = '21') AND (GL IN ('91100', '92100'))) OR
((TRANSTYPE = '22') AND (GL IN ('13100', '12200'))) AND (BE IN (SELECT DISTINCT BE FROM REF_BUDGETENTITY WHERE FISCALYEAR = @.FISCALYEAR))
And the error message is :

Must declare the table variable "@.TABLENAME".

thanks,

Murthy here

|||

Hi there,

I do not have to create any temp tables. Actually the tables already exist with sql server. based on 1 field from 1 table I have to select data from 1 or more different tables.

The select statement has to different for different tables so I am generating the table names which already exist on the fly.

Hope I am clear.

thanks,

Murthy here

|||

I think you will need to use sp_execsql to execute the dynamic sql you build that way

Keep in mind that many people discourage the use of dynamic sql because of security and performance

1. SQL injection attacks

2. Having to compile the statement every time

3. YOu need to grant permissions on the underlying tables, not on the proc

|||

If you are trying to do something like this:

Declare @.table varchar(20)
set @.table = Northwind.dbo.Products

Select * from @.table

You can't. It's looking for a table afterfromso @.table would have to be a table variable.

To do what you need, asdbland07666 mentioned, you need to use dynamic sql. Caveat Emptor. Here is a link that might help you:

http://www.nigelrivett.net/SQLTsql/TableNameAsVariable.html