Questions tagged [row]

A horizontal line of cells in a spreadsheet, SQL table, HTML table, or similar structure.

A row most commonly refers to a horizontal line of cells in a spreadsheet or similar structure.

7733 questions
47
votes
6 answers

How to add rows to empty data frames with header in R?

Possible Duplicate: R: losing column names when adding rows to an empty data frame I created an empty dataframe with column names only as follows > compData <- data.frame(A= numeric(0), B= numeric(0)) > compData [1] A B <0 rows> (or 0-length…
Surjya Narayana Padhi
  • 7,741
  • 25
  • 81
  • 130
46
votes
1 answer

How to set row height of QTableView?

I have QTableView and QAbstractTableModel. I require rows to have height equal to 24. I know the only way to do this is by calling QTableView::setRowHeight. Since the model is dynamic it may be added new rows, but I don't want to call setRowHeight…
Ashot
  • 10,807
  • 14
  • 66
  • 117
45
votes
10 answers

How can I get the total number of rows in a CSV file with PHP?

Using PHP, how can I get the total number of rows that are in a CSV file? I'm using this method but cannot get it to work properly. if (($fp = fopen("test.csv", "r")) !== FALSE) { while (($record = fgetcsv($fp)) !== FALSE) { $row++; } …
telexper
  • 2,381
  • 8
  • 37
  • 66
44
votes
4 answers

Remove rows in python less than a certain value

I feel like this question must have been answered by someone before, but I can't find an answer on stack overflow! I have a dataframe result that looks like this and I want to remove all the values less than or equal to 10 >>> result …
JAG2024
  • 3,987
  • 7
  • 29
  • 58
44
votes
3 answers

How to configure MySQL 5.6 LONGBLOB for large binary data

Before I ask my question a little background: I'm doing the Data Export/Import using the MySQL Workbench 6.1 of a MySQL 5.5 database from one machine to a 5.6 on another. both machines are ubuntu one 32-bit the other 64-bit. I dump the data no…
nrapopor
  • 723
  • 1
  • 5
  • 7
43
votes
2 answers

Missalignment with inline-block (other elements pushed down)

I'm trying to align small boxes in a row. These boxes have something like 2 elements in each. In some cases, the first element is so "much" text, that it splits into 2 lines. If this happens, all other blocks in this special line are shown…
simon
  • 3,378
  • 2
  • 22
  • 32
43
votes
4 answers

WPF Grid: Is there an easy way to readjust the row items if I need to insert new rows?

It appears that grid row and column definitions are hard-coded like this: Grid.Row="3" Grid.Column="1" I am in the middle of development on a new WPF app and I am having to constantly add and delete new rows from my grid as the client makes up…
oscilatingcretin
  • 10,457
  • 39
  • 119
  • 206
42
votes
9 answers

SQL - Inserting a row and returning primary key

I have inserted a row with some data in a table where a primary key is present. How would one "SELECT" the primary key of the row one just inserted? I should have been more specific and mentioned that I'm currently using SQLite.
Samuel Moriarty
  • 958
  • 1
  • 8
  • 20
37
votes
12 answers

Highlight ListView selected row

I have a list of albums (several hundred). When I touch the selected album I want to offer the user a choice of playing the whole album, or moving to its track ListView. No problem. However, after touching the ablum in albumListView I want the row…
user611089
37
votes
4 answers

MS SQL 2008 - get all table names and their row counts in a DB

I'm trying to identify which tables are affected by a data update though an application (developed by others). There are more than 200 tables in the DB and I'd like to avoid checking each of them for changes. Is there any other way where I can list…
chinna_82
  • 6,353
  • 17
  • 79
  • 134
36
votes
3 answers

How to check if a row exist in the database using PDO?

I want to have a condition that will perform some action when the row doesn't exist at all. $stmt = $conn->prepare('SELECT * FROM table WHERE ID=?'); $stmt->bindParam(1, $_GET['id'], PDO::PARAM_INT); $stmt->execute(); $row =…
xperator
  • 2,743
  • 7
  • 34
  • 58
34
votes
6 answers

WPF DataGrid RowHeader databinding

I have a DataGrid, bound to a DataTable. I want to display text in the RowHeader, to achieve something like this: Col0 Col1 Col2 Col3 Table | 1 | 3 | 5 | 6 | Chair | 3 | 2 | 1 | 8 …
eriksmith200
  • 2,159
  • 5
  • 22
  • 33
33
votes
7 answers

Delete a row from a table by id

I have a little problem. I have some dynamically created tables and each row has an id. I want to delete the row with the id "x". I tried the usual method (removeChild) but it doesn't work for tables apparently. function deleteRow(tableid, rowid) …
zozo
  • 8,230
  • 19
  • 79
  • 134
33
votes
3 answers

Add row in each group using dplyr and add_row()

If I add a new row to the iris dataset with: iris <- as_tibble(iris) > iris %>% add_row(.before=0) # A tibble: 151 × 5 Sepal.Length Sepal.Width Petal.Length Petal.Width Species
Dan
  • 1,711
  • 2
  • 24
  • 39
33
votes
5 answers

Remove table row after clicking table row delete button

Solution can use jQuery or be plain JavaScript. I want to remove a table row after user has clicked the corresponding button contained in the table row cell so for example: