Forum Replies Created

Viewing 15 posts - 1 through 15 (of 106 total)

  • RE: SQL Error Log Size

    Hi,

    As to my knowledge there is no defined size of SQL Server Error Log file. Sql Server will keep on using the same file until the server is restarted or...

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Into Clause in SQL Server

    Dear Pramana,

    Listed is the script taken from http://www.c-sharpcorner.com/UploadFile/67b45a/how-to-generate-a-create-table-script-for-an-existing-table/

    I have modified it to omit the identity property.

    DECLARE

    @object_name SYSNAME

    ...

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Display Order due to NonClustered Index

    GilaMonster (12/30/2014)


    No ORDER BY, no guarantee of order. End of Story

    If you need a particular order, put an ORDER BY on your query.

    Why so serious...!! :crying:

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Trigger Execution Problem

    Dear Akbar,

    If it didn't solve your issue share the complete code and version of your SQL.

    Also have you recently upgraded your SQL Version.

    Saw a similar kind of thread on msdn...

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Trigger Execution Problem

    Dear Akbar,

    have you tried disabling and re-enabling the trigger?

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Data leakage

    Hi,

    What i can make out of your requirement is listed below:

    1. You want to secure your data.

    2. You want to know who is accessing what data.

    If my assumption is correct...

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: how to count a data.

    Old bad habits die hard...!! :blush:

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: how to count a data.

    Dear Gila,

    I started the query with

    Select Distinct(Left(Code,3)..... to check for the first three characters.

    and then added the rest of the code.

    Forgot to remove the Distinct. 😛

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: how to count a data.

    Dear Immaduddin,

    Use the Below mentioned query

    Select Distinct(LEFT(Code,3)) as CODE,COUNT(Name) as Name

    From [TABLENAME]

    Group by LEFT(Code,3)

    Hope it Helps..!!

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Schedule backup/ copy backup and rename to other folder

    Hi,

    For Scheduling backups to one or more then one designated folder you can use ola hallengren backup script.

    https://ola.hallengren.com/sql-server-backup.html

    If you want to move the backed up database to a new folder...

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Error when altering steps from job in SQL 2008

    Check the last reply from the GilaMonster. 🙂

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Execute SSIS package using bat file

    Hi,

    Code in your batch file would be something like this:

    C:\Program Files\Microsoft SQL Server\100\DTS\Binn\dtexec /f "c:\pkgOne.dtsx" /l "DTS.LogProviderTextFile;c:\log.txt"

    # /f "c:\pkgOne.dtsx" refers to the location of the saved SSIS pacakage.

    # /l "DTS.LogProviderTextFile;c:\log.txt"...

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Starting from Scratch - How long to get the gist of SQL Server?

    Dear Accidental Programmer,

    Best of Luck..!! 🙂

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: Index Rebuild -- DB Mirroring / Log Shipping

    Hi,

    Another way to go about it is that you can change the recovery model of the database from Full to Bulk logged and hence Alter Index statement would be minimally...

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

  • RE: query

    DECLARE db_cursor CURSOR FOR

    SELECT name

    FROM master.dbo.sysdatabases

    WHERE name NOT IN ('master','model','msdb','tempdb') AND name like ‘lcn%’ -- exclude these databases

    No need for NOT IN clause 🙂

    DECLARE db_cursor CURSOR FOR...

    Regards,
    Shafat Husain
    🙂
    And Your Lord Never Forgets...!! (64:19 -- Quran)

Viewing 15 posts - 1 through 15 (of 106 total)