projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
b367563
)
MOVED mysql/project_get_type.sql to mysql/core_project_get_type.sql
author
Alan Knowles
<alan@roojs.com>
Tue, 11 Oct 2016 03:09:41 +0000
(11:09 +0800)
committer
Alan Knowles
<alan@roojs.com>
Tue, 11 Oct 2016 03:09:41 +0000
(11:09 +0800)
mysql/core_project_get_type.sql
[new file with mode: 0644]
patch
|
blob
diff --git a/mysql/core_project_get_type.sql
b/mysql/core_project_get_type.sql
new file mode 100644
(file)
index 0000000..
f4a757e
--- /dev/null
+++ b/
mysql/core_project_get_type.sql
@@ -0,0
+1,11
@@
+
+DROP FUNCTION IF EXISTS project_get_type;
+DELIMITER $$
+CREATE FUNCTION project_get_type(in_id INT(11)) RETURNS VARCHAR(2) DETERMINISTIC
+ BEGIN
+ DECLARE v_ret VARCHAR(2);
+ SET v_ret= '';
+ SELECT type INTO v_ret FROM Projects WHERE id = in_id LIMIT 1;
+ RETURN v_ret;
+ END $$
+DELIMITER ;
\ No newline at end of file