Click here to Skip to main content
15,896,557 members
Home / Discussions / Database
   

Database

 
GeneralRe: large SQL table update performance Pin
David Mujica9-Dec-10 9:25
David Mujica9-Dec-10 9:25 
AnswerRe: large SQL table update performance Pin
jschell9-Dec-10 10:25
jschell9-Dec-10 10:25 
AnswerRe: large SQL table update performance Pin
Mycroft Holmes9-Dec-10 11:34
professionalMycroft Holmes9-Dec-10 11:34 
Questionsyntax error! Pin
Jassim Rahma9-Dec-10 2:57
Jassim Rahma9-Dec-10 2:57 
AnswerRe: syntax error! Pin
Pete O'Hanlon9-Dec-10 4:10
mvePete O'Hanlon9-Dec-10 4:10 
AnswerRe: syntax error! Pin
Eddy Vluggen9-Dec-10 5:02
professionalEddy Vluggen9-Dec-10 5:02 
QuestionOPENXML - SQL Pin
Hum Dum8-Dec-10 17:46
Hum Dum8-Dec-10 17:46 
AnswerRe: OPENXML - SQL Pin
Hiren solanki8-Dec-10 22:53
Hiren solanki8-Dec-10 22:53 
Hum Dum wrote:
SELECT @address = CONVERT(VARCHAR(150),[TEXT]) FROM OPENXML(@idoc,'/Name_Address/address', 0) where [text] is not null


AFAIK the result is having two rows returning and At a time of converting SQL might picking up the second row and converting it accordingly, As It returns two rows having one column.

But I can Provide you another solution for that. To first Retrieve the result and using COALESCE you can JOIN them together to produce expected result.

Here's my work for you only.

SQL
SELECT @address = COALESCE(@address+',' ,'') + [address]
FROM 
(
SELECT    * FROM       
OPENXML (@idoc, 'Name_Address/address',3)
WITH ([address]  varchar(1000) '.')
) P
SELECT @address


It's working all right.

QuestionUpdating a DataSet from a Database Pin
Dominick Marciano8-Dec-10 14:07
professionalDominick Marciano8-Dec-10 14:07 
AnswerRe: Updating a DataSet from a Database Pin
PIEBALDconsult8-Dec-10 17:02
mvePIEBALDconsult8-Dec-10 17:02 
AnswerRe: Updating a DataSet from a Database Pin
Mycroft Holmes8-Dec-10 20:17
professionalMycroft Holmes8-Dec-10 20:17 
AnswerRe: Updating a DataSet from a Database Pin
David Mujica9-Dec-10 3:21
David Mujica9-Dec-10 3:21 
AnswerRe: Updating a DataSet from a Database Pin
Vimalsoft(Pty) Ltd9-Dec-10 4:30
professionalVimalsoft(Pty) Ltd9-Dec-10 4:30 
AnswerRe: Updating a DataSet from a Database Pin
Dominick Marciano10-Dec-10 4:25
professionalDominick Marciano10-Dec-10 4:25 
AnswerRe: Updating a DataSet from a Database Pin
Spectre_00114-Dec-10 2:37
Spectre_00114-Dec-10 2:37 
Questiontable physical size [mysql] Pin
Jassim Rahma8-Dec-10 4:08
Jassim Rahma8-Dec-10 4:08 
AnswerRe: table physical size [mysql] Pin
Eddy Vluggen8-Dec-10 4:57
professionalEddy Vluggen8-Dec-10 4:57 
AnswerRe: table physical size [mysql] Pin
PIEBALDconsult8-Dec-10 14:11
mvePIEBALDconsult8-Dec-10 14:11 
Questiondatabase physical size Pin
Jassim Rahma8-Dec-10 3:46
Jassim Rahma8-Dec-10 3:46 
AnswerRe: database physical size Pin
NeverHeardOfMe8-Dec-10 4:07
NeverHeardOfMe8-Dec-10 4:07 
AnswerRe: database physical size Pin
PIEBALDconsult8-Dec-10 14:10
mvePIEBALDconsult8-Dec-10 14:10 
Questionserver properties Pin
Jassim Rahma8-Dec-10 3:46
Jassim Rahma8-Dec-10 3:46 
Questionrun dynamic sql [mysql] Pin
Jassim Rahma8-Dec-10 3:42
Jassim Rahma8-Dec-10 3:42 
AnswerRe: run dynamic sql [mysql] Pin
Chris Meech8-Dec-10 7:38
Chris Meech8-Dec-10 7:38 
AnswerRe: run dynamic sql [mysql] Pin
RyanEK8-Dec-10 14:30
RyanEK8-Dec-10 14:30 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.