Update of /cvsroot/monetdb/MonetDB5/src/modules/mal/Tests
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv9593
Modified Files:
All remote04.mal
Added Files:
remote04.stable.err remote04.stable.out
Log Message:
The remote04 example illustrates the inline tuples and the pickup
using the io.import()
The latter requires a test, because currently it seems to assume
a void headed column, despite oids are being shipped.
--- NEW FILE: remote04.stable.err ---
stderr of test 'remote04` in directory 'src/modules/mal` itself:
# 04:46:54 >
# 04:46:54 > mserver5 "--config=/ufs/mk/monet5/Linux/etc/monetdb5.conf"
--debug=10 --set
"monet_mod_path=/ufs/mk/monet5//Linux/lib/MonetDB5:/ufs/mk/monet5//Linux/lib/MonetDB5/lib:/ufs/mk/monet5//Linux/lib/MonetDB5/bin"
--set "gdk_dbfarm=/ufs/mk/monet5//Linux/var/MonetDB5/dbfarm" --set
"sql_logdir=/ufs/mk/monet5//Linux/var/MonetDB5/sql_logs" --set mapi_open=true
--set xrpc_open=true --set mapi_port=30399 --set xrpc_port=41245 --set
monet_prompt= --trace --dbname=mTests_src_modules_mal remote04.mal
# 04:46:54 >
#warning: please don't forget to set your vault key!
#(see /ufs/mk/monet5/Linux/etc/monetdb5.conf)
# 04:46:54 >
# 04:46:54 > Done.
# 04:46:54 >
Index: All
===================================================================
RCS file: /cvsroot/monetdb/MonetDB5/src/modules/mal/Tests/All,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -d -r1.45 -r1.46
--- All 4 Oct 2007 13:08:04 -0000 1.45
+++ All 20 Jan 2008 03:57:54 -0000 1.46
@@ -37,6 +37,8 @@
remote01
remote02
remote03
+remote04
+remote05
xml00
xml01
--- NEW FILE: remote04.stable.out ---
stdout of test 'remote04` in directory 'src/modules/mal` itself:
# 04:46:54 >
# 04:46:54 > mserver5 "--config=/ufs/mk/monet5/Linux/etc/monetdb5.conf"
--debug=10 --set
"monet_mod_path=/ufs/mk/monet5//Linux/lib/MonetDB5:/ufs/mk/monet5//Linux/lib/MonetDB5/lib:/ufs/mk/monet5//Linux/lib/MonetDB5/bin"
--set "gdk_dbfarm=/ufs/mk/monet5//Linux/var/MonetDB5/dbfarm" --set
"sql_logdir=/ufs/mk/monet5//Linux/var/MonetDB5/sql_logs" --set mapi_open=true
--set xrpc_open=true --set mapi_port=30399 --set xrpc_port=41245 --set
monet_prompt= --trace --dbname=mTests_src_modules_mal remote04.mal
# 04:46:54 >
# MonetDB server v5.3.0, based on kernel v1.21.0
# Serving database 'mTests_src_modules_mal'
# Compiled for x86_64-redhat-linux-gnu/64bit with 64bit OIDs dynamically linked
# Copyright (c) 1993-2007 CWI, all rights reserved
# Visit http://monetdb.cwi.nl/ for further information
# Listening for connection requests on mapi:monetdb://gio.ins.cwi.nl:30399/
##this example tests recieving tuple values as part of the
##MAL interface.
#
#b:= bat.new(:oid,:int);
#[ [EMAIL PROTECTED], 1]
#
#c:= bat.new(:oid,:str);
#[ [EMAIL PROTECTED], "hello"]
#
#io.print(b);
#io.print(c);
#
function user.main():void; # 0 (main:void)
#this example tests recieving tuple values as part of the # 1 (_1:str)
#MAL interface. # 2 (_2:str)
b := bat.new(:oid,:int); # 3 CMDBATnew
(b:bat[:oid,:int])<-(_4:oid)(_5:int)
tuples := "/tmp/filevf4ZMd"; # 4 (tuples:str)<-(_8:str)
b := io.import(b,tuples); # 5 IOimport
(b:bat[:oid,:int])<-(b:bat[:oid,:int])(tuples:str)
c := bat.new(:oid,:str); # 6 CMDBATnew
(c:bat[:oid,:str])<-(_4:oid)(_10:str)
tuples := "/tmp/fileMx2CD3"; # 7 (tuples:str)<-(_13:str)
c := io.import(c,tuples); # 8 IOimport
(c:bat[:oid,:str])<-(c:bat[:oid,:str])(tuples:str)
io.print(b); # 9 IOprint_val (_14:void)<-(b:bat[:oid,:int])
io.print(c); # 10 IOprint_val (_15:void)<-(c:bat[:oid,:str])
end main; # 11
#-----------------#
# h t # name
# oid int # type
#-----------------#
[ [EMAIL PROTECTED], 1 ]
[ [EMAIL PROTECTED], 2 ]
#-------------------------#
# h t # name
# oid str # type
#-------------------------#
[ [EMAIL PROTECTED], "hello" ]
[ [EMAIL PROTECTED], "world" ]
# 04:46:54 >
# 04:46:54 > Done.
# 04:46:54 >
Index: remote04.mal
===================================================================
RCS file: /cvsroot/monetdb/MonetDB5/src/modules/mal/Tests/remote04.mal,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- remote04.mal 20 Jan 2008 02:05:30 -0000 1.1
+++ remote04.mal 20 Jan 2008 03:57:54 -0000 1.2
@@ -1,13 +1,15 @@
#this example tests recieving tuple values as part of the
#MAL interface.
-b:bat[:oid,:int]:=mserver.receive();
+b:= bat.new(:oid,:int);
[ [EMAIL PROTECTED], 1]
[ [EMAIL PROTECTED], 2]
+b:= io.import(b, tuples);
-c:bat[:oid,:str]:=mserver.receive();
+c:= bat.new(:oid,:str);
[ [EMAIL PROTECTED], "hello"]
[ [EMAIL PROTECTED], "world"]
+c:= io.import(c, tuples);
io.print(b);
io.print(c);
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Monetdb-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-checkins