.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

How to have dynamic column names in an Excel Destination?

Posted By:      Posted Date: September 10, 2010    Points: 0   Category :Sql Server
I have a situation where both the column names in the source (SQL) and destination (Excel) are being created dynamically. The number of columns, their positions, and datatypes remain the same. How do I change the OLE DB Source and Excel Destination meta-data to handle these changes at run-time?

View Complete Post

More Related Resource Links

Dynamic Column in Excel Source

Hi,I am having Excel Source Which needs to be imported into Sql Server Table using SSIS.In the Excel Source I dont have Month and Year Column.But in Table I have Month and year column and both the columns are Primary Key columns.So i am not able to Import data from Excel to Table.So is there any possiblities to add Columns Dynamically in Excel source inorder to  get the Year and Month

Export Visio Database Table Names to Excel

If you use the Enterprise Architect edition of Microsoft Visio for data modeling regularly, then there is a good chance that at some point you've wanted to export just the table names into Excel. You might want to do this to map logical ERD entities to physical data model tables, track project status by entity, or track overlap between database versions.

dynamically change column names in Crystal reports


I need to develop 3 pages.

On the first page user defines atmost 7 column names to be displayed on the report. I'm saving these names in a Sql DB table 'Columns' with Column_Nm and Column_ID as Table columns.

On the second page I'm retrieving column_Nm from the table and displaying them on the page so that the user enters the data. This data is saved in another table 'Summary' with the Columns column1 through column7.

on the 3rd page I need to show a report of 'Summary' table.

How do I dynamically replace column1 through column7 names with that of 'Column_Nm' on the report?

Any help/suggestions would be appreciated.


Duplicate column names from forms in SharePoint lists



I'm in the process of migrating from a WSS 2 site to WSS 3/MOSS. On the old site I used an Infopath 2003 form for absence requests. During the migration I now use Infopath 2007. There wasn't any problem initially when the form was stored with the SharePoint form library. However, when I published the form as a content type from Infopath 2007 and then added that content type to the form library, there are two columns for each piece of data from the form. (One from the content type and one from the form list.) I relinked each old form (list content type) to the new AbsenceRequest content type and removed the original one from the list. However, the duplicate column names are still there. Since they came from the Infopath form, they are not editable or deletable from the SharePoint list management interface. The duplicate column names make it tough to build views since it isn't apparent which column to use in the form building UI. It can be determined form the overview display, but it is very cumbersome.


Does anyone know a way to get rid of the old, absolute, columns?

Dynamically change column names in Crystal reports - ASP.Net

Hi I am developing an application in ASP.net 3.0 and MY SQL database . I want to display column names & values in crystal report as user selects in ASP.net application  and column names and corresponding values will be changed dynamically. Any help/suggestions and sample code would be appreciated. Thanks in advance....  

In export, i want to disable column in excel sheet

Hello, I am doing Import/Export. While export i want to disable some column in excel sheet, so during upload or import same primary key I can use, instead of user modify such column. Regards, Sandeep    

How do I change the order of column names in EditForm.aspx

I have an Announcements list to which I've added extra columns: Publish (date), De-Publish (date), and Category (choice).  When I go to EditForm.aspx, the columns display in this order: Title , Body, De-Publish , Category and Publish . I'd like to change the order of the columns on EditForm.aspx so that it is Title, Body, Category, Publish and De-Publish . Changing the All Items view doesn't do it. How might I change the order of columns that is shown to the user?

how do i develop a cascade drop down lists which get the chart names from excel sheets

hi i have to develop a cascade dropdownlist. one of the drop down is used to retrive only excel docs from a specific doc library and and the other drop down to get all the chart names and attach it to the second dropdown list in doc lib item changed event thanks    

Unable to load data into a LookUp column in sharepoint using sharepoint destination

I have loaded details of a customer on a list and was able to load the data with out any problem using sharepoint list destination. We have a lookup column called customerid looking at customer list  . This lookup column is in another list, called Customer Main, so I am trying to load additional data for customer in this customer Main  list which contains a lookup column called customerID. I was not able to load data into this cutsomerid, whereas rest of the data is coming into sharepoint with out any problem. How should I load data into a lookup column. Thanks  

Trouble importing strange column format report from Excel 2007 to SQL 08

