Ligthweight SQL editor for Eclipse (Helios)
Is there any simple SQL editor plugin for Eclipse? By simple I mean, the editor does NOT connect to any DB, does syntax highlighting and preferably formatting sql is a bonus. ...
Is there any simple SQL editor plugin for Eclipse? By simple I mean, the editor does NOT connect to any DB, does syntax highlighting and preferably formatting sql is a bonus. ...
Given this SQL: DECLARE @content XML SET @content = '<people> <person id="1" bimble="1"> <firstname bobble="gomble">John</firstname> <surname>Doe</surname> </person> <person id="2" bimble="11"> <firstname bobble="zoom">Mary</firstname> <surname>Jane</surname> </person> <person id="4" bimble="10"> <firstname...
I am trying to extract a maximum of 5 entries randomly from two tables combined directly from database. kinda like this SELECT RANDOM FROM table1,table2 LIMIT 0,5) I am aware that I can filter the result later on from PHP, but I want only 5 random rows from database. These multiple tables might have different database structure ...
Hi, I would like some guidance on what is the best approach for storing the Report SQL definitions for SSRS 2008 reports. [Our web app will interface with the SSRS web service and display the reports in the VS ReportViewer control] Currently I see 3 options Store the SQL within the RDL [Report Definition] files. Store the SQL in Sto...
Hello, I have written some code that provides statistical information about visitors to a website (like "Google Analytics") I have a REFERER table with refererID, refererURL columns. The refererURL contains the whole url, including the parameters. other tables, such as the statistics table, refer to this table by the refererID column....
OleDbCommand cmdpic = new OleDbCommand ("select * from sub_category where id_s=" + Request.QueryString["id_s"] +"or"+"order by sub_id desc", concars); it shows error what is the correct command ...
Is there a TSQL script that will allow me to see the contents of a constraint. I found a question regarding Oracle but I need a TSQL script. http://stackoverflow.com/questions/2686353/how-to-see-contents-of-check-constraint-on-oracle I am aware of sys.check_constraints, however, the 'definition' comes back null for all objects. Selec...
This one seems so simple, but I must be missing something... Given this SQL: declare @xml XML set @xml = '<people> <person> <name>Matt</name> <surname>Smith</surname> <person> <person> <name>John</name> <surname>Doe</surname> <person> </people>' How would you go about getting a table containing: people ------...
Hi, I am trying to return the MATCH() AGAINST() results against several tables using UNIONS, the only problem is some rows return a relevance of 0, I want to exclude these. After the unions is there a way to use 'WHERE relevance > 0' Below is a bit of my SQL SELECT pages.content AS search, page_info.url AS link, MATCH(pages.content) AG...
We have a "large" code base already developed using SQLite and NHibernate using .NET 2 for our clients. Using SQLite we can communicate with the db (even multiple clients) across a Windows file share. Most of the time, this is perfectly sufficient for what we need to do. Over the last few months, we have needed to integrate our applic...
I've got an SQL-table with some million entries and I tried to query how much entries are older than 60 days (Oracle 11.2.0.1.0). For this experiment I used 3 different versions of the select-statement: (The cost-value is given by TOAD for Oracle V. 9.7.2.5) select count(*) from fman_file where dateadded >= (select sysdate - 60 from d...
I'm building a commenting mechanism into an application that allows a programmer/plugin author to implement comment threads in a simple manner. The way I wanted to do this is by using a unique identifier for the comment threads, which took the hard work away from the developer by using a unique key for the thread, where you can place co...
All, I'm probably over-analyzing this problem, but... Given table "A" with two one-to-many relationships "A1" and "A2", return all records in table "A" that have at least one child record in either table "A1" or "A2"... I'm not necessarily interested in knowing what the child data is, but rather that I just have child data. Thanks! ...
MY table looks like this id | string | foreign_id --------------------------- 1 | house | 5 2 | garden | 6 3 | window | 5 ... I have an array of strings and i want to get all foreign ids which match all elements in the array. So i have an array like this [house, window] then i want to get 5. The array of strings can have up to 10 ...
I've got access levels and pages. Pages <=many-to-many=> Levels I need to count how many opened pages does each level has. But the levels doesn't happen to come out if pageCount is 0. SELECT levels.id, levels.name, COUNT(pages.id) as pageCount FROM levels LEFT JOIN page_levels ON levels.id = page_levels.level_id LEFT JO...
I need a simple code to upload images to mySQL using PHP... short! snippet... and is it possible to upload an html, css file to mySQL?... its reason is complicated but all answers are appreciated!... EDIT:: say I have 1000 users.. and they each have their own layout for their page.. So inside their MYSQL record will be a html file, css f...
I was just introduced to the concept of Outlook forms. I don't know if this will solve my problem but here is what I want to do: I want to be able to have employees who are inside the company fill out some forms. So all I have to do is create the form and PUSH it to their Outlook? After they fill out the form, can I capture the data som...
I have three tables, 'A', 'B' and 'C'. I have query on 'A' and 'B', but I want to add a field that tells me whether or not there is one or more (I dont' care how many) 'C' that are foreign keyed to 'A'. Here's what I have: SELECT A.A_id, A.col_2, col_3, B.col_2, A.col_4 count(C.id) as C_count FROM A JOIN B ON (A...
I have a simple query and am wondering if it could be more elegantly coded. The final solution has to be ansi-compliant. I need to fetch the latest value from a table based on date and version. A sample would explain more clearly: declare @t table (id int, due_date smalldatetime, version int, value nvarchar(10)) insert into @t select ...
here's my condition: ([Panels] like '*something*' or [Panels] like '*something1*') AND ([Panels] like '*something2*' or [Panels] like '*something3*') another words, here is the logic: [Panels] has to be one of the following (IT_AMPH | AMPH_SN | AMPH_S) AND it has to be one of the following: (IT_BARB | BARB_SN | BARB_S) ...