1 Reply Latest reply on Oct 18, 2018 8:41 AM by Sam Sam

    Query for searching Empty Settings

    Sam Sam

      In addition to: https://forum.solidworks.com/thread/225454

       

      I tried to change query for searching of failures in Settings:

       

      - for the current Vault:

       

      SELECT Users.Username, Users.UserID, Settings.VarID, Settings.Value

      FROM Users

      INNER JOIN Settings ON Users.UserID = Settings.UserID

      WHERE (Settings.VarID <44) AND (Users.Enabled = 1) AND (Settings.Value IS NULL)

       

      - for the specified Vault:

       

      SELECT Users.Username, Users.UserID, Settings.VarID, Settings.Value

      FROM [Test].[dbo].[Users]

      INNER JOIN Settings ON Users.UserID = Settings.UserID

      WHERE (Settings.VarID <44) AND (Users.Enabled = 1) AND (Settings.Value IS NULL)

       

      For check I wrote down NULL value. Everything works.

      How it is necessary to change query that showed only empty cells?

      And it is even better - only empty cells in all Vaults?

        • Re: Query for searching Empty Settings
          Sam Sam

          I already resolved a part of an issue:

           

          SELECT Users.Username, Users.UserID, Settings.VarID, Settings.Value

           

          FROM [Test].[dbo].[Users]

           

          INNER JOIN Settings ON Users.UserID = Settings.UserID

           

          WHERE (Settings.VarID =6) AND (Users.Enabled = 1) AND (Settings.Value like '')

          or (Settings.VarID =7) AND (Users.Enabled = 1) AND (Settings.Value like '')

          or (Settings.VarID =16) AND (Users.Enabled = 1) AND (Settings.Value like '')

          or (Settings.VarID =21) AND (Users.Enabled = 1) AND (Settings.Value like '')

           

          Remained a question as it to make in all Vaults?