How To Get Node Name In SQL 2005 Nodes Query? Thanks

Nov 30, 2006

for example,xml like

'<name>test</name><age>10</age>'

select ? from @xml.nodes('/*')

how to get the node tag name like name and age?

thanks

View 4 Replies


ADVERTISEMENT

SQL Server 2005 Standard On 2 Nodes Of A 4 Node Cluster

May 23, 2006

My question is, I'd like my actual cluster to have 4 servers. The virtual server that will be running SQL 2005 will only be installed on 2 of those nodes. Will this work or do I have to split my cluster in to 2 to meet the SQL Server 2005 2 node failover limitation? A basic config for the cluster would be like below....

ClusterSQLNode
Active SQL 2005 Server
ClusterExchNode
Active Exchange Server
ClusterAppNode
Active Application Server
ClusterFailoverNode
Failover SQL 2005
Failover Exchange
Failover Application

Will SQL 2005 install in a 4 server cluster if I only install it on to two of the nodes? Any potential gotchas?

View 1 Replies View Related

Getting All Nodes And Node Details From Xml Using Xquery

Apr 8, 2006

Hi,I haev the following code:DECLARE @x xmlSET @x='<Root><row id="1"><name>Larry</name><oflw>some text</oflw></row><row id="2"><name>Joe</name></row><row id="3" /></Root>'exec sp_xml_preparedocument @idoc OUTPUT, @xSELECT * FROM OPENXML(@idoc, '/Root')This gives the following detailsidparentidnodetype localnameprefixnamespaceuridatatypeprev textI want to get the same details using XQuery, please let me know how togo about it.Regards,Shilpa

View 2 Replies View Related

Cannot Apply SP2 To 2 New Nodes In A 4 Node Cluster ?

Oct 12, 2007

HI There

We had an existing 2 node active / active cluster, 1 running a default instance of Sql Server 2005 Enterprise Edition 9.0.3152 (SP2 + Hotfixes) and the other running a named instance of the same version.

We recently added 2 new nodes to the cluster, they were successfully added and we tested the cluster group failover successfuly to the new nodes.

Last night we tried to install Sql Server 2005 Enterprise edition on the new nodes.

I followed to proper proceudure of modifying the installation for both instances and selecting the 2 new nodes to apply them to. This went 100%. Sql Server 2005 successfully installed for both instances on the 2 new nodes, all log files were successful.

We then tried to apply SP2, we tried the following:

1. We ran SP2 from the active node, but when we go to the screen to select what you want to apply SP2 too we could not select anything, if you clicked on database engine the message said that these instances were already at a later version and we could not proceed. This is how i successfully applied SP2 to the original 2 node cluster but it does not work for additional nodes to an exisitng cluster.

This is also what all the documentation we could find said, refer to SP2 release notes under the topic "Failover Cluster Installation", it is also the method we found when googling.

2. We then tried what is described under SP2 release notes "Rebuild a SQL Server 2005 SP2 Failover Cluster Node".
We ran SP2 from the new nodes while they were passive, but when we got the screen where you select what to apply the SP2 too we could not select database engine the message at the bottom said that SP2 must be run from the active node and that we were attempting it from the passive node, this is what we tried in step 1 described above.

3. This was a last resort. We were advised to try failing over the instance to the new node and then running SP2. Personally i thought this was a bad idea, one should never fail over a instance of sql server to a node with incompatible binary versions and secondly when we installed sql server on the new nodes a warnng popped up before hand stating that the instances were at a later version and that the new nodes must be at this version before attempting fail over. I thought that sql would not even start, to my surprie we successfully failed over the sql group to the new node, when we ran SP2 it looked good we could select the database engine on the new node to apply SP2 too, BUT after clicking next after a few seconds the SP2 installation just closed, NO INFORMAITONAL MESSAGES NO ERRORS NO WARNINGS it just closed an never came back.

I had never seen this happen on a cluster before, needless to say this made me very nervous so we failed the sql group back to the original nodes and gave up.

PLEASE can some tell me how to apply SP2 to 2 new nodes in a 4 node cluster all methods descibed in SP2 release notes and other documentation as descibed above in step 1 and 2 do not work !

Thank You

View 3 Replies View Related

Replication :: Failing To Create Subscription For One Node But Working For Other Nodes

