MobilityDB 1.3
Loading...
Searching...
No Matches
Macros | Functions
tbl_value_value.c File Reference

A simple program that reads two CSV files containing non-temporal values and applies a function to them. More...

#include <stdio.h>
#include <stdlib.h>
#include <meos.h>
#include <meos_geo.h>
#include <meos_cbuffer.h>
#include <meos_npoint.h>
#include <meos_pose.h>

Macros

#define MAX_LENGTH_HEADER   1024
 
#define MAX_LENGTH_TEMP   8192
 
#define MAX_LENGTH_VALUE   12001
 

Functions

int main (void)
 

Detailed Description

A simple program that reads two CSV files containing non-temporal values and applies a function to them.

The corresponding SQL query would be

SELECT t1.k, t2.k, array_length(timeSpans(t, i), 1)
FROM tbl_tstzspanset t1, tbl_interval t2
WHERE timeSpans(t, i) IS NOT NULL;

The program can be build as follows

gcc -Wall -g -I/usr/local/include -o tbl_value_value tbl_value_value.c -L/usr/local/lib -lmeos