Forum Replies Created

Viewing 15 posts - 766 through 780 (of 907 total)

  • RE: Log file question

    One option would be to batch up your imports into pieces, say 1000 records. This would require less log space per batch, then one large batch.

    Gregory Larsen, DBA

    If you...

  • RE: SET NOCOUNT ON isn't working

    Maybe it's time to call Microsoft.

    Gregory Larsen, DBA

    If you looking for SQL Server Examples check out my website at http://www.geocities.com/sqlserverexamples

  • RE: Space Allocation

    Here are a couple of things you might consider.

    If all the database on the server needed to grow no bigger than the allocated size, and the drive where...

  • RE: retrive 10,11,12..15 rows in a table

    Here is an example of a way you can retrieve 10-15 without a cursor using the top and order by clauses.

    Create table top_test (id int identity, description char(1))

    insert into top_test...

  • RE: retrive 10,11,12..15 rows in a table

    quote:


    You have an attribute called Top within the select statement... that essentially limits the number of records returned.... but only the first...

  • RE: Collate clause

    Make sense now, but BOL under ALTER TABLE under COLLATE says this:

    The COLLATE clause can be used to alter the collations only of columns of the char, varchar, text, nchar,...

  • RE: Advice on using COUNT( )

    Good article. Has a lot of valuable information about the in's and out's of COUNT.

    I've always used code similar to this for finding the row count, provided...

  • RE: Multiple select in a search

    Maybe something like this pseudo code will work for you

    Declare @search_clause char(1000)

    set @search_clause = ''

    if Category = 1

    set @search_clause = CategoryID = 1

    if Category = 3

    begin

    ...

  • RE: Changing Collation for a SQL 2000 DB.

    The reason I care is because we have cross database queries. When you have databases with a different character set, there are issues comparing data between database. To...

  • RE: cursor update

    Yep! I was goind to suggest that, but thought maybe you wanted to build a table contain all columns, there distinct values, and a Count of each value.

    Gregory Larsen,...

  • RE: Programatically Discard Results

    For OSQL and ISQL try this to find the command options:

    OSQL -?

    or

    ISQL -?

    Think you might be looking for the -o and -i options. Where -o write ISQL or...

  • RE: SET NOCOUNT ON isn't working

    Some where in you stored procedure after you issue the "SET NOCOUNT ON" run this:

    select @@OPTIONS&512

    if the result is 0 then "Set nocount off" is applied. If...

  • RE: Cursor declaration in a Stored Procedure

    I'll take a stab at this.

    Since cursors reside in SQL Server memory I think the following guidelines should be considered:

    1) Define the cursor right before you open it...

  • RE: using dynamic sql in from clause

    Some what. Here is an example:

    use pubs

    declare @v_table varchar(100)

    set @v_table = 'publishers'

    declare @cmd varchar (100)

    set @cmd = 'select country from ' + @v_table

    exec (@cmd)

    Gregory Larsen, DBA

    If you...

  • RE: cursor update

    I'm not exactly sure what you wanted to do. But I think I changed your code to reflect what I think you wanted (see below).

    I noticed your code in...

Viewing 15 posts - 766 through 780 (of 907 total)