472,789 Members | 1,309 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,789 software developers and data experts.

Spaces and comments in pgplsql

Hello,
I have a question about pgplsql:

Is it faster to execute a compact function (with minimal spaces and comments)
than a function with many comments and many spaces?

In others words, which one will be faster? AAAAA_function or BBBBB_function ?

CREATE FUNCTION AAAAA_function RETURNS INTEGER AS '
DECLARE
a_var INTEGER;
BEGIN
SELECT SUM(field) INTO a_var FROM a_table;
RETURN a_var;
END;
' LANGUAGE 'plpgsql';

CREATE FUNCTION BBBBB_function RETURNS INTEGER AS '
DECLARE

--
-- Bla bla bla
--
a_var INTEGER; -- Lot of spaces...

BEGIN

--
-- Rebla bla bla
--

SELECT SUM( field ) INTO a_var FROM a_table ; -- Selecting...

-- ...

RETURN a_var ;

END;
' LANGUAGE 'plpgsql';
Thank you very much

Luc

Jul 19 '05 #1
0 1960

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

17
by: bearophileHUGS | last post by:
Hello, I know this topic was discussed a *lot* in the past, sorry if it bores you... >From the Daily Python-URL I've seen this interesting Floating Point Benchmark:...
5
by: Christian Traber | last post by:
Hi, I'll try to switch from Oracle to postgres for some small applications. Is it possible to build functions like Oracle's nvl or decode with pgplsql? How can I make a function like nvl that...
2
by: Kuti Attila | last post by:
Hi, I have a pgplsql function. It is quite short and simple. The problem:
1
by: Howard | last post by:
is there a quick option in asp.net or visual studio 2005 to strip out all unessesary spaces in the html output? and html comments? I want to save bandwidth, readability is not an issue
135
by: Xah Lee | last post by:
Tabs versus Spaces in Source Code Xah Lee, 2006-05-13 In coding a computer program, there's often the choices of tabs or spaces for code indentation. There is a large amount of confusion about...
5
by: howa | last post by:
will performance increae if I removed comments & space from source code using php -w ...? given that i don't need to modify the source code, & don't use any cache?
0
by: MLH | last post by:
In an earlier post today, it was mentioned that dbl-spaces caused alignment-justification problems when printing labels. I've never noticed this in reports except for those meant for the...
0
by: Didje | last post by:
Hi, I'm trying to design a kind of calculator GUI using gridbaglayout. At the top of the calculator will be a couple of menus and then will come the section with all the buttons etc. Initially, I...
2
by: watusiboy | last post by:
<TEXTAREA NAME="comments" ROWS="10" COLS="50"> <?php echo $comments; ?> </TEXTAREA> this is a very simple question. the textarea above automatically adds three tab spaces at the beginning. as...
0
by: Rina0 | last post by:
Cybersecurity engineering is a specialized field that focuses on the design, development, and implementation of systems, processes, and technologies that protect against cyber threats and...
0
by: erikbower65 | last post by:
Using CodiumAI's pr-agent is simple and powerful. Follow these steps: 1. Install CodiumAI CLI: Ensure Node.js is installed, then run 'npm install -g codiumai' in the terminal. 2. Connect to...
0
linyimin
by: linyimin | last post by:
Spring Startup Analyzer generates an interactive Spring application startup report that lets you understand what contributes to the application startup time and helps to optimize it. Support for...
0
by: erikbower65 | last post by:
Here's a concise step-by-step guide for manually installing IntelliJ IDEA: 1. Download: Visit the official JetBrains website and download the IntelliJ IDEA Community or Ultimate edition based on...
0
by: kcodez | last post by:
As a H5 game development enthusiast, I recently wrote a very interesting little game - Toy Claw ((http://claw.kjeek.com/))。Here I will summarize and share the development experience here, and hope it...
0
by: Rina0 | last post by:
I am looking for a Python code to find the longest common subsequence of two strings. I found this blog post that describes the length of longest common subsequence problem and provides a solution in...
5
by: DJRhino | last post by:
Private Sub CboDrawingID_BeforeUpdate(Cancel As Integer) If = 310029923 Or 310030138 Or 310030152 Or 310030346 Or 310030348 Or _ 310030356 Or 310030359 Or 310030362 Or...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
0
by: lllomh | last post by:
How does React native implement an English player?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.