I have a list of table names in Notepad++:
employee
manager
customer
reciepts
customer_details
employee_mapping
manager_employee_mapping
I want each word to be duplicated again in the same line, for example:
employee employee
manager manager
customer customer
And so on. I want to do this to make a SQL script where I have to select tablename as string and table's total count. Like:
select 'employee', count(1) from employee union
select 'manager', count(1) from manager union
similarly for all rows.
Now, words like select/union/count/,/from
can easily be inserted using either ctrl+F or insertion at beginning and end. But getting the table name as a string is tricky.
Is there any way to do this in Notepad++ without doing this manually?
This list is just a sample, I have a list of more than 100 tables. Please help out.