IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

L1 and L4 command


IBM Mainframe Forums -> Java & MQSeries
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
monasu1998

Active User


Joined: 23 Dec 2005
Posts: 176
Location: India

PostPosted: Mon Jul 27, 2009 8:48 am
Reply with quote

Hi,

The L1 command reads a single record from Data Storage.
The L4 command is the same as the L1 command except that the record is placed in hold status.

My confusion is that, how can we know about

We do not write anything to put the record on hold. But internally how Adabas decides which record has to be put on hod?

Based on what, I can decide that my statement refers to L1 or L4 command?

similarly how can I decide about S1 and S4 command???

Thanks,
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2358
Location: Israel

PostPosted: Tue Jul 28, 2009 11:57 am
Reply with quote

It is up to you to decide if you want to hold the record while reading it.This is why ADABAS give you the flexibility of using L1 or L4. There are other methods of putting a record in HOLD within ADABAS, but L4 is the fastest.

O.
Back to top
View user's profile Send private message
monasu1998

Active User


Joined: 23 Dec 2005
Posts: 176
Location: India

PostPosted: Tue Jul 28, 2009 10:05 pm
Reply with quote

Thank you Ofer for your response. But I still wonder on How to put the record on HOLD while accessing adabas.
Can you please give a small example?

Thanks in Advance
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2358
Location: Israel

PostPosted: Tue Jul 28, 2009 10:50 pm
Reply with quote

Simply use L4. ADABAS will do the job for you.

O.
Back to top
View user's profile Send private message
monasu1998

Active User


Joined: 23 Dec 2005
Posts: 176
Location: India

PostPosted: Tue Sep 01, 2009 11:14 pm
Reply with quote

Hello Ofer7,

I m still in confusion about the L4 command.

In general we use the READ command to read the adabas file.

How can I determine if my READ command is L1 or L4?

Is there something like I have to use any other command with READ to make it L4?

Thanks in Advance.
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2358
Location: Israel

PostPosted: Wed Sep 02, 2009 1:21 am
Reply with quote

L1 & L4 are direct ADABAS command. Natural interprets each of your data access statements to one ADABAS direct command or more.

Natural is smart enough to take care of your HOLD logic without you knowing about it. For example, if an UPDATE statement is coded within a READ loop, the record might be read with HOLD status.

To read more, please refer to the fine manual (Programming Guide --> Database Access --> Record Hold Logic).

O.
Back to top
View user's profile Send private message
monasu1998

Active User


Joined: 23 Dec 2005
Posts: 176
Location: India

PostPosted: Wed Sep 02, 2009 7:46 am
Reply with quote

Thank you Ofer. I am clear now.... :-)
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> Java & MQSeries

 


Similar Topics
Topic Forum Replies
No new posts RACF - Rebuild SETROPTS command which... All Other Mainframe Topics 3
No new posts Routing command Address SDSF to other... TSO/ISPF 2
No new posts DTL - how to define key with stacked ... TSO/ISPF 3
No new posts LTJ command CA Products 4
No new posts Query on edit primary command CLIST & REXX 5
Search our Forums:

Back to Top