# Node-red-contrib-sql-prepare

**URL:** https://discourse.nodered.org/t/node-red-contrib-sql-prepare/37838
**Category:** Share Your Nodes
**Created:** [21 December 2020 12:02 UTC](https://discourse.nodered.org/t/node-red-contrib-sql-prepare/37838 "2020-12-21T12:02:09Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![YT2310](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/yt2310/32/35255_2.png) [@YT2310](https://discourse.nodered.org/u/YT2310)
#### Post date: [21 December 2020 12:02 UTC](https://discourse.nodered.org/t/node-red-contrib-sql-prepare/37838/1 "2020-12-21T12:02:09Z")

</div>

[describtion](https://www.npmjs.com/package/node-red-contrib-sql-prepare)  
I create a simple node which can be used to translate an array input to an sql command.  
So you can easily change the definition of the sql command via the array.  
Select, insert, delete and update commands are possible.

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [21 December 2020 21:51 UTC](https://discourse.nodered.org/t/node-red-contrib-sql-prepare/37838/2 "2020-12-21T21:51:02Z")

</div>

Hi, nice idea and one I'd probably try at some point.

Couple of things though. Your node has no license attached (according to npm) so most people won't be able to use it.

Also, it does really help to link the module to GitHub so that people can review the actual code and raise issues if needed.

---

<div class="post-metadata">

### Author: ![YT2310](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/yt2310/32/35255_2.png) [@YT2310](https://discourse.nodered.org/u/YT2310)
#### Post date: [22 December 2020 09:14 UTC](https://discourse.nodered.org/t/node-red-contrib-sql-prepare/37838/3 "2020-12-22T09:14:24Z")

</div>

Thanks for your feedback. I just added a license and also publish the code on github.  
Hope that its fine now 🙂

> **[yannt23/node-red-contrib-sql-prepare](https://github.com/yannt23/node-red-contrib-sql-prepare)**
>
> A node that converts array data input to sql insert

---

<div class="post-metadata">

### Author: ![dokoral](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dokoral/32/39381_2.png) [@dokoral](https://discourse.nodered.org/u/dokoral)
#### Post date: [28 March 2021 13:15 UTC](https://discourse.nodered.org/t/node-red-contrib-sql-prepare/37838/4 "2021-03-28T13:15:02Z")

</div>

I can't seen to figure out how to SELECT all records in db table. Can yo help. Thanks, Dan

---

<div class="post-metadata">

### Author: ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)
#### Post date: [28 March 2021 14:13 UTC](https://discourse.nodered.org/t/node-red-contrib-sql-prepare/37838/5 "2021-03-28T14:13:38Z")

</div>

There is an example in the readme showing how to do that, but why would you want to use this node for such a simple task. All you need is `select * from table`

---

<div class="post-metadata">

### Author: ![dokoral](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dokoral/32/39381_2.png) [@dokoral](https://discourse.nodered.org/u/dokoral)
#### Post date: [28 March 2021 18:45 UTC](https://discourse.nodered.org/t/node-red-contrib-sql-prepare/37838/6 "2021-03-28T18:45:22Z")

</div>

Okay Thank you
