sqltabs icon indicating copy to clipboard operation
sqltabs copied to clipboard

Option to hide default table column

Open aperaham opened this issue 8 years ago • 5 comments

Hi,

Occasionally, I have found that it would be convenient to to hide the default ordinal '#' column, making quick copy and pasting easier.

May I suggest adding an additional parameter to the table options? For example: --- table default=false

Or perhaps an option to hide the default column in the preferences menu.

It seems the code responsible is here: sqlDoc/src/SqlDoc.js#L435, and I would be happy to contribute code to the feature with your approval.

hide_ordinal

Regardless, thank you for your work with sqltabs!

aperaham avatar Jul 11 '17 19:07 aperaham

Hi,

I agree, this would be a useful feature. I was thinking about it for some time already. I propose to add a rownum parameter to a table block, default is not descriptive enough:

--- table rownum=false

Since there is already hlr option for a table block and some more options are in plans (like pageby) I think this would be a step in right direction.

The codeline you pointed is responsible only for column header # rendering. The real rownums are rendered here

A contribution is very appreciated. I'm currently working on other features, so you can create a pull request, I will review it and help to adjust the things. Feel free to ask any details about development process, unfortunately I lack good contribution documentation.

sasha-alias avatar Jul 12 '17 12:07 sasha-alias

I think --- table rownum=false makes more sense. Thank you for pointing me in the right directing where code is concerned.

aperaham avatar Jul 12 '17 18:07 aperaham

pull request submitted to sqldoc here

aperaham avatar Jul 17 '17 20:07 aperaham

yeah, I've seen it it and it looks good. Just I'm on vacation atm and having limited connectivity. I will review it and merge once I'm back. Also I saw your question regarding sqldoc vs sqltabs development. Let me address it a bit later as well. ETA ~2 weeks. Sorry for delay

sasha-alias avatar Jul 17 '17 22:07 sasha-alias

Sounds great, thank you! I thought I should follow up by posting here in case you hadn't been alerted by the pull request to the sqldocs project, but also I wanted to document the ticket. Hope your vacation is a pleasant one. Thanks again!

aperaham avatar Jul 17 '17 23:07 aperaham