Oct 12, 2015

Merge replication fails on one node with error. The merge process could not update the list of subscriptions.

(Source: MSSQL_REPL, Error number: MSSQL_ REPL-2147201010)
Cannot insert duplicate key row in object 'dbo.sysmergepublications' with unique index 'nc1sysmergepublications'.

The duplicate key value is . (Source: MSSQLServer, Error number: 2601)The subscription could not be created.

(Source: MSSQLServer, Error number: 14057) works fine on other subscribers.

View 4 Replies View Related

XML Query Nodes - Sequence ID

Aug 8, 2014

I have a situation that can be summarized like this :

DECLARE @XML XML = '<X C="0" I="1"><E D="CODE1" A="0" /><E D="CODE2" A="0.03" /><E D="CODE2" A="0.04" /></X>'

SELECT
E.value('@D','varchar(MAX)') AS Code,
E.value('@A','varchar(MAX)') AS Rate
FROM @XML.nodes('./X/E') AS T(E)

The order of appearance is of capital importance as the rates do apply on the previous ones. Is there a way to generate a sequential ID based on the order of appearance in the XML string ? In this case, I want :

1 CODE1 0
2 CODE2 0.03
3 CODE2 0.04

I though of using a temp table with Identity column... But it's not the best way for my need. I have multiple lines each with a XML String. The ROW_NUMBER() windowed function needs a ORDER BY clause that I can't provide.

View 3 Replies View Related

Transact SQL :: Order Of XML Nodes In Xpath Query

Nov 20, 2015

I have an XML field with some data that looks about like this:

<steps>
<step userName="abc"></step>
<step userName="abc"></step>
<step userName="saf2"></step>
<step userName="abc"></step>
</steps>

I have a query something like this:

SELECT XmlField.value('(//step/@userName)[1]', 'VARCHAR(100)') AS userName
FROM theTable

I would like to have some kind of indicator in my TSQL results of the number of each <step> node.  For instance, saf2 would be a 3.  I think this is similar to a ROW_NUMBER() kind of function in normal table data.

Is there a good way to get a 1, 2, 3, and 4 value for this sample data?

View 2 Replies View Related

SQL Server 2005 SP1 Error--No Passive Nodes Were Successfully

Oct 16, 2007



Hello All,

I have a database cluster which I am trying to upgrade to SP1+hotfixes. I was able to successfully upgrade to SP1, however when I try to apply the hotfix "sql2005-kb918222-x86-enu.exe". The install fails and generates the following error log; Can anyone please help? Thanks a lot.

10/16/2007 09:35:50.058 ================================================================================
10/16/2007 09:35:50.058 Hotfix package launched
10/16/2007 09:35:52.495 Product discovery successfully completed during the install process for MSSQLSERVER
10/16/2007 09:35:52.495 SP Level check successfully completed during the install process for MSSQLSERVER
10/16/2007 09:35:52.527 Product language check successfully completed during the install process for MSSQLSERVER
10/16/2007 09:35:52.542 Product version check successfully completed during the install process for MSSQLSERVER
10/16/2007 09:35:52.558 Command-line instance name check completed during the install process
10/16/2007 09:35:52.573 Baseline build check completed during the install process
10/16/2007 09:36:15.028 Attempting to install instance: MSSQLSERVER
10/16/2007 09:36:15.059 Enumerating passive cluster nodes
10/16/2007 09:36:15.090 Patching available passive node: SNTCCASGDB006
10/16/2007 09:36:15.106 Waiting for first successfully completed passive node
10/16/2007 09:36:15.121 Attempting to patch running passive node: SNTCCASGDB006
10/16/2007 09:36:15.200 Successfully created remote folder for product instance target \SNTCCASGDB006
10/16/2007 09:36:15.809 Successfully transferred payload to remote product instance target \SNTCCASGDB006
10/16/2007 09:36:15.825 Successfully transferred payload to remote product instance target \SNTCCASGDB006
10/16/2007 09:36:16.981 Successfully created new scheduled task for product instance target \SNTCCASGDB006
10/16/2007 09:36:17.840 Successfully saved new scheduled task for product instance target \SNTCCASGDB006
10/16/2007 09:36:17.872 Successfully created scheduled task for product instance target \SNTCCASGDB006
10/16/2007 09:36:17.887 Successfully started scheduled task for product instance target \SNTCCASGDB006
10/16/2007 09:36:17.903 Successfully started scheduled task for product instance target \SNTCCASGDB006
10/16/2007 09:36:20.934 Scheduled task for product instance target has completed
10/16/2007 09:36:20.950 Waiting for exit code from scheduled task for product instance target \SNTCCASGDB006
10/16/2007 09:36:25.966 Received exit code 11201 from scheduled task for product instance target \SNTCCASGDB006
10/16/2007 09:36:25.981 Result code for scheduled task for product instance target has been received
10/16/2007 09:36:25.997 Removed scheduled task for product instance target \SNTCCASGDB006
10/16/2007 09:36:26.169 Successfully removed remote folder for product instance target \SNTCCASGDB006
10/16/2007 09:36:26.185 Remote process completed for product instance target
10/16/2007 09:36:26.200 Exit code for passive node: SNTCCASGDB006 = 11201
10/16/2007 09:36:30.122 The following exception occurred: No passive nodes were successfully patched Date: 10/16/2007 09:36:30.122 File: depotsqlvaultstablesetupmainl1setupsqlsesqlsedllinstance.cpp Line: 2583
10/16/2007 09:36:30.169
10/16/2007 09:36:30.200 Product Status Summary:
10/16/2007 09:36:30.232 Product: SQL Server Database Services 2005
10/16/2007 09:36:30.263 MSSQLSERVER - Failure
10/16/2007 09:36:30.310 Details: No passive nodes were successfully patched
10/16/2007 09:36:30.341

