• Recent
    • Tags
    • Popular
    • Register
    • Login

    Please Note This forum exists for community support for the Mango product family and the Radix IoT Platform. Although Radix IoT employees participate in this forum from time to time, there is no guarantee of a response to anything posted here, nor can Radix IoT, LLC guarantee the accuracy of any information expressed or conveyed. Specific project questions from customers with active support contracts are asked to send requests to support@radixiot.com.

    Radix IoT Website Mango 3 Documentation Website Mango 4 Documentation Website Mango 5 Documentation Website

    How to move a point from one data source to another?

    How-To
    2
    8
    1.5k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • P
      Phillip Weeks
      last edited by

      I wonder if someone might provide and a method & explanation on moving a group of points from a modbus IP data source to another modbus IP datasource? I can add datapoints to a datasource through the import but if I wish to remove them from one and create them in another is this even possible? I am prepared to lose the points history and just move the xid, ie. delete and create, so can I delete the points from the datasource without issue?

      1 Reply Last reply Reply Quote 0
      • phildunlapP
        phildunlap
        last edited by

        Hi Phillip,

        Joel gave some good instructions in this thread: https://forum.infiniteautomation.com/topic/2055/changing-datasource-of-datapoint

        I think the only thing he may have left out was to disable the data sources before moving the points, then re-enable them (or just disable and re-enable the points, but that's more clicking)

        1 Reply Last reply Reply Quote 0
        • P
          Phillip Weeks
          last edited by

          so Phil would this be correct SQL to move points with these names from DS 6 to 10..
          update datapoints set DataSourceID = 10 where ((DataSourceID = 6) AND (name = 'FLOW_MIN LPM' OR name = 'FLOW_MAX LPM'));

          1 Reply Last reply Reply Quote 0
          • phildunlapP
            phildunlap
            last edited by

            That does appear to be valid SQL.

            1 Reply Last reply Reply Quote 0
            • P
              Phillip Weeks
              last edited by

              this is the result..
              org.h2.jdbc.JdbcSQLException: Method is only allowed for a query. Use execute or executeUpdate instead of executeQuery; SQL statement: update datapoints set DataSourceID = 10 where ((DataSourceID = 6) and (name = 'FLOW_MIN LPM' or name = 'FLOW_MAX LPM')); [90002-196]

              1 Reply Last reply Reply Quote 0
              • P
                Phillip Weeks
                last edited by Phillip Weeks

                Shoot I didn't have the source disabled.. that was not the issue.
                so should I use executeupdate instead of update

                1 Reply Last reply Reply Quote 0
                • phildunlapP
                  phildunlap
                  last edited by phildunlap

                  You can just disable and enable the points / sources after the fact or at worst restart Mango. That is not why the command failed, it sounds like you are hitting the 'submit query' button instead of 'submit update'. Best practice is disabling before moving.

                  1 Reply Last reply Reply Quote 0
                  • P
                    Phillip Weeks
                    last edited by

                    That was it Thank you all good now, Phewf :)

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post