I would like to know the Oracle SQL query that orders the children in a hierarchy query by the sequence_within_parent column. An example data set and query are: create table tasks (task_id …
IIS connecting to LocalDB
Is there any way so IIS could connect to LocalDB without using the NT SERVICENETWORK SERVICE user account. This account has not suitable permissions. I’m looking use some other default account or …
Import Large SQL File
I am a student conducting some research which involves a sort of data mining. I have several volunteer “node” servers which gather and produce SQL files for me to import on my server and analyze. The …
Cannot start LocalDB
Cannot start LocalDB instance, I have installed and re-installed over and over. Keep getting this error : Start of LocalDB instance “v11.0” failed because of the following error: Error occurred during LocalDB instance startup: SQL Server process failed to start. Anyone any advice ? ? Microsoft SQL…
Can I calculate there’s how many weekend days between two dates in SQL Server?
I’m calculating income of hiring equipments for a report. In that, hiring cost in weekend days will be plus 10% more if compare with normal days. So how can I calculate there’s how many weekend days …
MySQL query to return AVG
Just a practice problem, little bit confusing I’d appreciate it if somebody could clear this up.. I have a DB called Product and another one called PC. I’m trying to execute a query to “find the average hard disk size of a PC for all those manufacturers who also make printers” HereR…
oracle SQL how to remove time from date
I have a column named StartDate containing a date in this format: 03-03-2012 15:22 What I need is to convert it to date. It should be looking like this: DD/MM/YYYY What I have tried without success is: Is there a way to do this? EDIT1: the PA_VALUE column is: VARCHAR2 Answer When you convert your string to a …
How to round an average to 2 decimal places in PostgreSQL?
I am using PostgreSQL via the Ruby gem ‘sequel’. I’m trying to round to two decimal places. Here’s my code: SELECT ROUND(AVG(some_column),2) FROM table I get the following error: PG::Error: …
ERROR 1452 (23000): cannot add or update a child row. [closed]
It’s difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 9 years ago. what could be the pr…
SQL query to extract all WordPress posts with categories
I need to extract all posts from my WordPress DB along with the associated categories and not sure how to write this query. I’ve taken a couple of stabs at it already with no joy and would appreciate …