September 16, 2011 at 7:36 am
hi,
i have to trim excel sheet table content which is in this form APP_FI_APO-Sandbox_UNIX_Metsä-Botnia-Oy-Ab_mbapqd01 to 5columns in different database tables containing
applicationame as APP
LOCATION AS FI
device usage as APO-sandbox
environment is also the same as above APO-sandbox
device name is the last mbapqd01
customer name is Metsä-Botnia-Oy-Ab and how to write the function for this in mssql2008? :-)plz tel let me know.
September 16, 2011 at 7:43 am
I can't understand your question.
You have some data in Excel. I get that much. What are you trying to do with it?
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
September 16, 2011 at 7:49 am
If you are trying to separate the string into multiple strings / columns in Excel, you might look for an Excel forum instead of a SQL forum. If you're trying to import the Excel data to SQL Server and have the end result be in 5 columns instead of one, then maybe you can do this.
If the later, you should import the excel sheet into a staging table as is, then you can run a splitter function as per Jeff Moden's article here[/url] and insert the data into a different table.
September 16, 2011 at 7:53 am
hi thanx for understanding i will tel u in bit more detail what i need to do is i m having two databases one is local n other is in global so i need to export the excel sheet to mssql that i did but now a table containing called servername have containes tha data in the form i sended earlier now what i need i need to trim the whole data i,e have to break the data in the form of tables in a new mssql database. and the database tables containing the fields i shown earlier so how to do that?
September 16, 2011 at 7:55 am
Do as I said in the second paragraph of my last post. Import the data as is into a staging table, then split the data up, following the directions in the link of my last post, as you're inserting it into the final destination table.
September 16, 2011 at 8:28 am
YA I HAD SEEN YOUR LINK I will do IT NOW but IF I MAKE CHANGES IN MY PREVIOUS DATABASE table which i trimmed i need the changes would appear in it after acertain time interval.:-) how can i do that i cannot use trigger in my global view as i can do readonly from it! tel me that
September 18, 2011 at 11:49 pm
hi i didnt get ur reply on my query of trimming table!
September 19, 2011 at 4:31 am
rekhadodla0 (9/18/2011)
hi i didnt get ur reply on my query of trimming table!
Of course you didn't. I'm not going to reply when you "yell" at me by using all caps. That's just rude to someone who's trying to help you.
September 19, 2011 at 10:41 pm
:cool::-) and m sorry! now please help me on my database problem!
September 20, 2011 at 3:11 am
@tarvin: in ur last reply u have sended a link but that all tells about using a tally table bt i have to use in mssql i have to create the function and loop for insert and update in the local database so can i use this code there and how? tel me likewise!
Viewing 10 posts - 1 through 10 (of 10 total)
You must be logged in to reply to this topic. Login to reply