Forum Replies Created

Viewing 15 posts - 9,691 through 9,705 (of 10,144 total)

  • RE: The Daily Commute

    torpkev (8/4/2008)


    selling my kidney for gas money.. i think i may go bug em about it

    :hehe: Admirably laid-back attitude Kev!

  • RE: insert - help!

    --not quite, I want to find all the records that exist in both tblstudent_course and tblNew_entrants.

    SELECT c.Course_Code, c.Max_Course_Year, c.Academic_Year, c.Student_ID_Number

    FROM tblStudent_Course c

    INNER JOIN tblNew_Entrants n

    ON c.Course_Code =...

  • RE: insert - help!

    So if Student_ID_Number exists in tblStudent_course but not in tblRegistrations then you want to insert the appropriate columns from tblStudent_course into tblRegistrations;

    and if Student_ID_Number exists in tblNew_entrants but not...

  • RE: insert - help!

    Jude, what do you want to do with tblNew_Entrants? How does it fit into your description?

  • RE: Inserting Top 1 Record

    jeordonez (8/4/2008)


    I am working on an Inventory database and I am doing a mass insert from a stage table to my production table and I have several duplicate records in...

  • RE: The Daily Commute

    Atif Sheikh (8/4/2008)


    Also, working at home also depends on the policy oif the company you are working in. If it is a bank or even a Software development firm, the...

  • RE: How to get Sequential ordering of data based on Ids Passed to IN Keyword

    Hi Jeff

    You pick up a chunk of code off this forum and use it for a year or two; who's credited with it becomes lost in the mists of time....

  • RE: Finding a delivery date based on flags

    Hi Adam

    "Running totals" is one way to tag this problem, and here's a proof-of-concept solution. It's a bit raw so you can check values for yourself to see what's happening....

  • RE: Finding a delivery date based on flags

    Adam Warne (8/1/2008)


    That's spot on Jack.

    Thanks for the responses guys. I'm still trying to solve this myself too.

    First one to a solution get's to go home early?

    Already happened mate,...

  • RE: Finding a delivery date based on flags

    Adam, I've changed my code to subtract the current day number from the first available delivery day number, but if you run it now it will still be incorrect because...

  • RE: Finding a delivery date based on flags

    Hi Adam

    I deliberately changed the data for company 3 to make the test valid.

  • RE: Finding a delivery date based on flags

    Add [DaysToDelivery] to the current date:

    SELECT c.CompanyID, c.CompanyName,

    DATEADD(DD,

    CAST(CHARINDEX('1', CAST(Monday AS CHAR(1))+

    CAST(Tuesday AS CHAR(1))+

    CAST(Wednesday AS CHAR(1))+

    CAST(Thursday AS CHAR(1))+

    CAST(Friday AS CHAR(1))+

    CAST(Saturday AS CHAR(1))+

    CAST(Sunday AS CHAR(1)), DATEPART(dw, GETDATE()) ) AS...

  • RE: Finding a delivery date based on flags

    SET NOCOUNT ON

    DROP TABLE #DeliveryCompany

    DROP TABLE #DeliveryDays

    CREATE TABLE #DeliveryCompany

    (

    CompanyID INT

    ...

  • RE: Not like '%%'

    That's well smart, Ryan. Got a TSQL version? 😛

  • RE: Matching recoreds

    That's the intention.

    If you're likely to have a run of questions on this topic, why not post some table structures and sample data for people to test against?

Viewing 15 posts - 9,691 through 9,705 (of 10,144 total)