Structured Query Language (SQL) is a declarative query language for relational databases. Consider also using the tag for the specific database software if your question involves vendor extensions or language quirks.

learn more… | top users | synonyms

1
vote
0answers
23 views

In SQL SERVER how to do ;Third Computed Column = First Computed Column + Second Computed Column + Basic Column [migrated]

I use SQL Server. I have a table with A. One column is for "Interest" B. There are three computed columns : First_val , Second_val , Third_val First_val = 10 % of Interest , Second_val = 20 % of ...
1
vote
1answer
29 views

Running Parameterized Stored Proc From Power Query

I have been following the tutorial HERE but anytime I try to refresh the workbook, it gives me an error of: DataSource.Error: Microsoft SQL: This database function doesn't support the query option ...
0
votes
1answer
19 views

Error when installing SQL Server on new machine

I am installing SQL Server on a brand new laptop with no previous users. Unfortunately I am getting the following error: Has anyone seen this before and know the cause of it?
0
votes
0answers
31 views

SQL server case statement [migrated]

I have the following case statement that I am struggling to get to work. I can see what the problem is but am unsure on how to fix it. CASE WHEN DateDiff(n,Oppo_Opened,GetDate()) < CASE WHEN ...
2
votes
1answer
18 views

In Microsoft SQL Server, how can I disable “X rows affected” at the end of my output?

I'm querying a database in Microsoft SQL Server and writing the output to a csv file. When importing the outputdata into another program i get an error because the last line of my output file ...
0
votes
0answers
7 views

How to Create a Query which Combines Two Crosstab Queries under a Split, Merged Column

Sorry if the title is a little confusing. I am attempting to create a query which takes two cross-tab queries and combines them in a slightly different format than the original cross-tabs. I have used ...
0
votes
0answers
13 views

Converting CSV decimal time value in SQL select statement [migrated]

I have a CSV file I'm loading into a dataset. The time field is actually a decimal value since the type is set to General. How can I convert this time (not Date) to hh:mm format in the SQL statement. ...
-1
votes
0answers
14 views

What is wrong with this JOIN statement in SQL? [migrated]

I am working on this tutorial about SQL. In Step 2 of 2, it is asked to use the JOIN command to link 2 people from the persons list using information from the friends list. I edited the provided code ...
-2
votes
0answers
8 views

I would like to run a SQL Reporting Services service against my Azure Database how can I do this cheaply?

I have an Azure Sql Database. I don't have any SQL Server licences, but would like to be able to run SQL Reporting Services. Happy to pay for something, but I don't really want to pay for a full SQL ...
0
votes
1answer
14 views

Nested IFF query in MSAccess returning wrong number of arguments

I am trying to write a nested IFF query in MSAccess, but on running the error returned is "Wrong number of arguments" My two fields Paper1 and Paper2 are of datatype True/False The Query I wrote in ...
1
vote
1answer
38 views

Outer join with union in Excel 2010 using Power Query

I've got two tables (two worksheets of the same workbook in Excel 2010): The result should look like this: My SQL code works well: SELECT table_2.ID, table_1.value_1, table_2.value_2 FROM ...
0
votes
1answer
24 views

How do you free up Disk Space on a Windows 7 OS? [duplicate]

I've downloaded the sqlexprwt_x64_enu.exe file which was around 700mb and I'm trying to open up the file, but I keep getting the error message of "Unable to find a volume with enough disk space for ...
0
votes
1answer
28 views

(SSIS) Data Flow Task – export SQL to excel file

I'm looking for a solution / tutorial following case. In the MS SQL database I have two tables (invoice, invoice item). I need to export data to excel. My problem is the structure of the export ...
0
votes
1answer
44 views

How do you make a read-write data connection between two Excel worksheets? (I am currently using an od.odc file and a connection that uses SQL)

I have the following project started: Inside of Master.xlsx I have (the worksheet is named MasterList): I then go into CA_Accts.xlsx and make a data connection, with the following steps: ...
0
votes
1answer
16 views

Clustered SQL database requires full recovery mode?

The application we provide customers with requires an SQL database. Due to the nature of the application, we recommend the recovery mode to be set to Simple as it is not critical data that is stored. ...
-2
votes
1answer
18 views

Convert a (-ve) number to a (+ve) or absolute

