Sign up or Sign in | Share
 
ClearMyBench
Welcome, Guest
Please Login or Register.    Lost Password?
Re:Ruby basics (1 viewing) (1) Guest
Go to bottom Post Reply Favoured: 0
TOPIC: Re:Ruby basics
#4619
ShriNi (User)
Software Techie (PEGA) currently on a Career Break
Platinum Boarder
Posts: 4000
graph
User Offline Click here to see the profile of this user
Gender: Female Location: Secundrabad India Birthdate: 1983-09-29
Re:Ruby basics 3 Years, 10 Months ago Karma: 0  
All of these methods perform a search-and-replace operation using a Regexp pattern.

The sub & sub! replace the first occurrence of the pattern and gsub & gsub! replace all occurrences
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#4620
ShriNi (User)
Software Techie (PEGA) currently on a Career Break
Platinum Boarder
Posts: 4000
graph
User Offline Click here to see the profile of this user
Gender: Female Location: Secundrabad India Birthdate: 1983-09-29
Re:Ruby basics 3 Years, 10 Months ago Karma: 0  
The sub and gsub return a new string, leaving the original unmodified where as sub! and gsub! modify the string on which they are called.
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#4621
ShriNi (User)
Software Techie (PEGA) currently on a Career Break
Platinum Boarder
Posts: 4000
graph
User Offline Click here to see the profile of this user
Gender: Female Location: Secundrabad India Birthdate: 1983-09-29
Re:Ruby basics 3 Years, 10 Months ago Karma: 0  
The Ruby DBI module provides a database-independent interface for Ruby scripts similar to that of the Perl DBI module.
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#4622
ShriNi (User)
Software Techie (PEGA) currently on a Career Break
Platinum Boarder
Posts: 4000
graph
User Offline Click here to see the profile of this user
Gender: Female Location: Secundrabad India Birthdate: 1983-09-29
Re:Ruby basics 3 Years, 10 Months ago Karma: 0  
DBI stands for Database independent interface for Ruby

This means DBI provides an abstraction layer between the Ruby code and the underlying database, allowing you to switch database implementations really easily
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#4623
ShriNi (User)
Software Techie (PEGA) currently on a Career Break
Platinum Boarder
Posts: 4000
graph
User Offline Click here to see the profile of this user
Gender: Female Location: Secundrabad India Birthdate: 1983-09-29
Re:Ruby basics 3 Years, 10 Months ago Karma: 0  
DBI defines a set of methods, variables, and conventions that provide a consistent database interface, independent of the actual database being used.
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
Go to top Post Reply
get the latest posts directly to your desktop
logo footer   Copyright 2009 - 2013 HotRecruiter.Com - All Rights Reserved