I have a column called salary in my table. Another value table is stored as
- 5 lakhs 12 thousand similarly ..
I want to get the result
I created one request,
SELECT TOP(10) 'INSERT INTO jobs(Budget) VALUES('+ CAST(SUBSTRING( CAST(r.Budget AS VARCHAR(50)), 0, PATINDEX('%laks%', r.Budget))*100000 AS VARCHAR(50)) + ',' +CAST(SUBSTRING( CAST(r.Budget AS VARCHAR(50)), PATINDEX('%laks%', r.Budget) + 4 ,patindex('%Thousands%', r.Budget) - PATINDEX('%laks%', r.Budget) - 4)* 1000 AS VARCHAR(50))+')' FROM requirementsdetailsfororganization r
Here I can separate the individual values. I can not add two values.
when i use the above query my result
INSERT INTO jobs(Budget) VALUES(200000,5000)
Expected Result:
INSERT INTO jobs(Budget) VALUES(205000)
source share