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

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

is it possible to delete column data

Posted By:      Posted Date: September 17, 2010    Points: 0   Category :Sql Server
I wanted to delete specific column data from sql query to re-enter it. Is it possible?

View Complete Post

More Related Resource Links

Cannot delete external data list column due "Parameter name: combinedEncoded" error

Hello!   I migrated a Sharepoint 2007 to a Sharepoint 2010 by dbattach method. And now I want to delete the BDC list columns, but I'm getting this exception: System.ArgumentException:   Parameter name: combinedEncoded    at Microsoft.SharePoint.BdcClientUtil.SplitStrings(String combinedEncoded) What should I do to delete properly this columns?   Many thanks!

is it possible to delete column data

I wanted to delete specific column data from sql query to re-enter it. Is it possible?

Rendering data with HTML tags in the DD Gridview for a selected column


I am having trouble finding out where and how to HTML Encode a cell's data on the Dynamic Data (v4.0) gridview of List.aspx.  As a simple case, suppose I have formatted cell data that is A<br/>B in the DB.    Obviously, I want A stacked on B in the cell.

It seems gridView1.HtmlEncode = true has gone away.

So maybe I'll try to catch it on the RowDataBound event:

protected void GridView1_RowDataBound(Object sender, GridViewRowEventArgs e)

            if (e.Row.RowType == DataControlRowType.DataRow)
                // Html Encode the cells


but this event never fires?

Has anyone figured out how to properly render HTML tags data in the List.aspx's GridView1? 

If I figure this out, then I can add a MetaAttribute called something like [EncodeAsHtml(true)] and be on my way.  Thanks!

delete data in excel sheet



           I have write the code for deleting the data in excel sheet. but we have got the error" Deleting data in a linked table is not supported by this ISAM."

     below I paste some code snippest.

string strDelete = "Delete  from [" + strSheetName + "$]";

            cmdExcel.Connection = con;
            cmdExcel.CommandType = CommandType.Text;
            cmdExcel.CommandText = strDelete;


Please can anybody this answer.It is urgent

Data Points: Column Expressions, DataRelations, and Computations


This month John Papa fields some of his favorite questions regarding data manipulation with ADO.NET.

John Papa

MSDN Magazine January 2007

split one data column into many?


Hi, I've a database table contains survey questions and answers. But the problem is both 'question' and 'answer' are saved in the same column(like below).

SubmissionDate                                                          Submission

2010-02-15 14:53:59.657                     ***What's your pet's name?***  Lili ***Tell us about yourself*** I'm a teacher

2010-02-15 14:53:59.657                     ***What's your pet's name?***  Lucy ***Tell us about yourself*** I'm a five star cook

I'd like to use a simple datagrid to display the survey result, but I need to separate the submission column into multiple columns ('question' as column name, 'answer' as data)

the number of questions or questions being asked are different for each survey so they are not fixed. 

Is it even possible to get something like this below in a gridview? 


Business Data Column cascade


Good afternoon, I would like to know if is possible to have two business data columns linked to each other. This is the scenario that I want:

BD Column 1 called State with all US states

BD Column 2 called City with all the cities based on the state selected on BD Column 1

Use BDC data in list as multi-select column

I have a document library that uses values from another system for its metadata.  Right now, we copy the values from the primary system into SharePoint so users can choose them.  I want to find a way to use the BDC connection that I have set up to automatically pull those values.  The problem is that the current metadata is set to multi-select.  So, I have a file that is in the library and it can be used for multiple clients - clients is a column in my library and users can select many entries.  When I set up a column to pull BDC data, it only allows single entry.  Does anyone have any ideas?

BDC Entity as a Data Source for a Lookup column

Is it possible to create a custom lookup field type to have a BDC entity as the data source?

Sharepoint list group by column data ,display in webcontrol like panel or label


I  have a sharepoint list[Managers] with groupby sector column. like below




Each Sector group by column data i want to display in label or panel control.

How to do that ? how to write the logic?



Regards, Mansoor

wss2.0 update/delete/hide lookup column that does not display any values


Hi All,

I have a document library that contains a Category column that is a lookup field. This is a default column that is a required field when uploading documents to the document library. The Category column is empty and I am unable to amend, hide, make it not required or delete it.

I have gone to Modify settings and columns -> clicked on the Category field to edit, but there is no option to amend the content or delete it. I am only able to amend the Column name and Description.

Since then, I have amended the column name to eg. Category1 and created a new Category field as a lookup and linked it to the correct list.

The problem I am facing now, is that I cannot hide, delete or make the Category1 (old Category) field NOT required. Either I would like to update the original field to display the correct values or alternately hide, delete or make the column not required.

Please help.

Hide data for specific column from a user