View 11 Replies View Related

SQL Server 2012 :: Insert XML (with Multiple Nodes ) Into Table With Query

Dec 9, 2014

My xml is in below format:

DECLARE @MyXML XML
SET @MyXML = '<RS>
<R id="6330">
<WF id="71445">
<WFS id="12790"> <fname>John12790</fname> </WFS>

[Code] ....

I need to insert into table with TSQL query:

My output should be similar below:

John12790 12790 71445 6330
Eric 12791 12790 71445 6330
John12793 12793 71446 6331
Eric12794 12794 71446 6331

otherwise i need to write huge c# code to execute such thing..

View 2 Replies View Related

SQL 2012 :: Log Shipping - Reboot Secondary Node And Then Primary Node

Apr 20, 2015

I have not used log shipping before and find myself in a position where I need to reboot the secondary node and then the primary node and I don't actually need to failover.

Is there anything I need to be aware of. When rebooting the secondary node I assume the transactions will be held in the primary nodes log till the secondary comes back and just carry on once back up?

When rebooting the primary node nothing needs to be done and the log shipping will just start again once it has come back?

View 3 Replies View Related

Do I Need To Install SQL Server To Second Node In Cluster Prior To Adding The Node?

Jun 12, 2007

I read these instructions:

http://msdn2.microsoft.com/en-us/library/ms191545(SQL.90).aspx



But I'm not sure if I have to install SQL Server first on node 2, then add it to the cluster. Or does adding it to the cluster also install the software?



Thanks

View 1 Replies View Related

SQL 2012 :: Running 2 Distinct AGs On Each Node Of A Two Node Cluster?

Oct 23, 2014

I'm contemplating running two availability groups on a two node WSFC. The WSFC is setup with a file share witness (i.e. no shared storage). Can I safely run 1 AG on one primary node, and the other AG on the other node (as primary). Each AG would have replicas on the passive node. This would effectively allow both servers to be in use at the same time. In a failover event, I understand that both workloads would transfer to a single server - so the box needs to be sized appropriately.

View 1 Replies View Related

SQL 2012 :: 3 Node Cluster Runs With 2 Node Failures?

Jun 11, 2015

We are in the process of building a 3 node SQL Server Cluster (Server 2012/ SQL Server 2012), and we have configured the quorum so that all 3 nodes have a vote (no file share witness as we already have an odd number of nodes).

As I understand it, this should allow the cluster to run as long as 2 of the nodes remain online.

However, the validation report states that 2 node failures would be acceptable and, when we tested this by powering off two of the nodes, the cluster did indeed continue to run on a single node.

View 4 Replies View Related

Transfering Cluster Resources From One Node To Another Node

Aug 21, 2007



