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

Not able to convert sql query to es #3

Closed
janakiram0035 opened this issue Jul 23, 2018 · 5 comments
Closed

Not able to convert sql query to es #3

janakiram0035 opened this issue Jul 23, 2018 · 5 comments

Comments

@janakiram0035
Copy link

janakiram0035 commented Jul 23, 2018

Hi drewbo,

I am installing sqltoes in my system, it is showing like 5 packages added but when i cal the sqlToEs function with the query you have given it showing error message as zsh: missing delimiter for 'u' glob qualifier.

Can you help me to solve this issue.

@drewbo
Copy link
Owner

drewbo commented Jul 23, 2018

Hi @janakiram0035, the function needs to be called in node (rather than the shell/commandline). I'll update the documentation to be clearer. Let me know if that helps

@janakiram0035
Copy link
Author

janakiram0035 commented Jul 23, 2018

@drewbo thanks for you quick reply.... while doing "npm install sqltoes" i am getting this error.

npm ERR! code ENOSELF
npm ERR! Refusing to install package with name "sqltoes" under a package
npm ERR! also called "sqltoes". Did you name your project the same
npm ERR! as the dependency you're installing?
npm ERR!
npm ERR! For more information, see:
npm ERR! https://docs.npmjs.com/cli/install#limitations-of-npms-install-algorithm

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\341121\AppData\Roaming\npm-cache_logs\2018-07-23T16_09_49_309Z-debug.log

@janakiram0035
Copy link
Author

@drewbo i have solved the above error. node with js file name not giving any output

@drewbo
Copy link
Owner

drewbo commented Jul 30, 2018

@janakiram0035 so there are two options to see the output. One is that you can use node in interactive mode by typing node in the commandline. From there you can write the code in the example and it should print the output. If you are saving that code as a file (say example.js) and then you run node example.js, it won't print anything because there aren't any instructions to output the string. So you'll need to add another line at the bottom like:

console.log(JSON.stringify(sqltoes(query)))

and it will output the string.

@janakiram0035
Copy link
Author

Its working. Thanq @drewbo

@drewbo drewbo closed this as completed Jul 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants