FAQ Database Discussion Community


Table sorting based on the number of occurrences of a particular item

sql,postgresql,multiple-columns
Here is a example table with 2 columns. id | name ------------ 1 | hello 2 | hello 3 | hello 4 | hello 5 | world 6 | world 7 | sam 8 | sam 9 | sam 10 | ball 11 | ball 12 | bat 13 |...

Pass multiple value in where clause in SQL Server

sql,sql-server,case,multiple-columns,where-clause
SELECT "dbo"."ClaimDataFormat"."AGE", "dbo"."ClaimDataFormat"."RELATION", "dbo"."ClaimDataFormat"."NAME", "dbo"."ClaimDataFormat"."ENTRY_DATE", "dbo"."ClaimDataFormat"."CLAIM_AMT", CASE WHEN "dbo"."ClaimDataFormat"."Gender" = 'F' THEN 'FEMALE' ELSE 'MALE' END AS GENDER, "dbo"."ClaimDataFormat"."STATUS", "dbo"."ClaimDataFormat"."APPROVED_AMT" FROM "dbo"."ClaimDataFormat" WHERE "dbo"."ClaimDataFormat"."AGE" = CASE WHEN ${TimeGran} = '0-10' THEN 0 WHEN ${TimeGran} = '0-10' THEN 1 WHEN ${TimeGran} = '0-10' THEN 2 WHEN ${TimeGran} = '0-10' THEN 3...

List items in columns from top to bottom instead of left to right

html,css,css3,responsive-design,multiple-columns
I have a list of countries in alphabetical order like: Albania Andorra Armenia Austria Azerbaijan Belarus Belgium Bosnia and Herzegovina Bulgaria Croatia Cyprus Czech Republic Denmark Estonia Finland France Georgia Germany Greece ... I'm displaying them in a list: <ul class="mylist"> <li>Albania</li> <li>Andorra</li> <li>Armenia</li> <li>Austria</li> <li>Azerbaijan</li> ... </ul> The list...

Column height via Javascript

javascript,jquery,html,css,multiple-columns
I am using columns: 15em; to automagically format some images on a page. I would like to put filler images in the empty bottoms of the columns, shorter then the longest column. Can I find out what height these images would need to be? Also sometimes the columns don't format...

Update same column on multiple rows with different values

