Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
oracle Lead function is not working in the Edit Script section. I am using Qlikview 9.00 SRS 6.0 version. Please suggest any body has tried this.
 
					
				
		
Hi Ralf
I am getting the error as Right parenthesis missing.but there is some other error.
 rbecher
		
			rbecher
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Maybe it's the line break? I see no paranthesis is missing.
- Ralf
 rbecher
		
			rbecher
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		I don't have your table and data but I wonder if the column MDATE in the Where Clause should be SDATE?
- Ralf
 rbecher
		
			rbecher
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Ok, you could do this in QlikView in the following way:
1. SELECT the data without the LEAD function but with DESCENDING ordering: ORDER BY SDATE DESC
2.Use the QV function previous( ) on the LOAD statement:
TableA:
LOAD *, previous(SDATETIME) as Newdate;
SQL SELECT .... FROM TABLEA ORDER BY SDATE DESC;
- Ralf
 
					
				
		
Thanks for Support Ralf.
It is MDATE only in the where condition. Hard thing is I will not be able to share the data. But just want to know is there any similar function available in Qlikview.
 
					
				
		
Hi Ralf,
The same Query is working fine if i am executing in SQL plus. Any Suggestions or Alternative approach for this???
 
					
				
		
Hope QlikTech Support team can provide the support for this.
 rbecher
		
			rbecher
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		As I wrote before an alternative could be this:
1. SELECT the data without the LEAD function but with DESCENDING ordering: ORDER BY SDATE DESC
2.Use the QV function previous( ) on the LOAD statement:
TableA:
LOAD *, previous(SDATETIME) as Newdate;
SQL SELECT .... FROM TABLEA ORDER BY SDATE DESC;
- Ralf
 rbecher
		
			rbecher
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Are you using ODBC or OLE?
Which OS version and which Oracle version you have?
- Ralf
 
					
				
		
Hi ,
I am using OLEDB Connection and the OS version is Windows 2003. Oracle 10g.
