-- -------------------------------------------------------- -- Hoszt: 127.0.0.1 -- Szerver verzió: 10.4.11-MariaDB - mariadb.org binary distribution -- Szerver OS: Win64 -- HeidiSQL Verzió: 12.3.0.6589 -- -------------------------------------------------------- /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET NAMES utf8 */; /*!50503 SET NAMES utf8mb4 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- Struktúra mentése tábla aitrainer2. app_text CREATE TABLE IF NOT EXISTS `app_text` ( `text_id` int(13) NOT NULL AUTO_INCREMENT, `text_key` mediumtext DEFAULT NULL, `screenshot_url` char(200) DEFAULT NULL, `checked` tinyint(1) DEFAULT 0, PRIMARY KEY (`text_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. app_text_translation CREATE TABLE IF NOT EXISTS `app_text_translation` ( `translation_id` int(13) NOT NULL AUTO_INCREMENT, `text_id` int(11) NOT NULL, `language_code` char(2) NOT NULL DEFAULT 'en', `translation` char(50) DEFAULT NULL, PRIMARY KEY (`translation_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; -- Az adatok exportálása nem lett kiválasztva. -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. configuration CREATE TABLE IF NOT EXISTS `configuration` ( `configuration_id` int(11) NOT NULL AUTO_INCREMENT, `config_key` char(50) COLLATE utf8_hungarian_ci DEFAULT NULL, `config_value` char(50) COLLATE utf8_hungarian_ci DEFAULT NULL, `date_add` datetime DEFAULT NULL, `date_change` datetime DEFAULT NULL, PRIMARY KEY (`configuration_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. customer CREATE TABLE IF NOT EXISTS `customer` ( `customer_id` int(11) NOT NULL AUTO_INCREMENT, `name` char(100) COLLATE utf8_hungarian_ci NOT NULL, `firstname` char(100) COLLATE utf8_hungarian_ci NOT NULL, `email` char(100) COLLATE utf8_hungarian_ci DEFAULT NULL, `password` char(100) COLLATE utf8_hungarian_ci DEFAULT NULL, `sex` enum('m','w') COLLATE utf8_hungarian_ci DEFAULT 'm', `age` tinyint(4) DEFAULT NULL, `active` enum('Y','N','D','S') COLLATE utf8_hungarian_ci DEFAULT 'N', `date_add` datetime DEFAULT NULL, `date_change` datetime DEFAULT NULL, `data_policy_allowed` tinyint(4) DEFAULT 1, `admin` tinyint(4) DEFAULT 0, `trainer` tinyint(4) DEFAULT 0, `trainer_id` int(11) DEFAULT 0, `birth_year` int(4) DEFAULT 0, `weight` int(3) DEFAULT 0, `goal` char(250) COLLATE utf8_hungarian_ci DEFAULT '', `fitness_level` enum('beginner','intermediate','advanced','professional') COLLATE utf8_hungarian_ci NOT NULL DEFAULT 'beginner', `body_type` enum('ectomorph','mesomorph','endomorph') COLLATE utf8_hungarian_ci DEFAULT NULL, `firebase_uid` char(200) COLLATE utf8_hungarian_ci DEFAULT NULL, `sport_id` int(13) DEFAULT NULL, `email_subscription` tinyint(1) DEFAULT NULL, `synced_date` datetime DEFAULT NULL, `trial_date` datetime DEFAULT NULL, `firebase_reg_token` text COLLATE utf8_hungarian_ci DEFAULT NULL, `lang` char(5) COLLATE utf8_hungarian_ci DEFAULT NULL, `phone` char(50) COLLATE utf8_hungarian_ci DEFAULT NULL, `life_long` tinyint(4) DEFAULT NULL, `lang_sync` datetime DEFAULT NULL, PRIMARY KEY (`customer_id`), UNIQUE KEY `firebase_uid` (`firebase_uid`), KEY `firebase_reg_token` (`firebase_reg_token`(1024)), KEY `sport_id` (`sport_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Struktúra mentése tábla aitrainer2. customer_conversation CREATE TABLE IF NOT EXISTS `customer_conversation` ( `id` int(11) NOT NULL AUTO_INCREMENT, `customer_id` int(11) NOT NULL DEFAULT 0, `conversation_date` datetime DEFAULT NULL, `question` text COLLATE utf8_hungarian_ci DEFAULT NULL, `answer` text COLLATE utf8_hungarian_ci DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. customer_membership CREATE TABLE IF NOT EXISTS `customer_membership` ( `id` int(11) NOT NULL AUTO_INCREMENT, `customer_id` int(11) NOT NULL DEFAULT 0, `membership_id` int(11) NOT NULL DEFAULT 0, `start_date` datetime DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE, KEY `customer_id` (`customer_id`) USING BTREE, KEY `membership_id` (`membership_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. customer_property CREATE TABLE IF NOT EXISTS `customer_property` ( `customer_property_id` int(10) unsigned NOT NULL AUTO_INCREMENT, `customer_id` int(10) unsigned NOT NULL DEFAULT 0, `property_id` int(10) unsigned NOT NULL DEFAULT 0, `property_value` double unsigned NOT NULL DEFAULT 0, `date_add` datetime DEFAULT NULL, `goal` tinyint(4) DEFAULT 0, `goal_date` date DEFAULT NULL, PRIMARY KEY (`customer_property_id`), KEY `property_id` (`property_id`), KEY `customer_id` (`customer_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. diet CREATE TABLE IF NOT EXISTS `diet` ( `diet_id` int(11) NOT NULL AUTO_INCREMENT, `diet_user_id` int(11) NOT NULL DEFAULT 0, `diet_text` text COLLATE utf8_hungarian_ci DEFAULT NULL, PRIMARY KEY (`diet_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. diet_meal CREATE TABLE IF NOT EXISTS `diet_meal` ( `id` int(11) NOT NULL AUTO_INCREMENT, `diet_id` int(11) DEFAULT NULL, `meal_name` char(100) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '0' COMMENT 'i.e. monday|breakfast', `meal` char(250) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '0', PRIMARY KEY (`id`), KEY `meal_name` (`meal_name`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. diet_raw_material CREATE TABLE IF NOT EXISTS `diet_raw_material` ( `id` int(11) NOT NULL AUTO_INCREMENT, `diet_meal_id` int(11) NOT NULL DEFAULT 0, `raw_material_id` int(11) DEFAULT 0, `kcal_min` int(11) DEFAULT 0, `kcal_max` int(11) DEFAULT 0, `protein_min` int(11) DEFAULT 0, `protein_max` int(11) DEFAULT 0, `ch_min` int(11) DEFAULT 0, `ch_max` int(11) DEFAULT 0, `fat_min` int(11) DEFAULT 0, `fat_max` int(11) DEFAULT 0, `sugar` int(11) DEFAULT 0, `name` char(50) COLLATE utf8_hungarian_ci DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. diet_sensitivity CREATE TABLE IF NOT EXISTS `diet_sensitivity` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` char(100) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '0', PRIMARY KEY (`id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. diet_user CREATE TABLE IF NOT EXISTS `diet_user` ( `diet_user_id` int(11) NOT NULL AUTO_INCREMENT, `customer_id` int(11) NOT NULL DEFAULT 0, PRIMARY KEY (`diet_user_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. diet_user_consumption CREATE TABLE IF NOT EXISTS `diet_user_consumption` ( `id` int(11) NOT NULL AUTO_INCREMENT, `diet_user_id` int(11) NOT NULL, `raw_material_id` int(11) NOT NULL DEFAULT 0, `date_consumption` datetime NOT NULL, `name` char(100) COLLATE utf8_hungarian_ci DEFAULT NULL, `quantity` double NOT NULL DEFAULT 0, `quantity_unit` char(10) COLLATE utf8_hungarian_ci DEFAULT NULL, `cal` int(11) DEFAULT NULL, `protein` double DEFAULT NULL, `fat` double DEFAULT NULL, `ch` double DEFAULT NULL, `sugar` double DEFAULT NULL, PRIMARY KEY (`id`), KEY `diet_user_id` (`diet_user_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. diet_user_preference CREATE TABLE IF NOT EXISTS `diet_user_preference` ( `id` int(11) NOT NULL AUTO_INCREMENT, `diet_user_id` int(11) NOT NULL DEFAULT 0, `raw_material_id` int(11) NOT NULL DEFAULT 0, `temperature` decimal(1,0) NOT NULL DEFAULT 0, PRIMARY KEY (`id`) USING BTREE, KEY `diet_user_id` (`diet_user_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. diet_user_sensitivity CREATE TABLE IF NOT EXISTS `diet_user_sensitivity` ( `id` int(11) NOT NULL AUTO_INCREMENT, `sensitivity_id` int(11) NOT NULL DEFAULT 0, `diet_user_id` int(11) NOT NULL DEFAULT 0, PRIMARY KEY (`id`), KEY `diet_user_id` (`diet_user_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. faq CREATE TABLE IF NOT EXISTS `faq` ( `faq_id` int(11) NOT NULL AUTO_INCREMENT, `name` char(200) COLLATE utf8_hungarian_ci NOT NULL, `description` text COLLATE utf8_hungarian_ci DEFAULT NULL, `sort` int(11) DEFAULT NULL, PRIMARY KEY (`faq_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. faq_translation CREATE TABLE IF NOT EXISTS `faq_translation` ( `translation_id` int(11) NOT NULL AUTO_INCREMENT, `faq_id` int(11) NOT NULL DEFAULT 0, `name_translation` char(200) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '0', `description_translation` text COLLATE utf8_hungarian_ci DEFAULT NULL, `language_code` char(2) COLLATE utf8_hungarian_ci DEFAULT 'en', PRIMARY KEY (`translation_id`) USING BTREE, KEY `faq_id` (`faq_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Struktúra mentése tábla aitrainer2. membership CREATE TABLE IF NOT EXISTS `membership` ( `membership_id` int(11) NOT NULL AUTO_INCREMENT, `name` char(100) CHARACTER SET utf8mb4 NOT NULL, `description` char(200) CHARACTER SET utf8mb4 DEFAULT NULL, `duration` int(11) DEFAULT NULL, `duration_type` enum('free','subscription','lifetime','limited') CHARACTER SET utf8mb4 DEFAULT NULL, `duration_unit` enum('day','week','month','year') COLLATE utf8_hungarian_ci DEFAULT NULL, `training_plan_id` int(11) DEFAULT 0, `training_plan_day_ids` char(50) COLLATE utf8_hungarian_ci DEFAULT NULL, PRIMARY KEY (`membership_id`) USING BTREE, KEY `training_plan_id` (`training_plan_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. notification CREATE TABLE IF NOT EXISTS `notification` ( `notification_id` int(11) NOT NULL AUTO_INCREMENT, `internal_name` char(50) COLLATE utf8_hungarian_ci DEFAULT NULL, `internal_description` mediumtext COLLATE utf8_hungarian_ci DEFAULT NULL, `message_title` char(50) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '', `message_body` char(100) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '', `image_url` char(100) COLLATE utf8_hungarian_ci DEFAULT '', `schedule_date` datetime DEFAULT NULL, `schedule_hook` char(100) COLLATE utf8_hungarian_ci DEFAULT NULL, `schedule_sql` mediumtext COLLATE utf8_hungarian_ci DEFAULT NULL, `active` tinyint(1) DEFAULT 0, PRIMARY KEY (`notification_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. notification_history CREATE TABLE IF NOT EXISTS `notification_history` ( `notification_history_id` int(11) NOT NULL AUTO_INCREMENT, `notification_id` int(11) NOT NULL, `customer_id` int(11) NOT NULL, `response` char(255) COLLATE utf8_hungarian_ci DEFAULT NULL, `notification_date` datetime DEFAULT NULL, PRIMARY KEY (`notification_history_id`), KEY `notification_id` (`notification_id`), KEY `customer_id` (`customer_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. product CREATE TABLE IF NOT EXISTS `product` ( `product_id` int(11) NOT NULL AUTO_INCREMENT, `name` char(50) NOT NULL, `description` mediumtext DEFAULT NULL, `app_version` char(50) NOT NULL, `product_set` int(5) NOT NULL, `sort` int(5) NOT NULL, `type` enum('subscription','in-app-currency') NOT NULL DEFAULT 'subscription', `valid_from` date DEFAULT NULL, `valid_to` date DEFAULT NULL, `product_id_ios` char(50) DEFAULT NULL, `product_id_android` char(50) DEFAULT NULL, `price_ios` float DEFAULT NULL, `price_android` float DEFAULT NULL, PRIMARY KEY (`product_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; -- Struktúra mentése tábla aitrainer2. property CREATE TABLE IF NOT EXISTS `property` ( `property_id` int(11) NOT NULL AUTO_INCREMENT, `property_name` char(50) COLLATE utf8_hungarian_ci DEFAULT NULL, `property_unit` char(50) COLLATE utf8_hungarian_ci DEFAULT NULL, PRIMARY KEY (`property_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. property_translation CREATE TABLE IF NOT EXISTS `property_translation` ( `translation_id` int(13) NOT NULL AUTO_INCREMENT, `language_code` char(2) NOT NULL DEFAULT 'en', `property_id` int(13) NOT NULL DEFAULT 0, `property_name` char(50) DEFAULT NULL, PRIMARY KEY (`translation_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. purchase CREATE TABLE IF NOT EXISTS `purchase` ( `purchase_id` int(11) NOT NULL AUTO_INCREMENT, `customer_id` int(11) NOT NULL DEFAULT 0, `product_id` int(11) NOT NULL DEFAULT 0, `date_add` datetime DEFAULT NULL, `purchase_sum` double(22,0) DEFAULT NULL, `currency` char(3) DEFAULT NULL, `expiring` datetime DEFAULT NULL, PRIMARY KEY (`purchase_id`) USING BTREE, KEY `customer_id` (`customer_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. raw_material CREATE TABLE IF NOT EXISTS `raw_material` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` char(100) COLLATE utf8_hungarian_ci NOT NULL, `description` text COLLATE utf8_hungarian_ci DEFAULT NULL, `kcal_min` int(11) DEFAULT 0, `kcal_max` int(11) DEFAULT 0, `protein_min` int(11) DEFAULT 0, `protein_max` int(11) DEFAULT 0, `ch_min` int(11) DEFAULT 0, `ch_max` int(11) DEFAULT 0, `fat_min` int(11) DEFAULT 0, `fat_max` int(11) DEFAULT 0, `sugar` int(11) DEFAULT 0, `store_id` int(11) DEFAULT 0, PRIMARY KEY (`id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci ROW_FORMAT=DYNAMIC; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. recipe CREATE TABLE IF NOT EXISTS `recipe` ( `recipe_id` int(11) NOT NULL AUTO_INCREMENT, `name` char(250) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '', `description` text COLLATE utf8_hungarian_ci DEFAULT NULL, `cal` int(11) DEFAULT NULL, `protein` double DEFAULT NULL, `fat` double DEFAULT NULL, `ch` double DEFAULT NULL, `diet_user_id` int(11) DEFAULT 0, PRIMARY KEY (`recipe_id`) USING BTREE, KEY `name` (`name`), KEY `diet_user_id` (`diet_user_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. recipe_raw_material CREATE TABLE IF NOT EXISTS `recipe_raw_material` ( `id` int(11) NOT NULL AUTO_INCREMENT, `raw_material_id` int(11) NOT NULL DEFAULT 0, `recipe_id` int(11) NOT NULL DEFAULT 0, `quantity` int(11) DEFAULT 0, `quantity_unit` char(10) COLLATE utf8_hungarian_ci DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. store CREATE TABLE IF NOT EXISTS `store` ( `store_id` int(11) NOT NULL AUTO_INCREMENT, `store_name` char(50) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '', `country` char(4) COLLATE utf8_hungarian_ci NOT NULL DEFAULT '', PRIMARY KEY (`store_id`), KEY `store_name` (`store_name`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; -- Az adatok exportálása nem lett kiválasztva. -- Struktúra mentése tábla aitrainer2. tracking CREATE TABLE IF NOT EXISTS `tracking` ( `tracking_id` int(20) NOT NULL AUTO_INCREMENT, `customer_id` int(20) NOT NULL DEFAULT 0, `date_add` datetime NOT NULL, `event` char(100) COLLATE utf8_hungarian_ci DEFAULT NULL, `event_value` text COLLATE utf8_hungarian_ci DEFAULT NULL, `area` char(100) COLLATE utf8_hungarian_ci DEFAULT NULL, `platform` char(20) COLLATE utf8_hungarian_ci DEFAULT NULL, `version` char(20) COLLATE utf8_hungarian_ci DEFAULT NULL, PRIMARY KEY (`tracking_id`) USING BTREE, KEY `customer_id` (`customer_id`), KEY `event` (`event`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_hungarian_ci; INSERT INTO `customer` VALUES (54, 'Dummy User', '', 'bosi', '$2a$10$thOc8jS750c7xe9U9Qq3GuSPs/H0Pt2Ads05yzUlyzQBIj.Rk9QCy', 'm', 0, 'N', NULL, NULL, 1, 1, 0, 0, 0, 0, '', 'beginner', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); /*!40103 SET TIME_ZONE=IFNULL(@OLD_TIME_ZONE, 'system') */; /*!40101 SET SQL_MODE=IFNULL(@OLD_SQL_MODE, '') */; /*!40014 SET FOREIGN_KEY_CHECKS=IFNULL(@OLD_FOREIGN_KEY_CHECKS, 1) */; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40111 SET SQL_NOTES=IFNULL(@OLD_SQL_NOTES, 1) */;