joereynolds / SQHell.vim

An SQL wrapper for vim
MIT License
131 stars 9 forks source link

dd on SQHresult should delete row #8

Closed joereynolds closed 6 years ago

jbyte commented 6 years ago

Hi!

I've been tinkering a bit on this issue and found a simple enough way to do it. The basic idea was to save the current window number(SQHResult buffer) and then jump to the previous one(SQHTable buffer), get the table and database name and return to the result buffer. But that relays on the user not jumping around the opened windows or closing them. So I would like to get your input on the matter, if its fine or should I find another way to do it?

joereynolds commented 6 years ago

Hey jbyte,

I say go for it, the implementation can always be improved as we go on. I'm interested in how you're going to construct the DELETE query though as not all table will necessarily have primary keys.

Either way, excited to see the result!

jbyte commented 6 years ago

I added a explanation in the PR #25.

joereynolds commented 6 years ago

https://github.com/joereynolds/SQHell.vim/commit/1252fd5249d8439db83b1301fe64fc9b07d33976