|
I want to add select query result into dataset, so i can write new query to run on it to get net dataset but how?
Original query:
MyDATASET=( select x, y,z from table1 union all select k,l,m from table2 ) i wan to this select * from this.MyDATASET
Answer Snippets (Read the full thread at stackoverflow):
CREATE VIEW MyView AS select x, y,z from table1 union all select k,l,m from table2 GO SELECT * FROM MyView SELECT * FROM MyView WHERE x = 0
etc
... .
Well, you could perhaps create a CTE, UDF or view? But it really isn't clear what you are trying to do.. .
|
|
A query that is used to loop through 17 millions records to remove duplicates has been running now for about 16 hours and I wanted to know if the query is stopped right now if it will finalize the delete statements or if it has been deleting while running...
Started by RyanKeeter on
, 11 posts
by 11 people.
Answer Snippets (Read the full thread at stackoverflow):
I specifically tested this myself on my own SQL Server using the following query, and the ApplicationLog table was empty....
Otherwise what would the point of transactions be?
Your query delete statements.
I'm pretty sure that is a negatory.
|
|
At first I was thinking I was running into an issue with cfqueryparam and mysql. However when I change substitute them with static values I get the same error. This is stumping me, I'm too used to Microsoft SQL Server I guess. Any help would be greatly...
Started by mc on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
CFGears is right, you....
MySQL denies this by defualt, so each of your update and insert statements have to be in their own cfquery tags .
Unless you've explicitly allowed it on your MySQL server, you can't have multiple sql statements in the same cfquery .
|
Ask your Facebook Friends
|
I have a 800MB MS Access database that I migrated to SQLite. The structure of the database is as follows (the SQLite database, after migration, is around 330MB):
The table Occurrence has 1,600,000 records. The table looks like:
CREATE TABLE Occurrence...
Started by Saswati De on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
Each of the 18 times the....
Hope this is more clear and legible and in order to understand the context of the above query I thought it necessary to give a brief as the ‘Simulation’.
I have presented a smaller scaled down version of my query.
|
|
I have a problem similar to the on in this weeks podcast.
We have a Java application using hibernate with Sql Server 2005.
Hibernate is generating a Query for us that is taking nearly 20 minutes to complete.
If we take the same query using show_sql and...
Started by Ged Byrne on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
Problem with complex queries in Hibernate is not the query itself, but rather the creation of all, SQL Server is creating a query plan based on an older set of parameter values that were passed in and which do not create an effective....
|
|
Is there a straightforward way to run mysql_query with an insert and get the ID of the new row, for example in the return? Or will I have to do another query with select to check it?
Started by fmsf on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Try mysql_insert.
Simply call mysql_insert_id after running mysql_query and you will get the ID.
|
|
How can you find out what are the long running queries are on Informix database server? I have a query that is using up the CPU and want to find out what the query is.
Started by grom on
, 6 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
Sysmast/sysmast.htm If the query is currently running watch the onstat -g act -r 1 output and look.
|
|
I'm trying to run the following SQL statement in Oracle, and it takes ages to run:
SELECT orderID FROM tasks WHERE orderID NOT IN (SELECT DISTINCT orderID FROM tasks WHERE engineer1 IS NOT NULL AND engineer2 IS NOT NULL)
If I run just the sub-part that...
Started by RickL on
, 21 posts
by 18 people.
Answer Snippets (Read the full thread at stackoverflow):
If you re-write your ....
There are many factors that determine how the database resolves the query.
I could set this query up in one Oracle database and make it run slow and make it run fast in another.
Is not very helpful.
|
|
Hi
i have dataset that contain data.
i need to run any query on this DataSet.
thank's in advance
Started by Gold on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
If the query criteria and primary key are the same, then DataTable.Rows.Find will work much faster.
|
|
I have a query which joins 6 tables, produces 800,000 rows, and inserts them into a table.
I'm running this query on Sql 2005 Standard on an 8-core machine, on which there is no other workload running. The Sql service uses only one CPU core while running...
Started by treaschf on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Try forcing another transaction isolation level (SET TRANSACTION....
You could also post the query and its plan (in text mode) here for others to analyze.
Have a look at the query plan, probably it will give you some insight on what's happening.
|