Rabbitfood
Programmer
Hi,
I am trying to do a select into ie.
INSERT INTO TableA (col1, col2)
SELECT (col1, col2)
FROM TableA
WHERE col3 = ...
Now in part of my select statement I want to create a new string by selecting some existing data and building it up using the + operater but I also want to include vbCRLF
SELECT ....,
'Some Text:' + col4 + 'some more text', etc..
I did not include the vbCRLF in the example above because I cant get it to work - so rather than me fudging it I will explain why I am trying to do it.
Im working in ASP (classic) (and MS SQL 05) and I want to insert some data so that when presented back in html it wraps - but I dont want to use "<br />". So what I would have done is:
dim myString : myString = "some text" & vbCRLF & "more text"
Now after submitting this data, I can pull it back out and it will display with line breaks but without the use of "<br />".
The end result is to send the data I'm pulling out in a HTML formatted email.
So is it possible, or is there another way, to do what im asking?
Below is a small portion of the query I will actually be running - note I have used <br /> in my example but I would really like to not hae to do it that way.
SELECT 'REFUND FOR ORDER #195001<br />See original order comments below<br />---------------------------------<br />' + ISNULL(comments, '')
+ '<br />---------------------------------<br />' AS comments
FROM Orders
WHERE (Order_ID = 195001)
Thanks In Advance, David.
I am trying to do a select into ie.
INSERT INTO TableA (col1, col2)
SELECT (col1, col2)
FROM TableA
WHERE col3 = ...
Now in part of my select statement I want to create a new string by selecting some existing data and building it up using the + operater but I also want to include vbCRLF
SELECT ....,
'Some Text:' + col4 + 'some more text', etc..
I did not include the vbCRLF in the example above because I cant get it to work - so rather than me fudging it I will explain why I am trying to do it.
Im working in ASP (classic) (and MS SQL 05) and I want to insert some data so that when presented back in html it wraps - but I dont want to use "<br />". So what I would have done is:
dim myString : myString = "some text" & vbCRLF & "more text"
Now after submitting this data, I can pull it back out and it will display with line breaks but without the use of "<br />".
The end result is to send the data I'm pulling out in a HTML formatted email.
So is it possible, or is there another way, to do what im asking?
Below is a small portion of the query I will actually be running - note I have used <br /> in my example but I would really like to not hae to do it that way.
SELECT 'REFUND FOR ORDER #195001<br />See original order comments below<br />---------------------------------<br />' + ISNULL(comments, '')
+ '<br />---------------------------------<br />' AS comments
FROM Orders
WHERE (Order_ID = 195001)
Thanks In Advance, David.