I configure Windows 2003 R2 and SQL 2005 two nodes Cluster. When I move cluster resource from one node to anther node it takes around 30 seconds to become online. So in that time if any query is running it stops responding.



So please suggest in this regard

View 2 Replies View Related

Read XML Node Elements Using Query

Dec 29, 2011

I am having the example xml with the data as shown below,

declare @x xml
set @x = '<SinterklaasWishlists>
<child>
<name>Tim</name>
<wishlist>
<article>
<artno>21491269</artno>

[Code] ....

I want to extract the elements of xml using sql query and insert the data into the table as shown below:

CHILDNAME ARTICLE_NUMBER DESCRIPTION PRICE
------------------ ---------------------------- ----------------------------------- -----------
Tim1 21491269 Crane 12.50
Tim1 21499517 Keyboard 10
Tim1 21521591 Crime Investigation Game 9.95
Tim2 3145678 Mouse 12.50

View 2 Replies View Related

Is There A Way To Get The Node Descrption In The Same Query Where You Get The Prediction?

Feb 8, 2008

I am doing this right now this way:
1) I do the DMX prediction query where I get the PredictNodeId(predict_var), my query is like this:

SELECT PredictNodeId(predict_var), model_1.predict_var, t.var_1, t.var_2 FROM model_1 PREDICTION JOIN OPENQUERY([DATA_SOURCE_1], 'SELECT var_1, var_2 FROM table_1') AS t ON model_1.var_1 = t.var_1 AND model_1.var_2 = t.var_2
2)I do the DMX query to get the node_description from the model.content iterating each row from the result of my prediction query, this query is like this:

SELECT node_description FROM model_1.content WHERE node_name = 'node_name_var'

In this query node_name_var = PredictNodeId(predict_var) from my prediction query.
What I want to know if there is a way to merge Query 1 and Query 2 so I can get the node_description in the same query qhere I get the PredictNodeId.

Thanks

Juan José Jara

View 3 Replies View Related

Adding Second Node To SQL 2005 Cluster

Feb 20, 2008

I've installed MSCS on two Win2k3 x64 Enterprise systems. On the first I installed SQL 2005, and all went well. All resources are online and SQL works, migrated 25 databases into the new install. Installing SQL 2005 on the second node is problematic. If I select install cluster resources, I have to define new stuff for a new group. If I don't install cluster resources, then the install is all local (nothing on the unseen shared disk resource.)

It does not see the shared disk resource during install, the Quorum is good. I can move the Cluster Group between servers with no problems. None of the SQL resources is available on the second node. Error is basically "a cluster node is not available for this operation".


The Sql Server and Sql Server Agent do not even acknowledge the existence of the second node, and it is not available as a possible owner. i can't find any specific instructions on installing the second node. The other SQL resources say the second server is an available possible owner. None of them will take ownership and run the resource.

Any help available out there?
Thanks!
Bill

View 1 Replies View Related

Add Node To Sql 2005 Failover Clusters Hangs

Feb 2, 2008



Hello,

I wanted to instal sql server 2005 on our sql 2000 failover cluster.
The first thing i did was deinstal sql 2000.

The installation hangs on the dialog screen configuring components and does not present een error.

If i install the cluster with one node there's no problem.
But if i want to add the second node the installion hangs.

When i go to the second node and stop the scheduled task the installations stops.

Do you have any suggestion

View 1 Replies View Related

How To Get 2 Level Tree Node In The Sql Server 2005

May 30, 2008

hi,

How to get 2 level tree node in the sql server 2005. We have table with data.On load we populate the tree in Asp.net.

Regards,
Vinayak Panchal

View 2 Replies View Related

How Do I Write A Query To Get The Path From Ancestor To Node In A Tree?

Sep 12, 2005

Hi all. Here's my problem: I have a tree linking macaddresses (bigints)in a tree structure. i want to get the path from node a to b.create table tree1(father bigint , child bigint);insert into tree1 (father,child) values (100,200);insert into tree1 (father,child) values (100,300);insert into tree1 (father,child) values (100,400);insert into tree1 (father,child) values (200,2000);insert into tree1 (father,child) values (200,3000);insert into tree1 (father,child) values (100,4000);insert into tree1 (father,child) values (2000,11111);you can see that 100 --> 200 --> 2000 --> 11111select * from tree1what i would like is a query that given two parameters returns the pathbetweenthem, in the case of 100,11111 i want to get100200200011111if possible as different rows, but columns will do to.of course i do not know the legnth of the path. it can be very bigthx in advanceTzvika

