utils/check-status.js
function addInsert(agent) {
/*
    `id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
    `userAgent` VARCHAR(255) NOT NULL,
    `agentGroup_id` INT UNSIGNED NOT NULL DEFAULT '1',
    `agentSource_id` INT UNSIGNED NOT NULL DEFAULT '1',
    `timesReported` INT UNSIGNED NOT NULL DEFAULT '1',
    `status` TINYINT UNSIGNED NOT NULL DEFAULT '0',
    `description` TEXT,
    `created` DATETIME NULL,
    `modified` DATETIME NULL,
*/
    console.log("INSERT INTO `Agents` VALUES (NULL, '" + 
                quote(agent.agent) + "', '" +
                agent.groupId + "', '" +
                agent.sourceId + 
                "', '0', '0', '', NOW(), NOW());");
}
function addInsert(agent) {
/*
    `id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
    `userAgent` VARCHAR(255) NOT NULL,
    `agentGroup_id` INT UNSIGNED NOT NULL DEFAULT '1',
    `agentSource_id` INT UNSIGNED NOT NULL DEFAULT '1',
    `timesReported` INT UNSIGNED NOT NULL DEFAULT '1',
    `status` TINYINT UNSIGNED NOT NULL DEFAULT '0',
    `description` TEXT,
    `created` DATETIME NULL,
    `modified` DATETIME NULL,
*/
    console.log("INSERT INTO `Agents` VALUES (NULL, '" + 
                quote(agent.agent) + "', '" +
                agent.groupId + "', '" +
                agent.sourceId + 
                "', '0', '0', '', NOW(), NOW());");
}
function addInsert ( agent ) { /*
    `id` INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
    `userAgent` VARCHAR(255) NOT NULL,
    `agentGroup_id` INT UNSIGNED NOT NULL DEFAULT '1',
    `agentSource_id` INT UNSIGNED NOT NULL DEFAULT '1',
    `timesReported` INT UNSIGNED NOT NULL DEFAULT '1',
    `status` TINYINT UNSIGNED NOT NULL DEFAULT '0',
    `description` TEXT,
    `created` DATETIME NULL,
    `modified` DATETIME NULL,
*/ console . log ( "INSERT INTO `Agents` VALUES (NULL, '" + quote ( agent . agent ) + "', '" + agent . groupId + "', '" + agent . sourceId + "', '0', '0', '', NOW(), NOW());" ) ; }
create an INSERT statement to add a user-agent.
This is normally not needed since the agents.json file comes from
the database to which the data would be inserted.
create an INSERT statement to add a user - agent . This is normally not needed since the agents . json file comes from the database to which the data would be inserted .