zrhoffman commented on code in PR #6569:
URL: https://github.com/apache/trafficcontrol/pull/6569#discussion_r848625167


##########
traffic_ops/traffic_ops_golang/server/servers.go:
##########
@@ -214,43 +218,11 @@ INSERT INTO server (
        :status_id,
        :tcp_port,
        :server_type_id,
-       :upd_pending,
        :xmpp_id,
        :xmpp_passwd,
        :status_last_updated
 ) RETURNING
-       (SELECT name FROM cachegroup WHERE cachegroup.id=server.cachegroup) AS 
cachegroup,
-       cachegroup AS cachegroup_id,
-       cdn_id,
-       (SELECT name FROM cdn WHERE cdn.id=server.cdn_id) AS cdn_name,
-       domain_name,
-       guid,
-       host_name,
-       https_port,
-       id,
-       ilo_ip_address,
-       ilo_ip_gateway,
-       ilo_ip_netmask,
-       ilo_password,
-       ilo_username,
-       last_updated,
-       mgmt_ip_address,
-       mgmt_ip_gateway,
-       mgmt_ip_netmask,
-       offline_reason,
-       (SELECT name FROM phys_location WHERE 
phys_location.id=server.phys_location) AS phys_location,
-       phys_location AS phys_location_id,
-       profile AS profile_id,
-       (SELECT description FROM profile WHERE profile.id=server.profile) AS 
profile_desc,
-       (SELECT name FROM profile WHERE profile.id=server.profile) AS profile,
-       rack,
-       reval_pending,
-       (SELECT name FROM status WHERE status.id=server.status) AS status,
-       status AS status_id,
-       tcp_port,
-       (SELECT name FROM type WHERE type.id=server.type) AS server_type,
-       type AS server_type_id,
-       upd_pending
+       id

Review Comment:
   > I could revisit this approach and revert this change now that the columns 
are in the `server` table.
   
   @TaylorCFrey This change causes more conflicts than may be necessary with 
@rimashah25's #6569 PR. AFAIK #6569 plans to add them back now



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to