Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trying to query direct on a CSV file doesn't work if using payload as the filename #39

Open
TotallyInformation opened this issue Oct 6, 2020 · 1 comment

Comments

@TotallyInformation
Copy link

TotallyInformation commented Oct 6, 2020

I have a query that works perfectly if I put it in the query window. But if I try to move the filename to msg.payload (using the inject node) and use either FROM ? or FROM $0, it doesn't work. There is no error but zero records are returned.

This works:

SELECT * 
FROM 'C:/Users/xxxxx/Staff List for COVID19 21Sep20.csv'
WHERE Employee_Last_Name = "Knight"

This does not (where msg.payload = 'C:/Users/xxxxx/Staff List for COVID19 21Sep20.csv') :

SELECT * 
FROM ?
WHERE Employee_Last_Name = "Knight"

Neither does this:

SELECT * 
FROM $0
WHERE Employee_Last_Name = "Knight"

This, however, does work (where msg.payload = 'Knight'):

SELECT * 
FROM 'C:/Users/xxxxx/Staff List for COVID19 21Sep20.csv'
WHERE Employee_Last_Name = $0
@mathiasrw
Copy link
Member

Hmm. Interesting usecase. I cant look into it the next weeks - but will flag it as something to be addressed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants