Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Query help

Author  Topic 

shubhada
Posting Yak Master

117 Posts

Posted - 2007-03-22 : 02:48:14

I have the following string

@string = [rule("Total Covered Days",["Covered Days","Process Rule"],["",""],["Total Covered Days"]),
rule("Total Covered Charges",["Covered Charges","Processing Flag"],["","UB"],["Total Covered Chrg","Processing Flag"]),
rule("Flat Rate",["Reimburse Amt","Flat Rate","Process Rule"],["","2",""],["Reimburse Amt"]),
rule("HIS Reimbursement",["ASC DRG Code","MDC Code","DRG Reim Amt","Reim Base Type","Reim Base Value","DRG Outlier Amt",
"HIS Reimburse Pct"],["","","","","","","2"],["Reimburse Amt"]),rule("Total Reimburse Amt",["Reimburse Amt","Deductible Amt",
"Coinsurance Amt","Process Rule"],["","","",""],["Tot Reimburse Amt","Reim Cutback Amt"]),rule("Total Adj Amount",
["Tot Reimburse Amt","Original Reimburse","Process Rule"],["","",""],["Total Adj Amt"])]


i want to break the string and store it into variable as follow

1.first i want to pick following srting from @string and want to store in @string1

rule("HIS Reimbursement",["ASC DRG Code","MDC Code","DRG Reim Amt","Reim Base Type","Reim Base Value","DRG Outlier Amt",
"HIS Reimburse Pct"],["","","","","","","2"],["Reimburse Amt"])

@String 1 = rule("HIS Reimbursement",["ASC DRG Code","MDC Code","DRG Reim Amt","Reim Base Type","Reim Base Value","DRG Outlier Amt",
"HIS Reimburse Pct"],["","","","","","","2"],["Reimburse Amt"]),

then I want to remove @string1 part from @string

after this my @string will be as follow

@string = [rule("Total Covered Days",["Covered Days","Process Rule"],["",""],["Total Covered Days"]),
rule("Total Covered Charges",["Covered Charges","Processing Flag"],["","UB"],["Total Covered Chrg","Processing Flag"]),
rule("Flat Rate",["Reimburse Amt","Flat Rate","Process Rule"],["","2",""],["Reimburse Amt"]),
rule("Total Reimburse Amt",["Reimburse Amt","Deductible Amt","Coinsurance Amt","Process Rule"],["","","",""],["Tot Reimburse Amt","Reim Cutback Amt"]),rule("Total Adj Amount",
["Tot Reimburse Amt","Original Reimburse","Process Rule"],["","",""],["Total Adj Amt"])]


2. Second part is, I want to store following part from modified @string in @string2

@string2 = [rule("Total Covered Days",["Covered Days","Process Rule"],["",""],["Total Covered Days"]),
rule("Total Covered Charges",["Covered Charges","Processing Flag"],["","UB"],["Total Covered Chrg","Processing Flag"]),


and
3. Want to store the following part in @string3 from modified @string

@string3 = rule("Flat Rate",["Reimburse Amt","Flat Rate","Process Rule"],["","2",""],["Reimburse Amt"]),
rule("Total Reimburse Amt",["Reimburse Amt","Deductible Amt","Coinsurance Amt","Process Rule"],["","","",""],["Tot Reimburse Amt","Reim Cutback Amt"]),rule("Total Adj Amount",
["Tot Reimburse Amt","Original Reimburse","Process Rule"],["","",""],["Total Adj Amt"])]


Plz someone tell me how I can do this.

snSQL
Master Smack Fu Yak Hacker

1837 Posts

Posted - 2007-03-22 : 13:07:11
You should find some help for doing that here
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=50648
Go to Top of Page
   

- Advertisement -