Viewing 15 posts - 3,151 through 3,165 (of 3,543 total)
I would bcp header data to one file, bcp the data to another and concatenate the two.
July 22, 2003 at 7:05 am
Hi Frank,
'writing nice looking sql'
Sure is, I try to make my code as tabular and indented as possible to make reading and understanding easy and especially for the next poor...
July 22, 2003 at 6:35 am
Hi Jay,
Just being picky but why do have 'HAVING COUNT(*) > 0' in the query? Is it not superfluous as the query cannot return month/year with a count of 0?
Edited...
July 22, 2003 at 6:31 am
What do you mean by transfer?
July 22, 2003 at 6:26 am
Hi Frank,
Actually three, 0, 1 and NULL. In the original and my query there is no provision for NULL and therefore i assumed (there's that word again) there were no...
July 22, 2003 at 6:24 am
Why better, I see nothing wrong with your way. Another way of writing it would be
CREATE PROCEDURE dbo.spRef_GetCertifications
(
@activesOnly bit
)
AS
SELECT ID, Name, IsActive, SubmittedOnGMT
FROM...
July 22, 2003 at 6:02 am
I am on SLQ7 SP4 and I can import fixed length text files with or without cr/lf.
Can you post table structure and sample data?
July 21, 2003 at 7:07 am
Do you mean like this
SELECT *,
(CASEWHEN (tarih >= CONVERT(varchar(11), DATEADD([day], 0, GETDATE()), 120)+'16:00:00')
AND (tarihb <= CONVERT(varchar(11), DATEADD([day], 1, GETDATE()), 120)+'16:00:00')
THEN 1
WHEN...
July 21, 2003 at 6:51 am
Make sure
Access DB is not encrypted or secured
The server has access to the file
Change security to 'they will be mapped to' with a remote user of admin and no password.
...
July 21, 2003 at 5:34 am
This view will return values from the table plus two extra columns for BirthdayToday and BirthdayThisWeek
DROP VIEW UserBirthDay
GO
CREATE VIEW UserBirthDay AS
SELECT...
July 18, 2003 at 7:14 am
If the field contains a LF then I think there must be a problem with the datafile. I have seen data where LF not converted and CR/LF added to each...
July 18, 2003 at 6:38 am
SET DATEFIRST 1 --Monday
declare @startday int,@endday int
set @startday = day(getdate()-datepart(weekday,getdate())+1)
set @endday = @startday+6
select FirstName,LastName
from users
where month(Date_born) = month(getdate())
and day(Date_born) >= @startday
and day(Date_born) <= @endday
July 18, 2003 at 6:05 am
The problem is in the last case (could not test this). It needs an extra bracket
SUM(CASE WHEN (oh.quote_minutes >= 90 AND ISNULL(oh.timedorder,0))
THEN 1 ELSE 0...
July 17, 2003 at 7:54 am
Viewing 15 posts - 3,151 through 3,165 (of 3,543 total)