View 3 Replies View Related

SQL 2005 Analysis Service Clustering And Majority Node Set

Apr 4, 2008



Hi,

I am trying to set up a SQL 2005 analysis server cluster in our two servers, AS02 and AS04. The server cluster is built up on Majority Node Set (MNS). During the installation of the analysis service, I don't see the available cluster groups. In the cluster admin, the cluster is up and running fine. The MNS cluster has no shared disk, and it has two nodes.

Any thoughts or suggestions? or is it possible to built the SQL 2005 analysis service cluster with MNS?

Thanks.

View 4 Replies View Related

How Do You Determine The Active Node Inside A Stored Proc For An Active/passive 2-node Cluster?

Jan 16, 2008

I invoke xp_cmdshell proc from inside a stored procedure on a 2-node active/passive SQL 2005 SP2 Standard cluster. Depending on which server the xp_cmdshell gets executed on I need to pass different arguments in the shell command. I thought I could use host_name() function to get the runtime process server, however, I am finding that it's not behaving correctly. In one example I know my active node is server2, but the host_name() function is returning server1. The only thing that I could possible explain this is that the MSDTC cluster group is not always on the same active node as the SQL server group and in the case I am talking about the cluster groups are in this mode (differnet nodes). Does the xp_cmdshell get executed by the SQL active node or the MDTC active node? And what is the best way to find out which server is going to run my xp_cmdshell?

Thanks.

Edit:

Perhaps another by product of this is that if I run select host_name() from the Studio Management query window i get different results depending on which server I am running the Studio Management on. On server1 I get server1 and on server 2 I get server 2, all the while server2 is the active node. I need a different function that will always let me determine the correct server that'll be running the xp_cmdshell...

Edit 2: I guess I could determine the running host inside the command shell itself, but I am curious to see if i can do it (cleaner) from SQL.

View 1 Replies View Related

Upgrading Memory In A SQL 2005 2 Node Active/passive Cluster

Sep 14, 2007

Could someone give me an ideal of what it takes to upgrade the memory in my cluster. Is it as easy has upgrading the passive node, switching the nodes, then upgrading the other server. And do I need to re-configure the windows cluster. And will both server need to be down at the same time at any point.

Or is their more to the process? Thanks for any assistance.

btw, I currently have 16mb of RAM in each node.

View 3 Replies View Related

SQL 2005 Standard To Enterprise Edition Upgrade On Existing Three-node Cluster

Jun 10, 2007

Current set-up: three node cluster running Windows Server 2003 Enterprise Edition SP2 with two instances of SQL Server 2005 Standard Edition SP2.



Virtual node 1: Standard Edition, default instance, Database Engine only

Virtual node 2: Standard Edition, named instance, Database Engine, Analysis Services and Integration Services



Physical node A: Prefered node for virtual node 1

Physical node B: Failover node for both virtual node 1 and 2 (thus having two installations of Standard Edition)

Physical node C: Prefered node for virtual node 2



We started off with this set-up because there was no need for Enterprise features, and SQL 2005 supports failover clustering with two nodes in Standard Edition. Saved a bundle of cash, so everybody's happy. Now we need to run a solution on virtual node 2 that requires Enterprise features in Analysis and Integration Services, so an edition upgrade is required on virtual node 2. I have done some research and found several edition upgrade examples, but none that match the above scenario. We are running production on these machines, so I can't risk experimenting with command line options, I have to be right the first time.



Is it possible to mix two editions of SQL Server 2005 in one cluster? Can I upgrade virtual node 2 to Enterprise but leave virtual node 1 at Standard? What procedure do I have to follow to upgrade all three components of virtual node 2 to Enterprise Edition on both physical node B and C?



Any ideas will be greatly appreciated.

View 3 Replies View Related

Sql Server 2005 Express: Can't See [DatabaseMail] Node In Manamgent Studio's Object Explorer

Dec 10, 2007

I use Windows Vista Home Premium

