| 
		
			| How to populate a form blcok through cursor [message #142244] | Thu, 13 October 2005 23:04  |  
			| 
				
				
					| d.dineshkumar Messages: 211
 Registered: April 2005
 Location: Kolkatta
 | Senior Member |  |  |  
	| Hi all, how can i populate a form multi record block from a cursor.
 
 For example , suppose i have a cursor fetching all the records from emp for deptno 10 , and i have a multirecord block for emp.
 Now how can i populate record in my block on the click of a button.
 
 
 Hope i am clear.
 Thanks And Regds
 Dinesh
 
 |  
	|  |  | 
	|  | 
	|  | 
	| 
		
			| Re: How to populate a form blcok through cursor [message #142549 is a reply to message #142320] | Sat, 15 October 2005 10:26   |  
			| 
				
				
					| d.dineshkumar Messages: 211
 Registered: April 2005
 Location: Kolkatta
 | Senior Member |  |  |  
	| Hi all, What is the error in the following code:
 
 If(:DUMMY_BLOCK.D_SYSTEM_NAME='HR' Then
 GO_BLOCK('BLOCK01');
 set_block_property('BLOCK01',QUERY_DATA_SOURCE_NAME,'SELECT * FROM MST_HR@HR');						V_QRY_DATA_SRC_NM:=GET_BLOCK_PROPERTY('BLOCK01',QUERY_DATA_SOURCE_NAME);
 MESSAGE(V_QRY_DATA_SRC_NM);
 set_block_property('block01',default_where,'system_name = '''||:d_system_name ||''''||
 ' and condition = ''' || :d_condition ||'''');
 clear_block(no_validate);
 do_key('execute_query');
 Else
 ....
 End If;
 here my requirement is on the basis of d_system_name.
 How can i change my data source to mst_hr@hr at runtime.
 
 Hr is a dblink.
 The above statemet is returning Ora-40405 -unable to perform query.
 
 How to solve this.
 Thanks And Regards
 Dinesh
 [Updated on: Sat, 15 October 2005 10:27] Report message to a moderator |  
	|  |  | 
	|  | 
	|  |