|
-- Function: aspnet_session_setandrelease()
CREATE OR REPLACE FUNCTION aspnet_session_setandrelease(
IN iNewItem boolean,
IN iSessionId aspnet_session.sessionid%TYPE,
IN iAppId aspnet_session.appid%TYPE,
IN iLockId aspnet_session.lockid%TYPE,
IN iTimeout aspnet_session.timeout%TYPE,
IN iSessionItems aspnet_session.sessionitems%TYPE
)
RETURNS VOID
AS
$BODY$
DECLARE
pOneMinute interval = '1 minute';
BEGIN
IF iNewItem = true THEN
BEGIN
DELETE FROM aspnet_session WHERE SessionId = iSessionId
AND AppId = iAppId AND Expires < CURRENT_TIMESTAMP;
INSERT INTO aspnet_session
(SessionId, AppId, Created,
Expires,
LockDate, LockId, Timeout, Locked, SessionItems, Flags)
Values (iSessionId, iAppId, CURRENT_TIMESTAMP
, CURRENT_TIMESTAMP + iTimeout * pOneMinute
, CURRENT_TIMESTAMP, 0, iTimeout, false, iSessionItems, 0);
END;
ELSE
BEGIN
UPDATE aspnet_session SET Expires = CURRENT_TIMESTAMP + iTimeout * pOneMinute
, SessionItems = iSessionItems, Locked = false
WHERE SessionId = iSessionId
AND AppId = iAppId AND LockId = iLockId;
END;
END IF;
END;
$BODY$
LANGUAGE 'plpgsql' VOLATILE;
ALTER FUNCTION aspnet_session_setandrelease(
IN iNewItem boolean,
IN iSessionId aspnet_session.sessionid%TYPE,
IN iAppId aspnet_session.appid%TYPE,
IN iLockId aspnet_session.lockid%TYPE,
IN iTimeout aspnet_session.timeout%TYPE,
IN iSessionItems aspnet_session.sessionitems%TYPE
)
OWNER TO testsession;
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
A biography in this little spot...sure.
I've worked at GTE HawaiianTel. I've worked at Nuclear Plants. I've worked at Abbott Labs. I've consulted to Ameritech Cellular. I've consulted to Zurich North America. I've consulted to International Truck and Engine. Right now, I've consulted to Wachovia Securities to help with various projects. I've been to SHCDirect and now at Cision.
During this time, I've used all kinds of tools of the trade. Keeping it to the more familier tools, I've used VB3 to VB.NET, ASP to ASP/JAVASCRIPT/XML to ASP.NET. Currently, I'm developing with C# and ASP.NET. I built reports in Access, Excel, Crystal Reports, and Business Objects (including the Universes and ETLS). Been a DBA on SQL Server 4.2 to 2000 and a DBA for Oracle. I've built OLTP databases and DataMarts. Heck, I've even done Documentum. I've been lucky to have created software for the single user to thousands of concurrent users.
I consider myself fortunate to have met many different people and worked in many environments. It's through these experiences I've learned the most.