Here's my Help About Info: Microsoft SQL Server Management Studio Express 9.00.3042.00
Microsoft Data Access Components (MDAC) 6.0.6000.16386 (vista_rtm.061101-2205)
Microsoft MSXML 3.0 4.0 5.0 6.0
Microsoft Internet Explorer 7.0.6000.16546
Microsoft .NET Framework 2.0.50727.1433
Operating System 6.0.6000

I opened up the Surface Area Configuration Tool and chose the "Surface Area Configuration for Features". Choose "Database Mail" and clicked the checkbox "Enable Database Mail Stored Procedures"

When I go into the Management Studio, I can't see the "Database Mail" node under "Management"
I'm thinking I might need a service pack as in the about, I don't see a service pack listed. BUT, when I go to the SQL Server 2005 Express "Service Pack 2" page, there's no option to just download the Service Pack. I recently downloaded (2 weeks ago or so) this Sql Server Express Edition and I'm thinking this might have Service Pack 2 already, but I'm not sure as I don't see it in the "about".

What should I do?

View 3 Replies View Related

Install Active Active Sql 2005 2 Node Cluster

Mar 12, 2008




Hi all, My aim to install active/active 2 node SQL 2005 cluster. I have installed sql cluster on one mode, which automatically installed on node 2.

it works great. However When i tried to install second virtual server, it is not allowing me to install.

it says already install, can anyone tell me how to install active active cluster

View 1 Replies View Related

Function On Heirarchy Nodes

Feb 3, 2006

Hi
i have 3 master tables 1)RoleDetails(Roleid(PK),name,masterroleid(fk) ref:RoleDetails roleid)
2) PositionDetails(positionid(PK), name,MasterPositionid(FK) ref:PostionDetails postionid,Roleid(fk) ref:Roledetails roleid)
3) Userdetails(userid(pk), loginid,pwd,roleid(fk) ref:roledetails roleid,positionid(fk)ref:postionDetails positionid,fname,address)
how to Create two functions one return child nodes as per Case 1 and another one is return Parent Nodes
as per case 2
(Manager) a -- r1 (roledetails)
/

(ROL)a1 (ROL) a2 -- r2
/ | / | |
(RO)b1 b2 b3 b4 b5 b6 -- r3
Case 1:
On passing the User ID of (a) , should get the Output as User id of ( b1,b2,b3,b4,b5,b6) along with their Role ID.

On passing the User ID of (a1), should get the Output as User ID of (b1,b2,b3)along with their Role ID.

