procedure

Why TObject.Free is called before the first line of code of my application is executed?

折月煮酒 提交于 2019-12-11 06:27:52
问题 We are trying to figure out if we have memory leaks in our software. So, I have been using various tools and programs to help me find possible memory leaks. One of the software I used was AQTime. As it came with Delphi XE, it was only a demo. So, I was not really able to get any useful information from it. Then, I decided to use free software, MemProof. So far, it has shown me many issues with our software that requires attention. One of which is an error. As soon as I start my program

Python List Bracket Removal

拈花ヽ惹草 提交于 2019-12-11 06:24:14
问题 So I am trying to add a list of ticker symbols from a CSV file into a python list. The CSV File looks like this: AAPL XOM EMC When working with the stockList[]. How do I remove the [' '] brackets and quote marks? My code is below: stockList = [] csvReader = csv.reader(open('tickers.csv','rb'), quoting=csv.QUOTE_NONE) for row in csvReader: stockList.append(row) for item in stockList: print repr(item) For example when the code above is ran it outputs: ['AAPL'] ['XOM'] ['EMC'] 回答1: It looks like

How to create an Oracle stored procedure to lock user accounts not logged onto database for more than 90 days

匆匆过客 提交于 2019-12-11 06:07:56
问题 How do I create an Oracle Stored Procedure to lock user accounts that's not logged onto the database for more than 90 days? I assumed that I could create a Profile Object and list the Resource Parameters in my database but I am using Oracle 11g and it appears that feature doesn't exist. This is what I tried so far: select username from dba_audit_trail where action_name = 'LOGON' group by username having max(timestamp) < sysdate - 90 I also attempted to create a profile attempting to use

VBA Excel Procedure Too Large

谁都会走 提交于 2019-12-11 06:03:24
问题 I trying to create a tool using VBA excel. I'm am an amateur at this and need some help. I have a dedicated button/macro that uses a mess load of codes if/then statements. I need this one button to do what I want it to do, this is what I have. I'm getting the Procedure Too Large error, please help Private Sub Save_Click() Dim ws As Worksheet Set ws = Worksheets("Sales Tracker") Dim newRow As Long newRow = Application.WorksheetFunction.CountA(ws.Range("A:A")) + 1 ws.Cells(newRow, 1).Value = Me

Call mysql PROCEDURE inside while loop works only first time

拟墨画扇 提交于 2019-12-11 04:58:43
问题 I have some data from the DB I post on a table. For every line of the table (every loop of the while loop), I need to CALL a stored procedure to calculate the data for the last <td> of my table. Here some code: $s = $lk->query("SELECT * FROM A_USERS JOIN A_DATA WHERE A_DATA.id_user = A_USERS.id AND A_USERS.usr_att = 1 AND A_DATA.act_data = 1 AND A_DATA.a_att = 1 AND A_DATA.qty IS NOT NULL ORDER BY ID ASC"); while ($dato = $s->fetch_object()) { print '<tr>'; print '<td>'; print $dato->id;

How to execute procedure returning resultset in Firebird

最后都变了- 提交于 2019-12-11 02:23:23
问题 I have the following table create table LIST_PIPE_TABLE ( ID INT, ITEM VARCHAR(4000), IS_FOLDER VARCHAR(10) ) with 3 rows of data insert into LIST_PIPE_TABLE values(1,'Victorias Secret','true') insert into LIST_PIPE_TABLE values(2,'Porsche','true') insert into LIST_PIPE_TABLE values(3,'Babbolat','false') And a stored procedure that should return resultset CREATE or alter PROCEDURE LIST_PIPE RETURNS ( col1 varchar(4000), col2 varchar(10) ) AS begin FOR SELECT ITEM AS ITEM ,IS_FOLDER AS IS

Call assembly procedure from another assembly file?

删除回忆录丶 提交于 2019-12-11 02:06:04
问题 Just a simple question: Let's say I had the following two assembly programs: 1: add10: add eax, 10 ret ;call add5 from other file 2: add5: add eax, 5 ret ;call add10 from other file Could I call add10 (declared in the first file) from the second file, or vice-versa? If so, how can it be done? (even if it isn't feasible) NOTE: This will be running on bare metal, not on any fancy NT calls! Thanks. Edit: I'm using NASM on Windows. 回答1: If both files are linked into the same executable, yes.

dynamic query in oracle procedure using cursor

天大地大妈咪最大 提交于 2019-12-10 10:13:58
问题 I am using a stored procedure to select records using a cursor. This procedure gets record id as input. Here is the code: create or replace procedure GET_ITEM_DETAILS_ALL ( cur_out out sys_refcursor, PSTRING VARCHAR2 DEFAULT NULL ) is query_string VARCHAR2(1000); Begin query_string := 'Select IT.SL_NO from ITEM_DETAILS IT where IT.SL_NO in (:sl) order by IT.SL_NO'; OPEN cur_out FOR query_string USING PSTRING; End; And for calling / testing the procedure I use the below code: VAR R REFCURSOR

Procedure mysql with cursor is too slow.. Why?

十年热恋 提交于 2019-12-10 10:07:51
问题 I create a Mysql procedure using cursor, but it's run too slow... It's get between 40 and 60 lines by second.. See: DELIMITER $$ CREATE PROCEDURE sp_create(IN v_idsorteio INT,OUT afetados INT) BEGIN DECLARE done INT default 0; DECLARE vc_idsocio INT; DECLARE z INT; DECLARE cur1 CURSOR FOR select IdSocio from socios where Sorteio=1 and Finalizado='S' and CodClientes IS NOT NULL; DECLARE CONTINUE HANDLER FOR SQLSTATE '02000' SET done=1; SET z=1; OPEN cur1; FETCH cur1 INTO vc_idsocio; WHILE done

Strugging with spring SimpleJdbcCall to call Oracle function

陌路散爱 提交于 2019-12-08 19:36:07
问题 I am struggling with the below code to make it work, searching documentation and forums and stucked. Finally I decided to ask you for help. What I have is package with TYPES, FUNCTION declarations and FUNCTION BODY declaration. In future I would like to use SYNONYM to MYPACKAGE (This is only mock - I will not have package and types declarations in my database, but use dblink to external database and Java code to run procedures / functions, but now I don't have this dblink accessible) and