Home Microsoft SQL Server DigiMailing iRN Contact
    Keyword



sys.sp_MScheck_join_filter_circular_relations

  No additional text.


Syntax
create procedure sys.sp_MScheck_join_filter_circular_relations @pubid uniqueidentifier
                                        , @use_partition_groups smallint
                                        , @can_use_partition_groups bit output
as
    declare @join_filters table (art_nick int, join_nick int, level int)

    insert into @join_filters
    select distinct art_nickname, join_nickname, NULL
    from dbo.sysmergesubsetfilters
    where pubid = @pubid

    declare @level int
    select @level = 0

    while @level = 0 or @@rowcount > 0
    begin
        select @level = @level + 1

        update jf
        set jf.level = @level
        from @join_filters jf
        where jf.level is NULL
        and jf.join_nick not in (select art_nick from @join_filters jf2
                                    where jf2.level is NULL)
    end

    select @level = 0

    while @level = 0 or @@rowcount > 0
    begin
        select @level = @level - 1

        update jf
        set jf.level = @level
        from @join_filters jf
        where jf.level is NULL
        and jf.art_nick not in (select join_nick from @join_filters jf2
                                    where jf2.level is NULL)
    end

    if exists (select * from @join_filters where level is NULL)
    begin
        set @can_use_partition_groups = 0

        if @use_partition_groups in (1,2)
        begin

            raiserror(22515, 16, -1)
            return 1
        end

    end

    return 0

 
Last revision 2008RTM
See also

  sp_MScheck_dynamic_filters (Procedure)
sp_MSdrop_rladmin (Procedure)
       



News

  Query a named instance
Sybase+ASE+silent+install
SQL 2008 R2
Deprecated procedures in SQL2008
Reporting Services item-level role definitions
Create all your missing indexes
Converting datetime field
Start MSSQL Server Profiler at time
Replicating MSSQL Server views
Exploring Microsoft Sharepoint
The OLE DB provider "SQLNCLI10" for linked server indicates.
Mobile solar charger
Oracle to SQL Server replication
Cannot insert the value NULL into column
Undocumented Microsoft SQL Server 2008
VMware
Zoekmachine optimalisatie
SQL Servers hidden objects
FckEditor
Flash in Ajax
De hype die AJAX heet
Barcode scannen
MySQL; Gratis, makkelijk en snel!
PHP
sIFR; de combinatie tussen HTML en Flash