Viewing 15 posts - 1,096 through 1,110 (of 1,245 total)
I'm guessing a bit here but is this something like what you're after?
create table #mytable
(
Locationvarchar(20)
,shipqtyint
,late_qtyint
,po_datevarchar(10)
)
insert into #mytable (Location,shipqty,late_qty,po_date)
select 'Home',2,3,'02/24/2012' union all
select 'Town',2,5,'01/20/2012' union all
select 'City',5,5,'01/20/2012' union all
select 'Home',4,5,'01/20/2012' union all
select...
April 11, 2014 at 4:55 am
How is the date formatted as varchar? Is it in words or 'yyyy-mm-dd', 'dd-mm-yyyy' or 'mm-dd-yyyy' or some variation of that? If you could post some sample data...
April 11, 2014 at 4:11 am
We've still got a lot of guesswork to do to help out, and that's what we're here to do. If you read this article and post some samples like...
April 11, 2014 at 3:59 am
Could you post some sample data and your expected results please? It will make it a lot easier to answer your questions.
April 11, 2014 at 3:31 am
gpascanu (4/11/2014)
I have the following values in a Float column
266.5
280.98
127.558
How do I set the precision in a SELECT? I need to display two digits after the decimal point. My problem...
April 11, 2014 at 2:47 am
TomThomson (4/10/2014)
Ed Wagner (4/10/2014)
Kurt W. Zimmerman (4/10/2014)
Revenant (4/10/2014)
Ed Wagner (4/10/2014)
SQLRNNR (4/10/2014)
trackerHunt
Dogs
Sun
Set
Up
Charm
Stuart beat me to it!
Feeder
Club
April 11, 2014 at 1:24 am
BWFC (4/10/2014)
April 10, 2014 at 5:19 am
With the Numeric data type, the first digit in the bracket gives the maximum number of digits for the complete figure and the second is the maximum number of digits...
April 10, 2014 at 4:54 am
milos.radivojevic (4/8/2014)
BWFC (4/8/2014)
That solution works but will give an error if the string consists of only numerals.
Thank you BWFC for the correction!
A great thing in this forum is whenever...
April 8, 2014 at 8:00 am
That solution works but will give an error if the string consists of only numerals.
declare @rowstring as varchar(max) = '1251596483'
select
case
when isnumeric(@rowstring) = 1 then @rowstring
else
REVERSE(
SUBSTRING(REVERSE(@rowstring),PATINDEX('%[0-9]%',
REVERSE(@rowstring)),PATINDEX('%[^0-9]%',
SUBSTRING(REVERSE(@rowstring),(PATINDEX('%[0-9]%', REVERSE(@rowstring))),LEN(@rowstring)))-1))
end
That will...
April 8, 2014 at 5:58 am
Ed Wagner (4/7/2014)
TomThomson (4/4/2014)
Revenant (4/4/2014)
SQLRNNR (4/4/2014)
mishkaGrishka
Shishka
Bob
Shilling
April 7, 2014 at 5:22 am
Kurt W. Zimmerman (4/3/2014)
SQLRNNR (4/3/2014)
Ed Wagner (4/3/2014)
crookj (4/3/2014)
Revenant (4/3/2014)
Ed Wagner (4/3/2014)
JAZZ Master (4/3/2014)
SQLRNNR (4/3/2014)
rigoloLaugh
Cry
Baby
Girl
Daddy
Mommy
matriarch
Patriarch
April 4, 2014 at 1:26 am
Ed Wagner (4/1/2014)
TomThomson (4/1/2014)
crookj (4/1/2014)
Ed Wagner (4/1/2014)
SQLRNNR (4/1/2014)
breadDough
Won
Lost
Dog
Day
April 2, 2014 at 1:37 am
Viewing 15 posts - 1,096 through 1,110 (of 1,245 total)