How do I update a field in a SQL table to change a neg to a pos. (Multiply *-1) I have some data that was loaded using a mapper tool. Unfortunately the data should have been - and was +. The software ...
1
vote
2answers
158 views

Can't install SMSS 2016 March Preview

I am trying to install the latest Microsoft SQL Server Management Studio release. This is what the installation log looks like just before the installation fails: ...
0
votes
0answers
28 views

how to find out session id of executing ssis package through SP_target

I am executing a ssis Package which contains only one data flow task. Simply SELECT statement in source and Table in destination. I want to find out session id of this running Package in SP_TARGET. I ...
0
votes
0answers
34 views

“Navicat for PostgreSQL” gives error “80070003: PrectServer2 not connected” when attempting to autocomplete with materialized views

For some reason I get the error "gives error "80070003: PrectServer2 not connected" when Navicat tries to autocomplete. Take the following example select co.| from visualize.co_mention co When the ...
0
votes
0answers
35 views

VBS for SQL 'Update' statement

Struggling a bit with what I assume is quite simple so wondering if you can point me in the right direction. I want to automate the following SQL command: Update Tablename SET COLUMN ='12/03/2016 ...
0
votes
0answers
55 views

how do i filter by a rolling date range from a sql query

I am trying to filter a query by a date range, but a moving date range. I have heard (read on this site) that this can be handled in a formula in excel, but I couldn't really follow the formula that ...
0
votes
0answers
11 views

SQL Server Management Studio 2008 UI Issues

