Skip to main content

All Questions

Tagged with
0 votes
0 answers
66 views

Excel CopyFromRecordset method has suddenly gotten very slow but still fast in debug mode

The code below has worked very well for the last 6 or 7 years. The database is SQL Server 2008 R2, the client is Excel 365 64-bit (v.2502). Over the past few months, some users are seeing execution ...
JanMarek's user avatar
0 votes
0 answers
40 views

Leading zero being dropped in Hive SQL when downloaded in Excel

I did some analysis in Hive but when I export it to a .csv file, it's dropping the leading zero. Is there a way to preserve this? i.e. a group by variable is being converted from "07895" to &...
Dave Diggler's user avatar
0 votes
1 answer
74 views

Reading an Excel in SQL through OpenDataSource (OpenRowSet): rows order?

I have T-SQL code for SQL Server 2012 to read an Excel file into a temp table. I do this using OPENDATASOURCE: INSERT INTO #MyTable (id, F1) SELECT ROW_NUMBER() OVER (ORDER BY (SELECT 1)) AS id, F1 ...
Victor Sotnikov's user avatar
1 vote
1 answer
61 views

Problem with cleaning csv data before Importing in PostgreSQL

I started studying SQL a month ago. I'm trying to import a .CSV file but I have a problem. In the that file, there are numbers written in quotes and where decimals are divided by commas. In Excel, if ...
Simone Romualdi's user avatar
1 vote
2 answers
61 views

Running SQL query from excel and refer to specific cell

I'm using excel to run sql query and i want to refer the WHERE command to a specific cell in excel. For example, my code is: SELECT [Value] FROM [Sheet1$] WHERE [ClientID]=2> Instead of 2, i went ...
Sharon's user avatar
  • 21
0 votes
0 answers
38 views

Pass multiple cells as parameter in Excel query

Let´s say I have a column with 10 unique ISIN values in Excel. I want to pass these ISINs as an argument/parameter to query. I know it works with a single cell, where I put "?" in the query ...
Vladimír Ondrášek's user avatar
1 vote
2 answers
55 views

Convert a value column into multiple columns in Power BI per customer

I would like to know how to convert the following table Customer Score ABC 25 ABC null DEG 1 XYZ 10 XYZ 7 XYZ 0 XYZ 26 into this: Customer Score1 Score2 Score3 Score4 ABC 25 null DEG 1 XYZ 10 7 0 26 ...
Data123's user avatar
  • 33
2 votes
2 answers
94 views

sql in excel vba - child parent subquery

I am trying to select only rows from the INPUT table which do not have a child - in SQL.The result is in OUTPUT. To make it easier, for now, I am considering only the columns 5H and 6H (the other ...
Peter's user avatar
  • 31
1 vote
2 answers
70 views

SQL in VBA EXCEL - compare rows in the same table

I would like to insert into the table OUTPUT the data from the table INPUT. Both, INPUT and OUTPUT have these columns: name, 1H,2H,3H,4H,5H,6H. The data in INPUT have a hierarchy structure. Into the ...
Peter's user avatar
  • 31
0 votes
0 answers
64 views

How to ensure that NULLs from the database are exported to Excel spreadsheet as NULLs (or blanks cells) and not 0s

I am trying to export the results of a stored procedure to an Excel spreadsheet. However, although the database has some values of 0 (for temperature and hours of use) which are relevant values, it ...
Need Help's user avatar
0 votes
0 answers
50 views

SQL query to export data in excel anda update columns written in Excel

I would like to know if it is possible and, broadly speaking, how to perform a daily extraction from Microsoft Navision into an Excel file using SQL. Specifically: About 15 columns are standard fields ...
Divad's user avatar
  • 11
-1 votes
1 answer
119 views

"SQL Error [XX000]: ERROR: Numeric column 2 precision and scales cannot be merged" when coding logic in REdhsift

Such code gives me an error of: "SQL Error [XX000]: ERROR: Numeric column 2 precision and scales cannot be merged" WITH RECURSIVE build (PERIOD_START_DATE,PEQ,PREV_PEQ,repeated_patient, ...
Kondjitsu's user avatar
-1 votes
2 answers
133 views

Power Query: Convert existing data set, individual rows into columns based on Dates

I have a data set where a customer may have had multiple assessments over a period of time. Now each customer's behavior towards these assessments may vary, meaning C1 may have had theirs on day 1, ...
Data123's user avatar
  • 33
-1 votes
2 answers
50 views

Translate excel formulas into Redshift SQL query

I am looking for help to translate excel formulas into Redshift SQL . With given fixed input values for rows 1 (Month ascending) and 2 (SU - some number) I have to calculate through particular cells ...
Kondjitsu's user avatar
1 vote
0 answers
97 views

ODBC: ERROR [HY000] importing data to Excel

I have an ODBC database I can connect to and navigate to correct folder and table. Table has over 200,000 entries and I only want to pull in 258 of them. The column in the table is called WWID and it ...
Lewis Wentworth's user avatar

15 30 50 per page
1
2 3 4 5
302