Query Syntax

47K

Solutions

12

Articles & Videos

17K

Contributors

SQL (Structured Query Language) is designed to be used in conjunction with relational database products as of a means of working with sets of data. SQL consists of data definition, data manipulation, and procedural elements. Its scope includes data insert, query, update and delete, schema creation and modification, and data access control.

Refine results

I need to use DATEDIFF using three dates. I need to add two dates, receiving date and ship date and subtract the time we have been waiting on quote approval for units. I am already using datediff with…

318 views
DevOps Toolchain Recommendations
DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Hi. I am using the following SQL Statement to get a Unique list of the combination of Date and  Shift. Is this correct or will it only give me a unique list of [Date]?

SELECT DISTINCT [Date], …

39 views

I have the following in an Access query and it works fine:

(CODE)

I need to add another If statement... if InventoryProfile.MAPPricingAmount <> $0.00 or <> Is Null, use the amount in that field …

2522 views

Working on a query. Here are the details:

Table: REQUEST
Columns: StartDate, EndDate, Type, Hours, Status, EMPLID

Table: ACCOUNTS
Columns: ID, FULLNAME, MGRID, EMPLID

I would like to:

1623 views

Hi EE,

I have the following query:

(CODE)

When I run it though I getting the following errors:

Database name 'TempDB' ignored, referencing object in tempdb.


What is causing this error…

212 views

what's the best way to  (performance wise) or other  to write this query to get all the fields that are 25 days old


select 1, 2
from table
WHERE DATEADD(DD,25,ThisDATE)>=GETDATE()

422 views

hi i have the following cursor in my 12c database
(CODE)

am geting the above error but in 11g is ok am running this in plugable database

529 views

Hi

I am trying to build a SQL statement from an Excel spreadsheet where the user selects several cells which contain addresses.
The resulting statement would look like this
Select * From …

210 views

I am in a job where I sometimes need to make a "hot fix" to the live production database, and have been told we need to start using transactions to reduce the risk of causing a bigger problem than we …

923 views

Where can I find a tutorial on ServiceCenter IR Query expressions?  What language does service center use for IR Query?  I need to built a custom query for all tickets open for a primary assignment …

117 views
Gigs: Get Your Project Delivered by an Expert
Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Hello,

I have two tables one with fields I need such as ID, clientID, table  andCustomerID the second table has the ID of the record in table and a total column. I am trying to get a subtotal …

2745 views

Hi Experts,

I am looking to place the contents of 6 fields into 2 fields as follows.

We have Date1 Column (Datetime) and Results1 column (varchar(50), then Date2 column and Results2, and Date3 …

1643 views

The following statements return numbers from a-z but I need a new column to calculate the change as a number.
For example, if the letter for Q1 is B and Q2 is D, then the output would be +2.  If Q1 …

324 views

I want to get four query results, not two:

select count(*) as SecondYearInterestIsNo  from APSecondYear where SecondYearInterest='No'

select count(*) as SecondYearInterestIsNO  from APSecondYear…

226 views

We have a database that information is fed into and at 4:30am every day we want to be able to append the information for the prior day (4am-4am) to another table in another database.  We want to be …

221 views

I have a server with multiple ODBC connections.
I want to create a connection string that will connect to all those ODBC (each for one database), so that when I run a query it will query all …

1319 views

I see a working query with the following select statement:

            SELECT
                  , hfext.Family_id, 0 IsAPStartMatching, MAX(ack.AgreedDate) StartMatchingDate
            FROM

what function does the '0' server …

526 views

I have a scenario where I have to run a query on multiple databases from a database "A" using database links from "A" database.
I have a table in "A" database which should insert the pulled data from…

3062 views

Hi,
I have some data that I was to parse or separate out, that is initially in 1 row and want to separate into
different rows.  As seen in the data samples below.  I was looking at examples but they…

231 views
Courses: Start Training Online With Pros, Today
Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Experts,

In this code I am trying to do 2 things. The first is to bring back in single rows a combination of header and detail information. The second is to create a ranked line number in …

623 views

I have 3 queries like follows:  I am not sure how to make the union due to the cte...I was thinking the cte might have to be a temp table and the the unions some how combined that way..Please help …

936 views

Can we can query the email header (message detail) in the  email activity record?

Our goal is to use the Office 365 transport rule to add the contact name to the subject line of an email and then …

1254 views

The AuPair table has a non-primary key called AuPair. APNo.

I am getting incorrect syntax.

Suggestions?

Thanks!

(CODE)

743 views

how to compare two NULL value so that if both are NULL then return true

430 views

I have a field Accept_Referral

IF the value is 'yes' in want the derived column to return 1
if no the derived column should be 0
if null then just leave it as null

How?

728 views
Show more content
201506-LO-Top-001

TOP EXPERTS

view all

RELATED TOPICS view all topics

  1. MS Access
    (216,157)
  2. MS SQL Server
    (157,558)
  3. MS SQL Server 2005
    (71,562)
  4. MS SQL Server 2008
    (49,070)
  5. Databases
    (53,700)
  6. MySQL Server
    (46,533)
  7. Oracle Database
    (78,050)
  8. PHP
    (117,724)
  9. ASP
    (80,722)
  10. Visual Basic Classic
    (163,615)