• It gives me the error

    Msg 102, Level 15, State 1, Line 31

    Incorrect syntax near '('.

    I understand that is on the:

    sys.dm_db_index_physical_stats (DB_ID()

    But no matter what parameter I pass to the DB_ID function it gives me an error.