Greetings, I have a problem. I would like to restrict showing specific users (or roles or schemas) data in a column. First I thought DENY option will do it but figured out that it won't. DENY denies the column being in the SELECT query. I would still like to call the column but if access to the data in that column is restricted it would show only null values and not the real ones. So... I would like call the next query from user TestUser: SELECT ID,Name,Address FROM Employee But if access to Address is restricted for TestUser I would get results like: ID Name Address 1 John Smith NULL 2 Rick Ross NULL ... Is it possible to do something like that in SQL Server 2005/2008? I was thinking of storing that kind of information in a table (for which tables, which columns for which users access is restricted) and then manipulate it on the application site but my programmers tell me that they use components which always call the full table (like SELECT *).  Thank you for your answer.

How to perform math on a column of data in SQL database and display it in my VB app

Sorry if this is the wrong forum, cos it's SQL and VB2010 So I have my sqlserver database 3.5 compact editon called "Dive Club Records" and in it are stored columns of dive trip information and I want tthe user to be able run a query from my VB2010 application to sum a divers total dive hours and display it on the form, eg: MemberID, FirstName, LastName, DiveTime by the way divetime is a real number recorded as 15.5, 20.5, 5.0 etc What is the easiest way to do this? Would prefere to do it from within VB2010 code if possible or make a query from the datagrid on my form using query designer. thanks for any suggestions from you all, hope you can keep them simple for me :)   regards   paul   paul

delete XML data

I have this XML data:<Master xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sqltypes="http://schemas.microsoft.com/sqlserver/2004/sqltypes" targetNamespace="urn:schemas-microsoft-com:sql:SqlRowSet1" elementFormDefault="qualified"> <xsd:import namespace="http://schemas.microsoft.com/sqlserver/2004/sqltypes" schemaLocation="http://schemas.microsoft.com/sqlserver/2004/sqltypes/sqltypes.xsd" /> <xsd:element name="Employee"> <xsd:complexType> <xsd:sequence> <xsd:element name="EmployeeName" nillable="1"> <xsd:simpleType> <xsd:restriction base="sqltypes:varchar" sqltypes:localeId="1033" sqltypes:sqlCompareOptions="IgnoreCase IgnoreKanaType IgnoreWidth" sqltypes:sqlSortId="52"> <xsd:maxLength value="100" /> </xsd:restriction> </xsd:simpleType> </xsd:element> <xsd:element name="EmployeeID" nillable="1"> <xsd:simpleType> <xsd:restriction base="sqltypes:varchar" sqltypes:localeId="1033" sqltypes:

C# newbie stuck - trying to access column data in a SharePoint list in an SSIS script task

Hello, I'm sure this is the simplest question but I can't figure it out, even with Google's help. I am trying to stumble through some C# code in an SSIS script task and I am frustrated that I can't figure out how to do the easiest things.  I eventually want to find data in a column,and then use another list as a lookup to replace that value with another where the existing value matches a value in the lookup list.  So, the data in my (multiple choice) column might be "apples; bananas" and in another list I have a row that contains two columns, the first holding the value "Apples" and the second containing "Red Delicious" and my original column should read: "Red Delicious; bananas." But, alas, I can't even figure out how to see the data that is in a column. Here is my code: /*<br/> Microsoft SQL Server Integration Services Script Task<br/> Write scripts using Microsoft Visual C# 2008.<br/> The ScriptMain is the entry point class of the script.<br/> */<br/> <br/> using System;<br/> using System.Data;<br/> using Microsoft.SharePoint;<br/> using Microsoft.SqlServer.Dts.Runtime;<br/> using System.Windows.Forms;<br/> using Microsoft.SharePoint.Utilities;<br/> <br/> namespace ST_08becda4c05c49cd9f30ea76110076cd.csproj<br/> {<br/> [

wpf charting column series data binding problem

I'm trying to build a chart using the columnSeries from the wpf toolkit and I appear to be having trouble with the data binding. Here is the xaml: <Grid>    <chartingToolkit:ColumnSeries Height="18" HorizontalAlignment="Left" Margin="188,169,0,0" Name="columnSeries1" VerticalAlignment="Top" Width="18" IndependentValueBinding="{Binding Path=Date}" DependentValueBinding="{Binding Path=Value}" /></Grid> In the code behind, I'm calling a stored procedure and putting the result in a datatable like this: string connString = ConfigurationManager.ConnectionStrings["string"].ConnectionString;            using (SqlConnection cn = new SqlConnection(connString))            {                DataTable dt = new DataTable("T1");                cn.Open();                SqlCommand cmd = new SqlCommand("T1_sp", cn);                cmd.CommandType = CommandType.StoredProcedure;                  SqlDataAdapter da = new SqlDataAdapter(cmd);                da.Fill(dt);                columnSeries1.ItemsSource = dt.DefaultView;                cn.Close();            } No error is being generated but I'm not getting a column chart either. If I take the same command and put it into a datagrid, it works fine. What do I need to do to get this into my column chart? If it helps,

Cannot delete custom column in calendar list - 'unknown error'

I've created a column in a calendar list and now cannot delete it.  I've cleared all data and I still get the "Unknown Error" message when I try to delete. jan
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