Forum Replies Created

Viewing 15 posts - 13,831 through 13,845 (of 14,953 total)

  • RE: Any idea to make it faster?

    I created a table using your structure, then populated it with 1-million rows of random numbers between 0 and 999.

    I tried a couple of different query methods:

    (The table name is...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Show all tabledefinitions

    Will the create scripts for the table accomplish what you need? That will have the definition of each column in each table.

    If so, you can get those by using...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Get Overlapping Date Ranges

    It's pretty simple.

    What you need are reservations that have a check-in date before the other reservation's check-out date, and a check-out date after the other reservation's check-in date.

    select res1.resno, res1.roomno

    from...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: NULL vs Default

    It's not really a question of performance. Either one will be about as fast as the other. It's a question of what do you want in your database,...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: getting error when Exporting to XML using Sql server 2005

    Two things:

    I think the query needs to be enclosed in quotation marks.

    And it might be helpful if you include what error message you're getting.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Building an Insert statement within a string

    The error means you're trying to add numeric (int) values to a string. You have to cast/convert them first.

    It's when you start adding values to the list of what...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: functions in SQL 2000...similar to INSTR and SUBSTR in Oracle

    left(string, charindex('@', string, 0)-1

    will give you everything to the left of the "@"

    right(string, len(string) - charindex('@', string, 0))

    will give you everything to the right of the "@".

    Charindex finds the position...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Stored Procedure - which is faster/better?

    It would go after the table name. Are you sure you want it? (Can result in dirty data.)

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: How to insert into table from two tables of data?

    If there's no relation between them (something like an employee ID), then there's no way to match the rows from one to the other. Is that what you're saying?

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Parsing a cell into multiple rows

    create table dbo.Tally (

    Number int identity (0,1) primary key,

    Junk bit)

    go

    insert into dbo.Tally(junk)

    select top 10001 null

    from sys.all_objects

    cross join sys.all_objects

    go

    alter table dbo.Tally

    drop column junk

    That should do it for you.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Checking the SQL 2005 Installation for no performance bottlenecks

    SQL Server performance is primarily the result of two things: Enough hardware set up correctly, and a well-built database.

    The hardware part is easy. Don't try to run an enterprise...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: How to create a View with rows from multiple tables with different columns?

    Put a column alias in there.

    SELECT 'A' as [Table],

    aID as ID,

    Col,

    ...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Synonym help needed

    The trick, if you want to name it, is don't select "SQL Server", select "Other" and then "Native SQL" as the provider. Then you can name it.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: data retrieval time from the server is too slow

    I'd start by checking the tables and indexes for fragmentation and the statistics for how recent they are.

    You can do this by right-clicking these things in Management Studio and checking...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • RE: Cannot resolve Odd Timeout Issue

    We recently had an issue with intermittent timeouts that was caused by a RAID controller that had started having problems (had a bad solder join on part of it). ...

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

Viewing 15 posts - 13,831 through 13,845 (of 14,953 total)