CSV Data Processor which evaluates and process data faster by using OpenMP
A lightweight CLI tool to query, aggregate, and update numeric CSV files directly from the terminal.
- Automatically loads
file.csvfrom the working directory - First row = column names
- Remaining rows = numeric data (
double) - Commands can be chained using
|(pipe operator) - Uses OpenMP for fast execution
When started, it prints the list of columns and shows a prompt:
Welcome to csv-data-processor
csv-data-processor>>>
a(<column>, <start>, <end>)
Sums values in a column from row start to end.
Use * to mean full coverage.
Examples:
a(SALARY,0,99)
a(PRICE,*,*)
ca(<column>, <condition>)
Filters cells based on a condition and sums the matching ones.
x refers to the current cell value.
Examples:
ca(SALARY, x>50000)
ca(AGE, x>=18 && x<=60)
u(<column>, <start>, <end>, <expression-or-value>)
Updates values in a given range.
- Expression uses
xas the old value - Or assign constant values
Examples:
u(SALARY,0,*, 50000)
u(AGE,*,*, x+1)
cu(<column>, <condition>, <expression-or-value>)
Only updates rows where the condition evaluates true.
Examples:
cu(SALARY, x<30000, x*1.2)
cu(AGE, x<18, 18)
s(<col1 col2 col3>, <start>, <end>)
Displays selected columns in table format.
Example:
s(ID NAME SALARY,*,*)
Note: Current version prints entire dataset ignoring range args.
commit
Saves data back to file.csv and ends program.
exit
Quits and discards unsaved changes.
After running commands (single or chained), tool prints:
-
Execution Time (in seconds)
-
Compact result table:
- 1st row: commands executed
- 2nd row: result per command
(
sum,Nullfor update,Errorif failed)
Ensure a C++ compiler with OpenMP is available.
Run:
./parallel.shYour file.csv must be placed in the executable directory.
ID,AGE,SALARY
1,22,40000
2,35,65000
3,29,52000
| Feature | Status |
|---|---|
| Range aggregation | |
| Conditional aggregation | |
| Range update | |
| Conditional update | |
| Parallel execution | |
| Save back to CSV | |
| Table output | |
| Command chaining |
Provides a fast and simple way to manipulate numeric CSV datasets without needing SQL or heavy spreadsheet tools — ideal for bulk analytics and quick data experiments.