Viewing 5 posts - 1 through 5 (of 5 total)
Is this what you are looking for?
insert into myTable (myColumn) values (@myValue + replicate('0', 8-datalength(@myValue)));
you could update the existing values in a similar fashion:
update myTable
set myColumn = myColumn + replicate('0',...
January 18, 2007 at 11:23 am
I worked for Wal-Mart for 3.5 years at their corporate headquarters. I quit one year ago to take a job back in my home state.
I worked on the Retail Link...
November 29, 2005 at 8:53 am
You might try one of the following techniques. The first two require you to know the values for workordernumbers, the third does not:
DECLARE @WorkOrderNumberOne int, @WorkOrderNumberTwo int, @WorkOrderNumberThree int, @WorkOrderNumberFour...
October 7, 2005 at 10:33 am
I am no expert at pivot tables and such, but if I understand the above posts, a hybrid approach would be something like this (not guaranteed to work since I...
October 5, 2005 at 9:21 am
It can be done with a common table expression (CTE), one of the new features of SQL Server 2005. The syntax is a bit different than Oracle, but it is...
August 4, 2005 at 9:19 am
Viewing 5 posts - 1 through 5 (of 5 total)