Actually it's not a long jump competition but this is the easiest way to visualize it. I've been playing in the SQL sandpit for too long on this one and frankly I'm stumped! Decided to take a leap and post the query here.
Athletes take several jumps, each recording a distance; hence a row in the table consist of athlete and distance, (number of attempts is irrelevant.)
I need a select statement that will return the top jumpers.
I have SELECT statement that is several thousands of characters long - i'm declaring many tables, columns, and I have many aliases to deal with as well. Is there any way I can break it up into multiple lines? The only two things I could think of were using " + " . . . " + " . . . " or simply doing nothing and just dividing it into separate the lines. By the way, is there a limit to how long a SQL statement can be. I have been finding different answers when searching online.
I am stuck on this and its happening no matter what I do. I have a huge project that holds tons of reports. Most are sub-reports.
I have 5 sections I will just use one for example
communictions (totals)
jump to report - summary data
Jump to report - detail data.
The when I get to the detail data I always get the error:
The path of the item '(null)' is not valid. The full path must be less than 260 characters long; other restrictions apply. If the report server is in native mode, the path must start with slash. (rsInvalidItemPath)
I have tried to do all sorts of things and no matter what I do I cant get it to work.
This is a web application using the ReportViewer for the web, SQL Server 2005 SP2
I have searched high and low for an answer to this and nothing works, not even the get instead of the post.
Let's assume the client code call a stored procedure which reads: SELECT * FROM myTable WHERE ID < 100. Let's assume that for whatever reason, the query becomes very slow and takes 60 seconds to complete. This 60 secs, could be the time for the DB engine to fetch all the rows (happening before returning the resultset to client code), or during the transfer of the resultset to client code (slow network throughput). Question1: could this prevent another user from doing SELECT on myTable? (could be onn different ID or even overlapping the ID between 1 and 100). Question2: could this prevent another user from performing write (UPDATE/DELETE) on the rows with ID between 1 and 100? Question3: can another user perform a write (INS, DEL, UPD) on rows outside of the ID between 1 and 100?
Hello.. The first problem: I have 2 tables in MS SQL database: topicstbl and txtfilestbl. And every one have column topicID. And in both I have fulltext column I want to search in it; but in the first one I want to search in the fulltext column (topicflds) and also in normal columns (topicname and topicsn) I need to search in these tables and get the (topicID) column as result by 1 table without repeated results. I tried this code: SELECT topicID, KEY_TBL.RANK FROM (SELECT topicID, 255 as RANK FROM topicstbl WHERE topicname like '%search word%' or topicsn like '%search word%') AS KEY_TBL UNION SELECT topicID, KEY_TBL.RANK FROM topicstbl AS topicstbl INNER JOIN CONTAINSTABLE(topicstbl, topicflds, 'search NEAR word') AS KEY_TBL ON topicstbl.topicID = KEY_TBL.[KEY] UNION SELECT topicID, KEY_TBL.RANK FROM txtfilestbl AS txtfilestbl INNER JOIN CONTAINSTABLE(txtfilestbl, txtfile, 'search NEAR word') AS KEY_TBL ON txtfilestbl.txtfileID = KEY_TBL.[KEY] ORDER BY KEY_TBL.RANK DESC
But the problem is the result table has repeated records (same topicID, different Rank Value). Also I used "SELECT DISTINCT" but same problem. The second problem: I want to merge the previous code with ROW_NUMBER code to get results between x and y. Like this code: WITH OrderedOrders AS (SELECT *, ROW_NUMBER() OVER (order by topicID DESC) as RowNumber FROM topicstbl)
SELECT * FROM OrderedOrders WHERE RowNumber between 1 and 50 But without change the first order.
I have a report that uses report parameters and navigation in the textbox. When I click in the textbox, it jumps to the same report, but I cannot see the report parameters any more(hidden ). I cannot change the report parameters. When I use only the report paramenters (no navigation option), they appear always during the run time. How can I do to keep the report parameters visible all the time using "jump to the same report"??
I have a table tblCustTrans which contains custid int transid int startdate datetime value int
the custid, transid and startid are composite primary key.
the table contains more than 10 million records. Now i want to fetch record for select * from tblcusttrans where startdate > = 10/10/2006 10:00:000 and startdate <= 10/10/2006 11:00:000
This statement is taking more than 2 hours to fetch the data. is there a way to fetch the record with less time
Hi All,I am facing problem in MS SQL Server 2000. It is behaving slow forselect statements. It is even slower than MS ACCESS. For example, if iuse"Select count(*) from tbl;". i get the results after long time ifthere is more than 100k rows. What might be the possible reasons forthis??ThanksHoque
Yesterday, we have had a sudden load in our SQL Server 2000 which resulted in several locks. There was not too much time to investigate as we had to rush. A team member had reviewed the processes in EM, Manegement, Current Activity. Looking for blocking processes and killed them.
She told me that as soon as the blocking SPID was killed, another one arose and she had to repeat the operation a dozen of time. When done, the server activity was back to normal. She noticed that more than half of the blocking processes showed that they executed the stored Proc "P_SearchProducts".
We don't own the server and the information on what had happened at that time (batches or resource intensive operations, etc.) is not available for now.
The team suggests that we set the Transaction Isolation Level to Read UNCOMMITTED for this SP. I would like to know better about locks before I go ahead.
P_SearchProducts returns 5 recordsets each one could contains from 1 to 200 rows. To achieve the results, it creates about 10 intermediate tables (SELECT ... INTO #TableX) these temp tables are then used progressively to arrive to the final results. Roughly the volume of these temp tables could be double than the final results. The developer who wrote this SP is not a guru in SQL, there is room for improvement. But here are my questions:
Q1. Could the series SELECT ... INTO #TableX in P_SearchProducts prevent or lock another connection from executing the same SP? If yes, under which conditions?
Q2. Let's assume that P_SearchProducts has a slow execution time. Could it prevent another connection from updating the Product table? And thus leading to a deadlock situation? Something like another transaction (by User2) has obtained lock on most of Product tables, except the Product table which were being slowly read by User1 executing P_SearchProducts. But User1 cannot read the other product tables b/c there are locks by User2.
Q3. If the contention issue was provoked by the slow execution time of many request to exec P_SearchProducts (let's assume there were suddenly 50 users on the web hitting the search product feature at the same time). Could the Read Uncommitted magically resolve the contention issue, providing we accept the consequences of the dirty read.
Sorry for the long post and thank you in advance for any help.
I use the "jump to url" in a report that links out to a page on our company intranet. Our internal users have to use http and an external user needs to be routed to the site w/ https. How can I account for this in a report?
I want to add two link(navigation) buttons in SINGLE CELL ... if i click on 1st it should navigate to xyz page and if i click on second then it should navigate to abc page...can u pls help me...
Hi, I am trying to link to a page outside of reporting services from a report. I am using SQL Server 2005 Reporting Services [Standard Edition]. The hyperlink works if it is a straight URL, however, nothing happens if I modify it to use Javascript so I can open the link in a new window. I have found many posts on the web from others indicating it should be really easy, but I can not get the link to recognize ANY Javascript (also tried a basic alert with no luck).
The Javascript I am using is well formatted. I can place it into a test page and it runs fine. I can also RC and View Source on my report, grab the entire link, put it in a test page and it works fine. It just doesn't work from the report - ?
The Hyperlink expression for the textbox €˜textbox24€™ refers to the field €˜Unit€™. Report item expressions can only refer to fields within the current data set scope or, if inside an aggregate, the specified data set scope.
I have created a hyperlink(textbox) with an action property setting of "Jump to report" The report I am jumping to takes 5 parameters. I want to pass 4 of the parameters from the main report and have the user enter the 5th. I have mapped the 4 parameters and in preview mode, everthing works great. In preview mode, the parametrs are passed and the last parameter is left waiting for entry. After deployment, this is not the case. In the deployed state, I simply get an error that parameter #5 is blank. Is there there something I am missing?
Can I have a report that is nothing more than a parameter and when the user selects from the list it will jump to another report based on which parameter was selected?
I can create a report with a text box that I can click to jump. I'd like to be able to eliminate the click on text box if possible and jump directly from parameter select pull down box.
Please tell me how to implement the "Jump to Bookmark" in reports, I mean to say, i have to move to another area or page in a report. Please provide a sample for the same.
I have a report that uses Jump to Report and passes Reportname with parameter. Is there a way to suppress the parameter value in the URL so the user is unable to manipulate the parameter and execute the changed URL?
I have a report (Report1) with a subreport (SubReport2). The subreport is a barchart. On the data values for the chart, I have a "Jump to Report" action defined. This jumps to another report(Report3) that has some parameters on it. Neither Report 1 nor SubReport2 have any parameters, only Report3.
When I jump to Report3, I would like to have it open up blank with the parameters open to be selected. I don't want to pass in any parameters as I jump to it. This works perfectly when I test it in my Preview pane in BIDS. However, when I upload the report to the ReportServer, when I click on SubReport2 to jump to Report3, I get an error saying
The 'Months' parameter is missing a value
There is no parameter pane for me to choose the parameters (or any other report viewer pane). However, if I open Report3 directly without trying to use Report1 and SubReport2 to jump to it, the parameter pane is there, everything works right.
Does anyone know how I can get the parameters pane to show up when I jump to Report3?
Here is my problem. I have a SSRS report that uses a SSAS cube for as it's datasource. I have a drop down parameter box where the user can select a year (2005,2006,2007,etc..) They click the View Report button and the report is generated. On one of the textboxes properties, on the navigation tab I have Jump to Report activated. I select the parameter from the receiving reports with the value of the dropdown box.
What I'm trying to do and can't, is to jump to that report passing the contents of the dropdown box. The receiving report is a SSRS report with a datasource being the SSAS. How do I make the receiving report open based on the parameter that was sent ??
When I put this link in TextBox properties >> Navigation >> Jump URL of my gridView : http://www.micheldegremont.com it works.
However, if I put "http://www.micheldegremont.com?id=" + Fields!ID.Value it doesn't work. I haven't not link in my report.
And if I put http://www.micheldegremont.com?id=Fields!ID.Value my report create a hyperlink to http://www.micheldegremont.com?id=Fields!ID.Value and no http://www.micheldegremont.com?id=1
I have a simple report which just lists product details and summary. So somthing like this:
Product Id | Hits | Sales
I want to add a action (Jump To URL) to the Product ID field, which then redirects it to its product page on a website, however, how do I pass the ID field within the url?
for example, typical product page on the website is
In Opening a display of invoices in Report Server I have a ULR link in the Jump to URL section under the navigation tab.
I have the URL with the invoice number in the expression. Is there something I can add to this expression that will force the interface to Open a new windows page instead of the existing window?