I am using C# in Visual Studio 2008 and I have install the WPF Toolkit. I created a DataGrid in testtest.xaml. The ID and Parts $ columns have the ability to sort the DataGrid by clicking on their respecteive column headers. However, the column header Complete Date does not have that ability. I used the tag "DataGridTemplateColumn" t...
I have a extjs gridpanel setup, and I want to be able to do things based on a user clicking on text or icons in the grid. For example, filter the grid if the user clicks (or double clicks) a word in a column, or show a popup if the user clicks on an icon. I can easily get the row they clicked on, and values by column name from that row, ...
I have a table that have 40million records.
What's best (faster)? Create a column directly in that table or create another table with identity column and insert data from first?
If I create an identity column in the table that have 40million records, is it possible estimate how long does it take to create it?
...
How do I databind a WPF Toolkit DataGrid column header value in code (not XAML)?
DataGridColumn fooColumn = new DataGridTextColumn
{
Header = "Foo",
Binding = new Binding {Path = new PropertyPath("BindingPath"),
Mode = BindingMode.OneWay}
};
This databinds the content of the cells of the column. But ho...
I have a table with lots of columns, say I have columns
A, B, C, D
in each of these columns, only one column in any one record will be filled and the others will always be NULL.
I need a select statement that will return the Column of the non null Column.
I've tried coalesce, but this return a value, not the column to which the ...
In sql server 2005, i in the query builder, i select "Add group by" to automatically
add the group by clause to all of the fields i selected. If one or more of those fields are a bit type, i get an error. Why is this? Is casting the column to TINYINT a good fix?
...
How to use C# to add a column for a table of sql server?
For example, I want to execute the following sql in C# code:
alter table [Product] add
[ProductId] int default 0 NOT NULL
...
I have a table [Product] with a column [CreateTime] datetime null, and is has some data already.
How can I set the column [CreateTime] 's default value to getdate(), and make the new added data to have a default value getdate() for column [CreateTime].
...
Hello,
My question is what is better to use in generating columns in SQL. Should the size of nvarchar (varchar) be multiply of 2 (32, 64, 128) or it's doesn't matter and we can use fully numbers example '100', '50' ?
Thank You very much for answers with reasons
Greeting's to all
...
I can understand that many years ago there would be this kind of limitation, but nowadays surely this limit could easily be increased. We have naming conventions for objects, but there is always a case that turns up where we hit this limit - especially in naming foreign keys.
Does anybody actually know why this isn't a bigger size - or ...
What is your naming convention for DATETIME columns (in my case, using MS SQL Server)
For a column that stores when the row was created CreatedDatetime makes sense, or LastModifiedDatetime.
But for a simple table, let's say one called Event, would you create columns called:
EventID, // Primary key
EventDatetime, ...
Hi Folks,
I have an existing column of data type varchar that I need to change to nvarchar, however I do not want to alter the existing column width of (5).
If I use the following statement
ALTER TABLE MYTABLE ALTER COLUMN MYCOLUMN NVARCHAR (5) NOT NULL
I end up with a column of nvarchar data type, but with a column width of (10)!...
I have multiple Users, each with a collection of Tasks.
public class User {
public string Name { get; set; }
public IEnumerable<Task> Tasks { get; set; }
}
public class Task {
public string Name { get; set; }
}
What I would like to do in Silverlight is have each User represented as a column, with Tasks represented as item...
To my surprise I just found out that applying text-alignment to a table column is fairly bad supported in current browsers. Neither Firefox 3.5.2, Safari 4.0.3 or IE8 shows the "amount" column below as right aligned.
HTML:
<table class="full_width">
<caption>Listing employees of department X</caption>
<col></col>
<col></col>
<c...
Hello,
My question is: Can I add in new column(S) in the gridview if the column is not found in the database?
- E.g. An indicator if a certain lecturer is a ML/Lec (roles).
I have a gridview that is "extracted" out from the database.
But I want to add in a new row which is not in the database but links to the data in the database.
Fo...
In my WPF Application I have an GridViewColumn that looks like this:
<GridViewColumn Width="170">
<GridViewColumn.Header>
<StackPanel Orientation="Horizontal">
<Path Data="{StaticResource pathStar}" Fill="Gold" Stroke="Red"/>
<TextBlock VerticalAlignment="Center">New items</TextBlock>
</Stack...
Hello,
I have made a one form with functionality to create grid view dynamically.
i have used concept of "how to create template columns dynamically in a grid view"
Link : http://www.codeproject.com/KB/aspnet/DynamicTemplateColumn.aspx
its working good.
i am creating control run time set the different property of control and bind it...
I have a 2-D array of integers. I'd like to initialize it in column order, and then access it in row order. Is it possible to initialize in PHP in column order without explicitly iterating over every row?
For example, in R, one can do
my2d = matrix(nrow=2, ncol=2) # create 2x2 matrix
my2d[,1] = c("a","c") # initialize column 1 in a s...
How do I SELECT rows and return all the columns, instead of specifying individual column names?
Can I also return only columns that match a specific criteria? (eg. col names beginning with an "_")
...
Hello there, I'm trying to add a column to a jtable. I've tried this code:
DefaultTableModel model = (DefaultTableModel) table.getModel();
model.addColumn("new column");
but the width of the table doesn't change, but the columns width. In other words, the width of the columns reduces so the new column "fits in" the table, but what I wa...