Case 2:
On passing the Role ID of (R3), should get the User ID of all the Parent roles( a1 and a2 (R2), a(R1)long with their Role id
Case 3: on passing role id of child node , should get only all particular parent userid and roleid's.

thanks in adv.,
chakri

View 14 Replies View Related

SQL Clustering Info - More Than 2 Nodes Please.

Oct 26, 2005

I am looking for information on building a 4 node, multi-instance, SQL cluster on Win2K3 Datacenter server. I've consulted BOL, google, and Microsoft's "techinfo" pages for Datacenter server clustering, but everytime I think I'm going to get some good information, I end up with info on a default, 2-node cluster setup. Any guidence, links, etc. would be highly prized.

Thanks very much.

View 3 Replies View Related

Retrieving Tree Sub Nodes

Apr 16, 2007

I have a tree structured table like the ff.



which looks like the one below in tree view.



I'd like to get the rows under a specified elementnumber which may have unlimited sub-nodes.

i.e. If i want only 'Level1' i would get results from row 2-5.

any help is greatly appreciated.

View 4 Replies View Related

Nested Nodes In XML From A Table

Dec 6, 2005

Dear all,I have table called CATEGORY, which is defined as follows:CREATE TABLE CATEGORY(CATEGORY_ID INTEGER IDENTITY(1,1) NOT NULL,CATEGORY_NAME VARCHAR(40) NOT NULL CONSTRAINTUC__CATEGORY__CATEGORY_NAME UNIQUE,PARENT_CATEGORY_ID INTEGER,CATEGORY_ICON IMAGE,DEPTH INTEGER,CONSTRAINT PK__CATEGORY PRIMARY KEY (CATEGORY_ID))Supposly, the following snap shot was taken later:================================================== ============| CATEGORY_ID | CATEGORY_NAME | PARENT_CATEGORY_ID | DEPTH |================================================== ============| 1 | PC | NULL | 1 |--------------------------------------------------------------| 2 | Networks | 1 | 2 |--------------------------------------------------------------| 3 | Audio | 1 | 2 |--------------------------------------------------------------| 4 | Video | 1 | 2 |--------------------------------------------------------------| 5 | TV Cards | 4 | 3 |--------------------------------------------------------------| 6 | Graphics Cards | 4 | 3 |--------------------------------------------------------------| 7 | AGP | 6 | 4 |--------------------------------------------------------------| 8 | PCI | 6 | 4 |--------------------------------------------------------------| 9 | Input Devices | 1 | 2 |--------------------------------------------------------------and I'd like to create out of this hierarchy the following desired XMLfile:<?xml version="1.0" encoding="utf-8" ?><Hardware><Catgeory name="PC" id="1"><Catgeory name="Networks" id="2" /><Catgeory name="Audio" id="3" /><Catgeory name="Video" id="4"><Catgeory name="TV Cards" id="5" /><Catgeory name="Graphics Cards" id="6"><Catgeory name="AGP" id="7" /><Catgeory name="PCI" id="8" /></Category></Category><Catgeory name="Input Devices" id="9" /></Catgeory></Hardware>The reason for this file is that it will be a datasource of theTreeView Control new in asp.net 2.0.Now, programmateiclally using C#.net i started using the XmlDocument,XmlTextWriter and XmlTextReader Namespaces and started using susingrecurrsion to genearete this desired XML file out of the records in thesnapshot, but ...Is there an easy way of doing this using SqlServer 2005 with the newdatatype XML?*Any hint would also be ok*Best regards

View 12 Replies View Related

A 3-nodes And 2-clusters Architecture Possible?

Feb 7, 2008

To all the SQL H/A experts, we were wondering if we could have 3 physical nodes and 2 active/passive clusters architecture setup on a SAN as seen in the image below? http://www.geocities.com/juanlieu/CP_Arch.JPGIn case you cannot see the diagram, it would looks something like this:
active/passive Cluster A ---> physical server A (Win2003/SQL2005) ---> HP EVA SAN ---> physical server B (Win2003/SQL2005) ---> HP EVA SANactive/passive Cluster B ---> physical server B (Win2003/SQL2005) ---> HP EVA SAN ---> physical server C (Win2003/SQL2005) ---> HP EVA SAN
In this setup, I understand that Server B cannot be called upon as the active server at the SAME time by both clusters. question: what would happens if it does, would Server B reject the last cluster that calls it?Appreciated in advance.

View 3 Replies View Related

Adding Custom Nodes To The RDL

Dec 10, 2007

Is there a way to expand the RDL to add custom nodes?

I read here there is a <Custom> element that can be put inside the <Report> node, but it does not work. I get all kinds of Scheme errors.
http://msdn2.microsoft.com/en-us/library/ms153972.aspx


I get the following errors when I add <Custom> element inside <Report>, which is acceptable according the the MSDN link above.


Deserialization failed: The element 'Report' in namespace 'http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition' has invalid child element 'Custom' in namespace 'http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition'. List of possible elements expected: 'http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinitionescription http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:Author http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:AutoRefresh http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinitionataSources http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinitionataSets http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:Body http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:ReportParameters http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:Code http://schemas.microsoft.com/sqlserver/reporting/2005/... Line 3, position 4.


Does anyone know how to get this to work, or know where there might be some information about this online? I am coming up dry.

Thanks.

View 1 Replies View Related

XML Datatype Nodes() Method

Oct 30, 2006



Dear ppl, I want to shred the following XML so that i can get all the Warranty(s) with id and text.

Required Output

id WarrantyText
1 1 year parts and labor
2 2 year parts and labor

XML

declare @myDoc xml
set @myDoc =
'<ProductDescription ProductID="1" ProductName="Road Bike">
<Features >
<Warranty id="1">1 year parts and labor</Warranty>
<Warranty id="2">2 year parts and labor</Warranty>
<Maintenance>3 year parts and labor extended maintenance is available</Maintenance>
</Features>
</ProductDescription>'


I am using the following query but it doesn't seem to work


select C.value('@id', 'nvarchar(max)' ) as ID,
C.value('Warranty', 'nvarchar(max)' ) as WarrantyText
from @myDoc.nodes('//Warranty') T(C)

View 4 Replies View Related







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