php,sql,multiple-columns
I want to run a cron job daily to update the dadmin_reminder_date, dshipment_date, and darrival_date. I need to add icmd_days to each of the current dates. Ex. For the second row(couldn't upload the image) the output should be old(05/07/2015)/new(06/04/2015),old(05/07/2015)/new(06/04/2015),old(05/15/2015)new(06/12/2015). The icmd_days = 28 for this row. Each row has a...

Excel merge all columns with VBA

excel,excel-vba,merge,multiple-columns
I'm using MS Excel 2010 and i have an excel sheet without macro's and without formula's everything is in raw format. The sheet contains a lot of columns and rows (column A to WC) as shown in diagram below. ~ represents split view between columns # represents row number |...

bug in bash sort with different columns?

bash,sorting,multiple-columns,cut
I am working with a file that contains 3 values, an ID (they happen to be protein ids in case you are curious), a value, and then another value. It is tab delimited, so it looks like this: A2M 0.979569315988908 1 AACS 0.925340159491081 1 AAGAB 0.982296215686199 1 AAK1 0.736903840140103 1...

Oracle SQL multiple columns aligned to a single range/legend

sql,oracle,date,multiple-columns
I have an activity table in my application. It has a project ID, an activity ID, a baseline finish date, an actual finish date a planned finish date and a late finish date. I want to take the count of activity ID for each week of the project in each...

Datagridview column SUM to textbox & update textbox with each adding row

c#,datagridview,sum,multiple-columns
I'm new to C# & i need your help with my below problem. I've DGV & its not bound to any data source. I have few textboxes & datetimepicker to add data to DGV. Once the user press the "ADD" button in my form it will add new row to...

regexp format and using 2 cell arrays

regex,matlab,multiple-columns,cell-array
I have a matrix made of 20x cells named T. each cell in this matrix contains the next thing: 1,26:00:01.490, 2.40,101.2, 7.8,-24.0,20.40,-0.76,-0.26 i would like to delimit and split it into columns so i used: Data=regexp(T,',','split'); The result is that im getting Data = 20x1 cells and inside each cell...

Python Pandas - n X m DataFrame multiplied by 1 X m Dataframe

python-2.7,pandas,multiple-columns
I am trying to multiply a 10X7 Pandas dataframe by a 1X7 dataframe in Python. Here is what I have: df = pd.DataFrame(np.random.rand(10,7),columns=list('ABCDEFG')) df_1 = pd.DataFrame(np.random.rand(1,7),columns=list('ABCDEFG')) I tried this: df_prod = pd.DataFrame(columns=df) for i in range(0, df.shape[0]): df_prod.iloc[i,:] = df[i,:].tolist()*df_1.iloc[0,:].tolist() But I get this error message: Traceback (most recent call...

Pandas, create columns after groupby

python,pandas,group-by,multiple-columns
Regarding the Pandas DataFrame 'test_df': id_customer id_order product_name 3 78 product1 3 79 product2 3 80 product3 7 100 product4 9 109 product5 After a groupby on 'id_customer' how is it possible to get: id_customer order_1 order_2 product_name_1 product_name_2 3 78 79 product1 product2 7 100 product4 9 109 product5...

css positioning to mimic html table

html,css,css-position,multiple-columns
I am working on a project there I want to display data in 2 columns. Each column would contain a heading that I am trying to position on the left of the column and some data that would be positioned next to the heading (right side of the column). The...

Rename two columns in netezza using single query

table,rename,multiple-columns,netezza,alter
I am new to netezza. I need to know how can we rename two columns with a single query. I've tried , ALTER TABLE tabemp RENAME COLUMN salary to empsalary and name to empname; ALTER TABLE tabemp RENAME COLUMN salary to empsalary , name to empname; But none of these...

3 column responsive footer

html,css,responsive-design,multiple-columns
I have a responsive grid layout for thumbnail images and a full width header. It is built using 'ul' and 'li' to make the grid. So basically I'm not using a responsive grid layout throughout. Although I would like to have a three column footer at the bottom that is...

Selecting rows based on multiple conditions using OR instead of AND in R

r,multiple-columns
I have a large dataset that I am trying to filter based on the value of 2 separate columns. For each row I have a column showing their total count (tot) and a column showing the total times that type of sample was seen (tot.type). I want to filter my...

HTML / CSS Column Scrolling

html,css,scroll,multiple-columns
I have two columns on my page. The left column is one long list, the right is smaller. When I scroll up and down I want the right column to float with the page not be static. I've managed to get this working using this css: .connected { min-height:100px; float:...

Select minimum value in columns after comparing each column to an input in sqlite

sqlite,input,compare,multiple-columns,value
I have the following table: Qual | C1 | C2 | C3 | C4 | 50 | 0.2 | 0.5 | 0.9 | 1.2 | 100 | 0.3 | 0.7 | 1.1 | 1.7 | I have an inputX1 (for example 50) and another inputX2 (= 0.7) and I am...

Cannot obtain result from searching csv file in Python

python,database,csv,search,multiple-columns
For an assignment I've got to code a program which can search a tab delimited text file of academic papers for certain values i.e. search for the author in the author column and then print the whole row. Here is the code so far... import csv import sys #Assign File...

how to display data in two column with php with header

php,mysql,multiple-columns
I have database --------------------------------------------- no | name | code | grade --------------------------------------------- 1 | john | A1 | C 2 | john | A2 | D 3 | john | A3 | B 4 | tom | A1 | A 5 | john | A4 | A 6 | alice...

2 Column paragraph

css,multiple-columns,paragraph
I know it's not hard to do that but I want to know the best way to achieve this In case of responsive the right part need to go above the left part for each item. Basically we have something like his 1 2 3 4 5 6 And in...

Re-arrange column order in mobile view

html,css,responsive-design,multiple-columns
I have a 2-column layout (C1 & C2). Inside C1 I have 3 boxes (B1, B2 & B3). Inside C2 I have 1 box (B4). On mobile view I would like to make the vertical order of the boxes: B1-B2-B4-B3. How can this be done? I'm open to using flex...

MongoDB - Aggregate max/min/average for multiple variables at once

mongodb,aggregate,multiple-columns
I am logging data into MongoDB in the following format: { "_id" : ObjectId("54f2393f80b72b00079d1a53"), "outT" : 10.88, "inT3" : 22.3, "light" : 336, "humidity" : 41.4, "pressure" : 990.31, "inT1" : 22.81, "logtime" : ISODate("2015-02-28T21:55:11.838Z"), "inT2" : 21.5 } { "_id" : ObjectId("54f2394580b72b00079d1a54"), "outT" : 10.88, "inT3" : 22.3, "light"...

Turning one row into multiple rows in r

r,multiple-columns,transpose
In R, I have data where each person has multiple session dates, and the scores on some tests, but this is all in one row. I would like to change it so I have multiple rows with the persons info, but only one of the session dates and corresponding test...

SQLite keeps returning error from CursorWindow (failed to read row)

android,sqlite,multiple-columns
I've been trying to solve this all night long and I can't find a solution. I keep getting the following error: 05-15 02:02:39.685 8757-8757/com.financeiro.coolkey.financeiro_2 E/CursorWindow﹕ Failed to read row 0, column -1 from a CursorWindow which has 4 rows, 7 columns. 05-15 02:02:39.686 8757-8757/com.financeiro.coolkey.financeiro_2 D/AndroidRuntime﹕ Shutting down VM 05-15 02:02:39.687...

Angular ng- grid - hide/remove column input from column menu

javascript,angularjs,grid,multiple-columns,ng-grid
When you use the flag 'showColumnMenu' with true value. the ng-grid is rendered with button on the right end top panel. Using this button we can hide/show the column on the grid. In my Case I don't want to make it possible for some column to be visible on the...

Oracle sql: Drop table column shows error: invalid identifier? [closed]

oracle,multiple-columns,ddl,alter-table
I get this error when I am trying to drop multiple column in one statement:- ALTER TABLE "RLX_ROLES" DROP COLUMN ("test","test_2"); But it works if I drop them one by one:- ALTER TABLE "RLX_ROLES" DROP COLUMN "test"; ALTER TABLE "RLX_ROLES" DROP COLUMN "test_2"; Why so? Is my syntax not correct?...

How to reset the ordering of columns with bootstrap 3 at extrasmall screens with preserving showed html markup?

html,css,twitter-bootstrap-3,order,multiple-columns
Here is the html code what is: <div class="col-sm-9 col-sm-push-3">Content</div> <aside class="col-sm-3 col-sm-pull-9">Some aside text</aside> At extrasmall screens main content goes first before the aside section. But how to make it go first and the aside element second preserving initial html markup and only at an extrasmall screens? and all...

Printing out multiplication table in python

python,multiple-columns,nested-loops
Currently I'm doing this problem and I've ran into errors. I decided to practice my nested for loop logic with somewhat of a more complicated strategy even though there are several easier methods. I'm a beginner coder so I hope my documentation is not confusing on my thought process. import...

min-height css property affecting multicolumn layout in text in an unexpected way

html,css3,multiple-columns
My problem: I'd like to set a min-height to a text container <div> with columns. This min-height should affect the whole div, as usual, so regardless of the text inside, the div would always be at least the specified height. However, when I assign a min-height property to a multi-column...

Python Pandas - Changing some column types to categories

python,numpy,pandas,multiple-columns,categories
I have fed the following CSV file into iPython Notebook: public = pd.read_csv("categories.csv") public I've also imported pandas as pd, numpy as np and matplotlib.pyplot as plt. The following data types are present (the below is a summary - there are about 100 columns) In [36]: public.dtypes Out[37]: parks object...

Delete lines in a file based on first row

terminal,multiple-columns
I try to work on a whole series of txt files (actually .out, but behaves like a space delimited txt file). I want to delete certain lines in the text, based on the output compared to the first row. So for example: ID VAR1 VAR2 1 8 9 2 4...

SQL Statement Issue combining 4 tables to get the correct information to display

sql,sql-server,multiple-columns
I am having trouble figuring this one out. I'm using MS SQL 2008 and trying to add the total tech hours from the unbilled table and the billed tables and group them together. I also need to exclude rows for the billed hours based on the report header on a...

Weird quirk when re sizing columns with css

html,css,multiple-columns
I posted an earlier question about making having columns wrap in a way that utilizes the most space in the viewport, right here. Combining some of the answers, I came up with the following jfiddle. I will be having a variable number of columns (2-5) and a variable number of...

SQL server duplicates, results with XY, YX duplicates

sql,duplicates,distinct,multiple-columns
i have table containing some information about some companies. the table contain this columns. Connectionkey|Phonenumber|Lastname|Firstname|Categoryid1|housenumber|Streettype|Street|Zipcode|Locality|Createts|lastuserid I am trying to extract duplicate rows based on some columns SELECT Dup.Connectionkey, Dup.Phonenumber, Dup.Lastname, Dup.Firstname, Dup.Categoryid1, Dup.housenumber, Dup.Streettype, Dup.Street, Dup.Zipcode, Dup.Locality, Dup.Createts, Dup.lastuserid, Dup1.connectionkey, Dup1.Phonenumber, Dup1.Lastname, Dup1.Firstname,...

Elementwise Subtraction(or addition) of columns from two dataframes based on the same values/matches in other columns

python,pandas,multiple-columns,multiple-conditions,elementwise-operations
I have two data frames. df1 = pd.DataFrame({'Ver' : [2,2,2], 'SN' : [1,1,1], 'Split' : [AA,AA,AA] 'Quad' : [3,3,4] 'Channel' : [1,2,0] 'Mean' : [1,2,3] 'Other' : [10,10,10] 'Mean2' : [1,2,3] 'Other2' : [10,10,10] }) df1 = pd.DataFrame({'Ver' : [2,2,2], 'SN' : [1,1,1], 'Split' : [AA,AA,AA] 'Quad' : [3,3,4] 'Channel'...

responsive wordpress columns from scratch

wordpress,multiple-columns
I'm developing a custom wordpress theme and currently using the column shortcodes plugin to achieve columns but they aren't working well. For example, they suddenly stopped going across the browser and will now only display one on top of the other except for on one page where they will work...

Display mongodb multiple group by query results in a nested format

mongodb,group-by,nested,aggregate,multiple-columns
Given the following dataset: [ { "account_id" : "1111" "task_id" : "aaaa", "workweek" : "20", "hours": "18" }, { "account_id" : "1111" "task_id" : "aaaa", "workweek" : "20", "hours": "12" }, { "account_id" : "1111" "task_id" : "aaaa", "workweek" : "21", "hours": "10" }, { "account_id" : "1111" "task_id" :...

CSS3 Columns and pseudo element positioning

css,css3,multiple-columns,pseudo-element
I've got a page with CSS3 columns, and I am trying to place a pseudo element at the same Y position as the inline element, but at a fixed X position (in the left margin). This works great on the first column, but the rest of these pseudo elements in...

get multiple columns from multiple files into a single file shell

bash,shell,multiple-columns
Hi, I have multiple files with the multiple columns, I want to select few different columns from every file and make it to single file. I have read the post file1 Day present absent total Mon 10 1 11 TUE 11 0 11 WED 9 2 11 THU 8 3...

Bash: Get modified `ls`-like output (multiple entries per line)

bash,multiple-columns,ls
When you call ls without additional options on the command line, you get multiple entries per line. Contrived example: $ ls mydir/*.tar.gz mydir/foo.tar.gz mydir/bar.tar.gz mydir/baz.tar.gz But if you want to modify the output in some way, you get one entry per line: $ ls mydir/*.tar.gz | sed "s/\.tar\.gz//g" mydir/foo mydir/bar...

taking some values from a column to make multiple new columns matched by an id column in R

r,multiple-columns,subsetting
I have two data frames in R: df1 Site_code Species_code Abundance 1 MRN 50 1 TFP 100 2 MRN 5 2 XNP 20 2 AMP 15 and in df2 I have a bunch of information, as well as the site code, but there is only one row for each site....

Matlab: How to write column number into new column if logical condition is met

matlab,multiple-columns,logical-operators
I have a sample matrix like this in matlab (though my real matrix contains many more columns) List = [0,0,1;1,0,0;0,1,0;0,1,0;0,0,0] List = 0 0 1 1 0 0 0 1 0 0 1 0 0 0 0 What I am trying to find is a way how I could summarize...

I need a query multiple columns each date in same table

mysql,multiple-columns,calculated-columns
I have this table structure Date | Success | No of success tran.| Failed | No. of failed tran 29/05/2015 | Total Amount | count success tran.|total amount| count failed tran I want "Date" to have datetime. "Success" to have total sum of success amount. "Number of success transactions" to...

Xpages checkbox group multiple columns?

css,css3,checkbox,xpages,multiple-columns
I want to format a checkbox group into 2 or more columns. I have read about a CSS3 solution using display, width, and float. It doesn't appear to work in IE9+. Is there a simple solution to doing this?...

Compare two columns from two sheets contains different names of peoples and return numeric value on third

excel,excel-vba,excel-formula,spreadsheet,multiple-columns
I want to compare "Sheet 2" "Column A" (which contains the name of 300 people) with "Sheet 1" "Column A" (which contains the name of 28 people). Now I want write down a formula on "Sheet 2" "Column B" to see whether those 28 people (Sheet 1, Column A) do...

Find Pandas dataframe column based on values, in Python

python-2.7,pandas,multiple-columns
I have 2 Pandas Dataframes in Python. Here they are: import numpy as np import pandas as pd df = pd.DataFrame(np.random.rand(10,3),columns=list('ABC')) df2 = pd.DataFrame(np.random.rand(10,3),columns=list('ABC')) df['A'] = 1 print df print df2 A B C 0 1 0.333141 0.803991 1 1 0.043958 0.582038 2 1 0.833433 0.782856 3 1 0.722592 0.237912...

Averaging rows by multiple column variables in R

r,ggplot2,average,bar-chart,multiple-columns
I am trying to create a multiple bar chart of my data, depicting the mean of avgct for each region with error bars using ggplot2. Here is a sample of my data: gregion lregion avgct 1 e 1.146 1 e 0.947 2 e 0.908 3 e 1.167 1 t 1.225...

MySQL: Select with multiple row based in quantity column

mysql,multiple-columns
I have a order table like: product|quantity Example: bread|3 I need a select like: row1- bread row2- bread row3- bread I made like this: SELECT product FROM ( SELECT product FROM order WHERE quantity > 0 UNION ALL SELECT product FROM order WHERE quantity > 1 UNION ALL SELECT product...

How to reclassify dataframe column?

r,data.frame,multiple-columns
I am working on reclassifying values in one dataframe column and adding those values to another column. The following script attempts to apply a reclassification function to a column and output the values to another column in a dataframe. a = c(1,2,3,4,5,6,7) x = data.frame(a) # Reclassify values in x$a...

I need to sort MYSQL results by a number passed in OR another column

mysql,sorting,multiple-columns
Here is my table with my select statement: SQLFiddle I want to group by job_id and then sort it by a number passed in, (in this case the number is 2) If there is no match then show result with default marked as true If none are marked as true...

How to update multiple columns with different where clauses in mySQL

mysql,sql-update,multiple-columns
im trying to update multiple columns in a table that all needs different where clauses in single query. Im not amazing at sql, and struggle to find help on google. im trying to achieve something like this UPDATE $table SET meta_value = 'john', meta_value = 'v1234' WHERE meta_key = 'name'...

Split long column into several columns and print them side by side

python,python-3.x,multiple-columns
Using this code: import string for i, j in enumerate(string.ascii_uppercase, 1): print('{}: {}'.format(i, j)) I get the following output: 1: A 2: B 3: C 4: D 5: E 6: F 7: G 8: H 9: I 10: J 11: K 12: L 13: M 14: N 15: O ......

zurb foundation make column width persist across screen sizes without individual declarations

html,css,zurb-foundation,multiple-columns,grid-layout
Using zurb foundation, I'm looking to have a single class declaration that will persist across media query breakpoints. For instance, if I wanted to create a div that was 10 columns no matter if it were being viewed on a desktop or a phone. I realize this can be accomplished...

How to fill CSS3 columns starting from the end with empty ones at the beginning?

css,css3,multiple-columns
I want to fill CSS3 columns starting from the end. Is there a way to do this with pure CSS? So if I have for example 4 columns, they should look like this: empty | empty | empty | content I tried direction: rtl; but it makes only one column...

Sql code to get multiple columns out of single column

sql,sql-server,ssis,multiple-columns
I have a column like "AP.1.12345.ABCD.20150523_0523.20150524_0223". Can i divide the column into multiple columns on basis of " . " ? Say for above example column, the output will be like AP 1 12345 ABCD 20150523_0523 20150524_0223. Thus single column will be converted into 6 columns. ...

PHP Mysql PDO query from foreach multiple values stored for output

php,mysql,pdo,foreach,multiple-columns
Today i've been searching on how to store the different values from a query which is injected 4 times with different categories. The result is as i wanted i got the values but when i return them i only get my last query as result. I'm wondering which will be...

Did I applied bootstrap 3 grid system right? [closed]

css,twitter-bootstrap,multiple-columns,grid-system
Here is the initial markup: <div class="product-related-products"> <div class="product-fields-title-wrapper"><span class="product-fields-title"><strong>Related products</strong></span> </div> <div class="product-field product-field-type-R">product1</div> <div class="product-field product-field-type-R">product2</div> <div class="product-field product-field-type-R">product3</div> <div class="product-field...

Add or Multiply Specific columns together

jquery,html,multiple-columns
I have seen a few examples for jquery and adding column values; however, the examples had only one column and one value. I wanted to know if you had multiple columns then how do you grab specific ones? For example, if I want to add all of the Quantity columns...

how to extract two columns of data using R by loop

r,loops,data.frame,multiple-columns
I have a dataframe with 1000 columns of data str(MT) 'data.frame': 1356 obs. of 1000 variables: $ Date : Factor w/ 1356 levels "Apr-1900","Apr-1901",..: 453 340 792 1 905 679 566 114 1244 1131 ... $ Year : int 1900 1900 1900 1900 1900 1900 1900 1900 1900 1900 ......

Perl : How to match data in entire text

perl,csv,match,multiple-columns,variant
In the following code I am trying to use data from Input File 1 to edit data in Input File 2. But the problem is the code is not able to match or substitute when the possible match text is anywhere other than at the last, towards right. Could you...

How to proper align after CSS column-count

html,css,multiple-columns
I'm working on an unordered list. I'm trying to display the content in multiple columns. I've managed to do this with CSS's column-count, however the content is not displayed properly. It seems like the first item of the list is placed on the second position, resulting in a crooked list....

Calculate median of multiple columns

excel,vba,excel-vba,multiple-columns,median
In my worksheet, named "Sheet1", Column A through Column J, each column contains various values (so they all have different number of rows). How to calculate median of these columns and put the calculated median in row9, and columns M through V? I known how to store the calculated median...

Rows to Columns

linux,python-2.7,row,multiple-columns
I have my text file as follows: TOPIC: 0 161416.0 the 10758.0 . 6330.0 , 5043.0 <unknown> 4591.0 in 4521.0 be 4476.0 of 3759.0 TOPIC: 1 93549.0 the 6957.0 , 4170.0 of 3624.0 . 3468.0 <unknown> 2321.0 be 2121.0 a 2073.0 in 1998.0 and so on. I have about 2000...

split file into columns with awk

bash,file,awk,multiple-columns
I have a file which looks like this: 1. result = 1.2.3.4 (1.2.3.4) info: [Affected] 2. result = www.addr.com (2.3.4.5) info: [not Affected] And now I want to split it in three columns, example: 1.2.3.4 1.2.3.4 Affected www.addr.de 2.3.4.5 not Affected I am using awk for that: cat filename.txt |...

Add text and image to specific cell of a table in Google Doc using Apps Script

arrays,google-apps-script,google-docs,multiple-columns,tablecell
Context: I have a program that creates a photo directory for 6th-12th grade students and leaders/teachers in a google document. For each student, it inserts a picture, and then several separate lines of text (name, phone number, etc.). Before the start of each new grade, text is inserted to label...

Compare two files with first column matching text and 2nd column of first file > than 2nd column value of 2nd file

awk,compare,multiple-columns
Looking for an awk one liner: I have two files each with two columns I need to print records where the first column match in both files and where the second file value column is > than the first file value column. file1 AAAA 322 BBBB 322 DDDD 200 file2...

Multiprocessing pool not working in user defined function

python,numpy,multiple-columns
I wanted to implement multiprocessing pool. But if it is a bug or my mistake I am not able to do so. The pooling works perfectly with numpy function while with the user defined function it runs into error. import numpy >>> import multiprocessing >>> P = multiprocessing.Pool(5) >>> P.map(numpy.sqrt,range(50))...

MySQL Database design with multiple column or single column

mysql,database,performance,multiple-columns
Hi just a simple question I need to store data to database, there are 2 option to show now Data : a,b,c,d 1. store a,b,c,d in 1 column, when needed only query and perform splitting in application 2. store a,b,c,d to 4 different column, can query directly from database Which...

Column displays each count

sql,oracle,multiple-columns
I am trying to run a query to count records based on a time stamp year to year. Here is a query that I currently have: SELECT plocation AS GROUP_NUMBER, count(DISTINCT UMEMBERID) AS YEAR_ONE FROM HEALTH_ASSESSMENT WHERE PUBLICATIONDT > '31-DEC-13'AND PUBLICATIONDT < '01-JAN-15' GROUP BY PLOCATION It counts exactly what...

Working with multiple columns from a data file

python,arrays,scipy,multiple-columns,data-files
I have a file in which I need to use the first column. The remaining columns need to be integrated with respect to the first. Lets say my file looks like this: 100 1.0 1.1 1.2 1.3 0.9 110 1.8 1.9 2.0 2.1 2.2 120 1.8 1.9 2.0 2.1 2.2...

Get an array of rows from a MySQL query?

php,mysql,multidimensional-array,row,multiple-columns
I have this code... $results_query = "SELECT * FROM profile WHERE string LIKE '%" . $search_deliminator . "%'"; $results_result = $database->query($results_query); $result = mysql_fetch_array($results_result); What I'm trying to do is pull all the rows in which the string column contains my search deliminator. Further, I would like to get the...

Re sizing columns with restriction in CSS

html,css,multiple-columns
So I have a weird question. This is what I have so far. In the jfiddle, there's 3 columns of words, but in reality, I will be between 2 and 5. The problem is the columns can be long, but short in width. What I'd like is to be able...

SQL selection by column values [duplicate]

sql,sql-server,select,multiple-columns,multiple-tables
This question already has an answer here: How do I find a value anywhere in a SQL Server Database? 12 answers I am working with a really messed up DB that has a a lot of tables and some of the tables have huge numbers of columns with bad...

R: Update columns in a data.table

r,data.table,multiple-columns
In R I have a data.table of the following structure: DT <- data.table(M=c(1,2,3,4,5), N=c(2,3,1,1,4), mu=c(1,10,100,1000,10000), sigma=c(10,10,10,10,10)) Here M is the simulation number, N the number of observations an mu and sigma are the parameters for the normal distribution. According to the number of observations I want to generate random numbers...

AngularJS: orderBy - string & array are not the same

angularjs,multiple-columns,angularjs-orderby
I have an array of users: $scope.users = [ {name: 'Anh', age: 10}, {name: 'Ánh', age: 10}, {name: 'Ba' , age: 10} ] When i use orderBy:'name' the result is: Anh Ánh Ba but when i use multiple fields orderBy:['name','age'] the result is different: Anh Ba Ánh Waiting for your...

How to display list items as columns preserving the left-to-right order?

css,list,multiple-columns,flexbox
Is it possible in pure CSS to lay out list elements to arbitrary number of columns, preserving the left-to-right order, as on this example? ...

LEFT JOIN on multiple tables in “FROM” part

mysql,left-join,multiple-columns
I'm unable to find an exact example on stackoverflow, so here is my problem. In MySQL 4.x it works fine, but 5.x seems not to like the following: SELECT some stuff.. FROM schools, member , applications LEFT JOIN courses ON courses.id = applications.course_id LEFT JOIN staff ON staff.id=member.staff_id This section...