Wednesday, May 29, 2013

[SQL Server] Bulk Copy.

[SQL Server] Bulk Copy.


Bulk Copy.

Posted: 28 May 2013 07:36 PM PDT

Hi Experts,i have a text file with 1 -3 lakh records and 5 columns or so.... each column is seperated by tab delimiter. i need to import this file to SQLSERVER 2008.while importing this text file into SQL server, the first column in text file has 10 characters stringi need to split this string into 4 separate strings of fixed lengths (like1st string -2char, 2nd string - 2char, 3rd string - 3char, 4th string -- remaining chars) and insert it into 4 different columns in sql server.example i have a string in first column like INAPHYD00001 when i import this into sql server it should split like IN ------to be inserted into Country column in sql server.AP -----to be inserted into State column in sql server.HYD ----to be inserted into City column in sql server.00001 --to be inserted into LocalityID column in sql server.i heard i can use Bulk Copy but i'm not sure how to use it and also how to prepare a format file for this requirement.please help me in this regard.ThanksKishorekishorefeb28@icloud.com

Application Slowness issue

Posted: 28 May 2013 10:32 PM PDT

Hi,My database is working fine, but application is getting slow. According to the client,If they login with one or two user application is fast. If all the user login at the same time the software became very slow.Is this a Database problem or Network issue.Can anyone please tell me the solution?Thanks in advance.

Power Pivot

Posted: 28 May 2013 05:48 PM PDT

Hi Guys.Need some of your expertise.I just wanted to know is it possible to run more then 1 query on the same power pivot sheet?i have certain product codes and i need to show them on 1 pivot chart with different colour barsAny advise on how to do this?

Displaying a week numbers as a rows for given date range

Posted: 28 May 2013 07:57 PM PDT

Hi,I would like to display a week number as a row for given date range. After all I want to join this with another data.So having a start date and end date as a parameter I would like to receive as many rows as we have weeks in given date range i.e. week start date = Mondaystart date = 2013.01.03end date = 2013.01.23expected results:[code="other"]week_nbr start_date end_date1 2013-01-03 2013-01-052 2013-01-06 2013-01-123 2013-01-13 2013-01-194 2013-01-20 2013-01-23[/code]

No comments:

Post a Comment

Search This Blog