Hi, I'm not sure whether this belongs in this section or the SSIS one so hopefully I've got it right!  Hoping someone will be able to help with a problem I'm having importing a report with header and detail rows from our antiquated POS system into SQL 2008 tables.  The reports export in Excel 2007 format and for each header row there can be one or more detail rows starting from column B.  As such I've tried several things such as openrowset, an Access 12.0 OLE DB source in SSIS and even COM automation of Excel to try and write a conditional split which will hold the header details in variables then write them to rows alongside the detail rows.  I've pasted a small sample of the data here as I wasn't able to attach it: 01/07/2010 @ 11:18 Page: 1 RECEIVING: Voucher Journal Sort: VC|Str|Vou Date|Vou #|Document SID Filter: Voucher Date: 01/06/2010@12:00a..30/06/2010@11:59p Include Item detail: DCS|Item#|Desc1|Attr|Material|Size|Qty VC Str Vou Date Vou # Qty ABC 001 15/06/2010 12345 38 E NN 66 200148 XXXXXXXX RED SHAD E NN 66 200149 YYYYYYYYY BLACK GO E PP 60 200154 ZZZZZZZZZ BLACK CDE 002 16/06/2010 13839 8 F SA 35 217500 XXXXXXXX Natural F SA FL 218674 YYYYYYYYY Chalk F SA WE 221462 ZZZZZZZZZ White FGH 001 21/06/2010 13905 3 F SH 85 126260 XXXXXXXX Navy IJK 001 23/06/2010 13914 3 E AA 61 250005 YYYYYY

merging every 3 column in excel using macros

I would like to merge every 3 columns and so forth in excel. It will be as follow: Column A,B,C as one column continued with  D,E,F, and G,H,I, and so forth until say KU,KV,KW. please let me know how to create the macros to select and then merge it. Thank you

Why are square brackets needed for column names

Hi I'm just trying to get used to using Joins if anyone can please tell me why this only works if I put the column name in square brackets. I only managed to work this out because after struggling I had look at how it should look when designing a New View. This works :- SELECT FoodInv.Calories FROM (FoodInv INNER JOIN Diary ON Diary.FoodIndex = FoodInv.[Index]) WHERE Diary.Date = '2010-09-05' but this didn't if I leave out the square brackets :- SELECT FoodInv.Calories FROM (FoodInv INNER JOIN Diary ON Diary.FoodIndex = FoodInv.Index) WHERE Diary.Date = '2010-09-05' Without the brackets would generate error within the Messages window :- Msg 1018, Level 15, State 1, Line 7 Incorrect syntax near 'Index'. If this is intended as a part of a table hint, A WITH keyword and parenthesis are now required. See SQL Server Books Online for proper syntax. Any hints are welcome. Thank you. Matthew

read excel column value

Hi All,             i am uploading excel file data to database.Excel column value is combination of text and time,i need to extract only time.Each column will have different value. One column value is   _immediate 17:00 - 9:00 another column value is EMAIL 09:30 - 18:00,another column value is CKA 09:30 - 18:30 ans so on. i need to extract only time and store it 2 different variables like this. string Intime - 17:00 string OutTime - 9:00   Please send me code to acheive this task.            

Saving Document With Column items applied via excel macro

I have an excel macro that pulls data down from columns within worksheets that will take an excel spreadsheet and save it as a PDF file into seperate folders based off criteria set in the files. Getting the files into the proper directory is not the problem i'm having. When the script executes it saves the documents directly to our sharepoint site, but the custom columns A B C D etc are all blank and some are 'required' items which sets the document as checked out until i go into the list and enter the required data. Is there anyway to make this macro export as PDF and set the required data for me in the sharepoint column so it checks the documents in for me? I'm figuring this is a simple set of meta datatags but I don't know the syntax for them and I didn't find anything like this on the forum anywhere else. ActiveSheet.ExportAsFixedFormat Type:=xlTypePDF, Filename:= _ "http://DirectoryStructureHere/corporate%20BoFi/pdfs/" & NewFileName & ".pdf" _ , Quality:=xlQualityStandard, IncludeDocProperties:=True, IgnorePrintAreas _ :=False, OpenAfterPublish:=False 'Exports the print area as a PDF document named the new filename "Modified: to sharepoint"

ASP.NET-Gridview - Export to excel- column format

Hi All, I am exporting gridview data into excel sheet. I have a column  which is a code for which data is like 012,013 etc. But when this data is being exported , in the excel sheet I can see the data as 12,13,14. but actually it should be 012.... Is there any way to specify the format of such columns in my datatable so that they are in the same manner as in the database? Please provide some information on this.Thanks in advance.

Excel/SQL - Column Name Length

Hi, I believe while importing/exporting data from Excel into SQL, the column name should not be more than 64 characters long. However, I have a situation where my field name could be more than 64 characters. Can someone suggest how to increase the column name length? Thank you for your quick response. Best Regards, Harikrishnan R

Uploading Excel 2007 table into WSS 3.0 - How does SharePoint decide the column that is used to edit

Hi, In Excel 2007, there's an option to upload (export) an Excel table into SharePoint.  The range of cells have to be identified as a table.  In the Table ribbon, there's an Export button.  When I upload the Excel 2007 table, SharePoint (WSS 3.0) decides which column in the table will be linked to the properties dialog box for each line in the table.  It seems to be a sporadic decision on the part of SharePoint. Does anyone know how WSS 3.0 decides which column will be linked to properties?  And, is there any way to control this when uploading the file? Thanks!Thanks! Patti N.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend