Hi,
I'm trying to write a function in C++ and I thought I would just provide a
makefile for it in my custom folder in MonetDB/sql/backends/monet5/CUSTOM.
But it seems like all of the Makefiles in UDF sample are generated by the
bootstrap.
How do I get over this? I need to use external C++ libraries in the
makefile..
Thank you for help.
Best regards,
Jiri Nadvornik
Astronomical Institute AV CR
Stellar department
Czech Republic
<mailto:nadvornik.ji@gmail.com> nadvornik.ji(a)gmail.com
Hi,
I'm sorry for spamming so much, but I have to get more into the idea of BATs
before I will be a little more self-sufficient.
I need a function which takes two table columns as parameters. I would come
up with this MAL declaration:
command build_chunks(ra:bat[:oid,:dbl], dec:bat[:oid,:dbl], nside_low:int,
nside_high:int):bat[:oid,:oid]
address OSPSbuild_chunks
comment "Build HEALPix groups for further processing.";
It should take ra, dec parameters (from my DB table) and then some integer
parameters. I guess it should return an oid, because all it does is that it
should write some computed result (multiple rows) to another table. I have
still no idea how I will do that, but I feel I'm getting closer J.
The function produces a c++ vector of some integers, which I want to write
down to another table.
Is that MAL declaration looking correct? How should I call that function? I
understand that SELECT reverse('hello'), but I don't know when the parameter
is passed from a query.
Thank you very much for pointing me in the right direction.
Best regards,
Jiri Nadvornik
Astronomical Institute AV CR
Stellar department
Czech Republic
<mailto:nadvornik.ji@gmail.com> nadvornik.ji(a)gmail.com
Hi,
When I download the source code from mercurial and run:
1. bootstrap, configure, make, make install
2. monetdbd start myFarm, mclient demo
3. sql>select 'hello',reverse('hello');
The output is:
SELECT: no such unary operator 'reverse(char)'
What can be wrong here? I had the original installation from packages, then
I apt-get removed them and installed via the make install.
Any ideas appreciated.
Best regards,
Jiri Nadvornik
Astronomical Institute AV CR
Stellar department
Czech Republic
<mailto:nadvornik.ji@gmail.com> nadvornik.ji(a)gmail.com
Hi All,
I have one table with data that can be grouped easily. I need to iterate
over these groups, count their members and distribute them uniformly over
the database nodes (physically).
If I have three groups A, B, C of size (1, 1, 2) and two physical nodes - I
want A,B to be on node no. 1 and C on the node no. 2.
The question is quite simple. Is it possible?
Jiri Nadvornik
Astronomical Institute AV CR
Stellar department
Czech Republic
<mailto:nadvornik.ji@gmail.com> nadvornik.ji(a)gmail.com
Hi,
We are facing problems with COPY INTO .. FROM STDIN and an auto increment column, which is the primary key column in the table.
The client is our own java client.
If we don't set any value for this column (which is our expected constellation) there is neither error nor exception,
but no record is inserted into the table.
A try with a null value for this column produces the same result (no exception, no record in the table)
The only way to insert records is to set the proper value for the column, but it is not the supposed behavior of an auto increment column, isn't it?
Best regards,
Fadila
Hi,
Is there any way to get the SQL query as a string from the
PreparedStatement of MonetDB??
(Like in some DBs, toString will give the SQL string)
Any help much appreciated. Thanks in advance.
Thanks & Regards,
Vijayakrishna.P.
Mobile : (+91) 9500402305.
The Aggregate count function doesn't work with the over clause in MonetDB. I am a new user on MonetDB, and have trouble using queries running on other databases like Postgres on MonetDB.
When using the Count function with Over clause I get the following error:
sql>select count(id) over() from sample_table ;SELECT: function 'count' not found
Regards, Ameya
Hi all,
I'm trying to understand the example of user defined functions in MonetDB
(https://www.monetdb.org/Documentation/Cookbooks/SQLrecipes/UserDefinedFunct
ion).
I understand the concept for just reversing a string.
But what about working with tabular data? I'd like to pass to this C
function a whole table (list of rows) and then return another table(s)/write
result data to other tables.
What is the correct way of doing this? Can I pass some kind of arrays to the
C function? Can I return these arrays from a function?
Or is it possible to query the DB directly from the C script?
Thank you very much for some answers.
Best regards,
Jiri Nadvornik
Astronomical Institute AV CR
Stellar department
Czech Republic
<mailto:nadvornik.ji@gmail.com> nadvornik.ji(a)gmail.com
hello dear all,
I'm trying to understand an execution plan generated in MAL by monetDB.
I would like to how exactlly the following functions works :
- sql.mvc
- algebra.subselect
- sql.bind
- sql.subdelta
- algebra.leftfetchjoin
Best regards,