nie, wpisz dokładnie tak jak jest
# mysql -uroot -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 32406 Server version: 5.0.44-log Gentoo Linux mysql-5.0.44-r1
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> CREATE FUNCTION lms_current_user() RETURNS int(11) NO SQL RETURN @lms_current_user; ERROR 1046 (3D000): No database selected mysql> use lmsutf8 Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A
Database changed mysql> CREATE FUNCTION lms_current_user() RETURNS int(11) NO SQL RETURN @lms_current_user; Query OK, 0 rows affected (0.00 sec)
mysql> CREATE VIEW customersview AS SELECT c.* FROM customers c WHERE NOT EXISTS ( SELECT 1 FROM customerassignments a JOIN excludedgroups e ON (a.customergroupid = e.customergroupid) WHERE e.userid = lms_current_user() AND a.customerid = c.id) -> ; Query OK, 0 rows affected (0.01 sec)
błędów nie widzę przy wykonaniu...
_______________________________________________ lms mailing list lms@lists.lms.org.pl http://lists.lms.org.pl/mailman/listinfo/lms