I work in a Citrix VDN virtual machine. When I get disconnected from my session and come back in, SSMS UI has a bunch of mini windows exploded all over the screen (sorry, no better way to describe ...
0
votes
0answers
10 views

Curious search behavior in Sql Server 2014, searching for dot also returns comma results

Background I'm getting some unexpected search results, consider the following pseudo-query: SELECT SomeField1WithSearchCriteria, SomeField2WithSearchCriteria, ...
0
votes
1answer
15 views

MS SQL equivalent of MyISAM?

I'm trying to port an old project from Linux onto current Windows (mostly as a learning exercise). The database side is all MySQL and every table uses TYPE=MyISAM, which I've done a little reading on ...
0
votes
0answers
28 views

Wordpress : clean a infected SQL dump [closed]

I'm currently recovering a wordpress website from an infection (due to Gravity form plugin). I'm backing up the files and the db, in order to perform a clean install on a new WP installation. So ...
0
votes
0answers
46 views

What is the best way to archive a large SQL DB table

Question: I am looking for recommendations on how to archive about 80% of the data in a SQL DB table. Software: I am using SQL Server Management Studio on a windows server. Background Info: I have ...
-2
votes
1answer
22 views

Prerequisites to get SQL cmd in computer

I want to get SQL cmd in my system. Could someone please guide me the complete steps? Even though I have a native client installed, sql cmd is still not appearing in the command prompt even by typing ...
1
vote
1answer
30 views

MS SQL query which split to other table columns

I have two table: table1: |Manager | USER | +--------+------+ |John | Tom | |John | David| |John | Marry| |James | Henry| table2: Now is empty, but must be like: ...
2
votes
1answer
86 views

Convert DateTime with Decimal Time Longer Than 3 digits?

I'm trying to import some data from CSV into MS SQL 2008 Server. I'm using PowerShell's Invoke-SQL, and an SQL script that utilizes BULK INSERT. CSV fields get imported as VarChars and I'm trying to ...
0
votes
2answers
29 views

UTF-8 not recognized in SQL batch process through Putty

I have an .sql file with a few simple "Insert into" SQL commands that are being inserted into a table called Künstler. insert into Künstler (name) values ('Mariah Carey'); insert into Künstler (name) ...
-1
votes
1answer
25 views

commands to upload sql file to database

There is a database file in this path : /var/www/db.sql in server. Our database size is about 800mb. we have to upload this sql file to the database : "age" username : root, password : pass, ...
1
vote
2answers
270 views

Sql Statements in MySQL, the use of the dot operator

The following is the sql statement that I found, and I am still learning SQL thus this might be a silly question for you. SELECT d.name, count(e.emp_id) num_employees FROM department d INNER JOIN ...
0
votes
2answers
29 views

SQL - How to Stop MYSQL from command line

I just noticed when I made an error statement, sometimes, it didn't stop or showed the error. Instead, the line kept going like this one mysql > UPDATE person ->SET birth_data = ...
0
votes
0answers
27 views

SQL Server 2016 installation issue

I've downloaded the SQL Server 2016 CTP 4 this evening and am trying to install it. I get this error message: "The application cannot find one of its required files, possibly because it was unable to ...
-2
votes
1answer
27 views

SQL Server licensing in a virtualised environment

My company has 6 instances of SQL Server 2012 Standard. These instances all run on VMware virtual machines. The licenses for SQL Server came packaged with WonderWare products (WonderWare Historian for ...
1
vote
1answer
34 views

Add column in SQL

I am currently learning SQL, and my current question is. Is it bad practice to have the word "COLUMN" after add when you want to add a column in SQL code? ALTER TABLE FICTION add COLUMN Best_Seller ...
0
votes
0answers
15 views

Cannot connect to SQL Server 2008 R2 from 3rd party program

I am running SQL 2008 R2 on a pc. I usually connect to a server instance from a 3rd party program all on the same machine, but suddenly I cannot connect. When I try I get message about network ...
0
votes
0answers
10 views

Getting data from databse using mysql querry of a php form

I have made a php form and created a database sarokaar for it with a table named persons. I want to get the values of all the attributes printed. I tried but I got error: Database Sarokaar ...
0
votes
1answer
31 views

update multiple fields in SQL

I am trying to update my table in SQL 2012 where the CategoryNumber values should be correspondant for the below name values but it seems that my syntax is wrong. Update mytable SET ...
0
votes
0answers
33 views

Different Sharepoint filepaths in different environments

We have a VBA application in Excel (UserForm) that users use to update another excel workbook via SQL. The two files are side by side in an MS Sharepoint folder. There are two kinds of users – first ...
0
votes
1answer
137 views

SQL Server Management Studio (SSMS) 2012 slow to show results in Grid only

I generally use Microsoft SQL Server Management Studio 2012 (11.0.3000.0) with query results being displayed in a grid. As of 3 or 4 days ago query results have been quite slow, but only ...
0
votes
1answer
43 views

Date values from SQL cannot be filtered in EXCEL

I created a VIEW in SQL which contains a date column. The date column is defined as datetime ,I had to use CONVERT (nvarchar.mydate,103) so I can get the following format : dd/mm/yyyy. Now when I ...
0
votes
1answer
75 views

Replace a filepath column in SQL with new file structure

I have recently changed the structure of a drive where I keep a lot of my 'estimating' files. The problem is, I use a program that has references to some of those files, in the old structure, stored ...
1
vote
1answer
177 views

Submit data to db and load next page PHP and SQL

This is just a test page I am working on. Trying to get my submit button to load the next page "order.php" It just keeps loading the same page. Should I be writing this in PHP or HTML? If you look ...
0
votes
1answer
58 views

what will happen when two users submit same form and the php code having more than one queries will be executed on the server?

I want to ask that what will happen when two user will submit the same form and then the php code having more than one queries in more than one for loops and if statements which alter the table data ...
0
votes
3answers
92 views

How to access SQL Configuration Manager

Upon checking the programs installed on my machine, it says that I have SQL Server 2014 installed. However I can't access the Configuration Manager in the "All apps" of the start menu to make a ...
0
votes
1answer
203 views

In Access, how can I pull data from another table by matching a field?

I am working on an inventory system for a tool rental shop. I have two tables: Details and Tracking. Details has all the basic information about all the customers (Name, Barcode, ID etc.). Tracking is ...
0
votes
1answer
18 views

Is it possible to get SQL string generated from clicking through UI commands in SQL Server Management Studio?

Ok, so SQL Server Management Studio (SSMS) lets me backup and restore SQL databases, which is pretty awesome an application QA Tester. It allows me to test different starting configurations without ...
-1
votes
2answers
113 views

Select distinct from after certain date [closed]

I have a DB with 3 tables: classes, teacher and taught: classes ID (classNum) title (classesType) cost (classesCost) teacher unique int (teacherNum) taught ...
0
votes
0answers
132 views

Changing Microsoft SQL Express Server 2012 Shared Feature Directory

I know that in order to change any directory location, when installing SQL Server 2012, there mustn't already be present other SQL products on the system, otherwise the directory text boxes and browse ...