Received: by 10.101.70.15 with SMTP id x15mr1249394ank.18.1228456689705; Thu, 04 Dec 2008 21:58:09 -0800 (PST)Date: Thu, 4 Dec 2008 21:58:09 -0800 (PST)X-IP: 171.161.56.16User-Agent: G2/1.0X-Google-Token: Fwo1fwwAAABORKFNUU55iK5dAl3QXapVX-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; InfoPath.1; .NET CLR 1.1.4322; .NET CLR 1.0.3705; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; MS-RTC LM 8; MS-RTC S),gzip(gfe),gzip(gfe)X-HTTP-Via: 1.1 mumkcnc1 (NetCache NetApp/6.0.1P3), 1.1 hk2-inetcache1 (NetCache NetApp/6.0.2P1D1)Message-ID: <59f6611c-409f-4747-ab23-6cc294233cdc@z27g2000prd.googlegroups.com>Subject: Insert statement versus .u.updFrom: Nav <nav.andraste>To: “Kdb+ Personal Developers” X-Google-Approved: simon.garland@gmail.com via web at 2008-12-05 07:58:43Hi All,I was wondering wht is the difference between a insert statementand .u.upd statement.More specifically whilst writing a c++ code ..For instance an insert statement looks like :k(-c,“trade insert(12:34:56.789;
xx;93.5;300)”,0);and a .u.upd usage isk(-kdbSocketHandle, “.u.upd”, ks((S)“trade”), row, (K)0);Please explain how the two statements differ..Thanks,Nav</nav.andraste>
.u.upd is a call to a user-defined function on the server (with thename upd in the namespace .u)–it can, in principle, do anythinginsert is a q built-in functionOn Fri, Dec 5, 2008 at 1:58 PM, Nav <nav.andraste> wrote:>> Hi All,>> I was wondering wht is the difference between a insert statement> and .u.upd statement.> More specifically whilst writing a c++ code ..>> For instance an insert statement looks like :>> k(-c,“trade insert(12:34:56.789;
xx;93.5;300)”,0);>>> and a .u.upd usage is>> k(-kdbSocketHandle, “.u.upd”, ks((S)“trade”), row, (K)0);>>> Please explain how the two statements differ..>>> Thanks,>> Nav>> >>– Aaron Daviesaaron.davies@gmail.com</nav.andraste>
Nav,.u.upd is part of kdb+tick, which is a separate product so you’reunlikely to get an answer herebut to answer your question .. .u.upd is just a function that’s calledwhen data arrives - and how it’s defined is up to the application, acommon definition is simply:.u.upd:insertinsert is different as that’s part of q/SimonOn Dec 5, 6:58?am, Nav <nav.andra…> wrote:> Hi All,>> I was wondering wht is the difference between a insert statement> and .u.upd statement.> More specifically whilst writing a c++ code ..>> For ?instance an insert statement looks like :>> k(-c,“trade insert(12:34:56.789;
xx;93.5;300)”,0);>> and a .u.upd usage is>> k(-kdbSocketHandle, “.u.upd”, ks((S)“trade”), row, (K)0);>> Please explain how the two statements differ..>> Thanks,>> Nav</nav.andra…>
Thanks that helps,Regards,NavOn Dec 5, 1:05?pm, simon <simon.garl…> wrote:> Nav,>> .u.upd is part of kdb+tick, which is a separate product so you’re> unlikely to get an answer here>> but to answer your question .. .u.upd is just a function that’s called> when data arrives - and how it’s defined is up to the application, a> common definition is simply:>> .u.upd:insert>> insert is different as that’s part of q>> /Simon>> On Dec 5, 6:58?am, Nav <nav.andra…> wrote:>>>> > Hi All,>> > I was wondering wht is the difference between a insert statement> > and .u.upd statement.> > More specifically whilst writing a c++ code ..>> > For ?instance an insert statement looks like :>> > k(-c,“trade insert(12:34:56.789;
xx;93.5;300)”,0);>> > and a .u.upd usage is>> > k(-kdbSocketHandle, “.u.upd”, ks((S)“trade”), row, (K)0);>> > Please explain how the two statements differ..>> > Thanks,>> > Nav- Hide quoted text ->> - Show quoted text -</nav.andra…></simon.garl…>